diff --git a/src/addons/userprofilefield/checkbox/component/addon-user-profile-field-checkbox.html b/src/addons/userprofilefield/checkbox/component/addon-user-profile-field-checkbox.html index e0b5c770c..63e6ee09b 100644 --- a/src/addons/userprofilefield/checkbox/component/addon-user-profile-field-checkbox.html +++ b/src/addons/userprofilefield/checkbox/component/addon-user-profile-field-checkbox.html @@ -1,7 +1,11 @@ -

{{ field.name }}

+

+ + +

{{ 'core.yes' | translate }}

@@ -14,7 +18,11 @@ - {{ field.name }} + + + + diff --git a/src/addons/userprofilefield/datetime/component/addon-user-profile-field-datetime.html b/src/addons/userprofilefield/datetime/component/addon-user-profile-field-datetime.html index 3638e01b8..ff6256e5d 100644 --- a/src/addons/userprofilefield/datetime/component/addon-user-profile-field-datetime.html +++ b/src/addons/userprofilefield/datetime/component/addon-user-profile-field-datetime.html @@ -1,7 +1,11 @@ -

{{ field.name }}

+

+ + +

{{ valueNumber * 1000 | coreFormatDate }}

{{ displayValue }}

@@ -10,7 +14,11 @@ - {{ field.name }} + + + + diff --git a/src/addons/userprofilefield/menu/component/addon-user-profile-field-menu.html b/src/addons/userprofilefield/menu/component/addon-user-profile-field-menu.html index a657ef6c1..28246420c 100644 --- a/src/addons/userprofilefield/menu/component/addon-user-profile-field-menu.html +++ b/src/addons/userprofilefield/menu/component/addon-user-profile-field-menu.html @@ -1,9 +1,14 @@ -

{{ field.name }}

+

+ + +

- +

@@ -12,7 +17,11 @@ - {{ field.name }} + + + + diff --git a/src/addons/userprofilefield/text/component/addon-user-profile-field-text.html b/src/addons/userprofilefield/text/component/addon-user-profile-field-text.html index 2426c2dd3..e75d88886 100644 --- a/src/addons/userprofilefield/text/component/addon-user-profile-field-text.html +++ b/src/addons/userprofilefield/text/component/addon-user-profile-field-text.html @@ -1,9 +1,14 @@ -

{{ field.name }}

+

+ + +

- +

@@ -12,7 +17,11 @@ - {{ field.name }} + + + + diff --git a/src/addons/userprofilefield/textarea/component/addon-user-profile-field-textarea.html b/src/addons/userprofilefield/textarea/component/addon-user-profile-field-textarea.html index ff938e96e..29f16a3c5 100644 --- a/src/addons/userprofilefield/textarea/component/addon-user-profile-field-textarea.html +++ b/src/addons/userprofilefield/textarea/component/addon-user-profile-field-textarea.html @@ -1,9 +1,14 @@ -

{{ field.name }}

+

+ + +

- +

@@ -12,7 +17,11 @@ - {{ field.name }} + + + + { if (!this.field) { return; } @@ -60,7 +61,6 @@ export abstract class CoreUserProfileFieldBaseComponent implements OnInit { return; } - } /** @@ -70,6 +70,7 @@ export abstract class CoreUserProfileFieldBaseComponent implements OnInit { */ protected initForNonEdit(field: CoreUserProfileField): void { this.value = field.displayvalue ?? field.value; + this.valueNotFiltered = field.displayvalue === undefined || field.displayvalue === null; } /** diff --git a/src/core/features/user/services/user.ts b/src/core/features/user/services/user.ts index 267b92123..3e9ca4b0f 100644 --- a/src/core/features/user/services/user.ts +++ b/src/core/features/user/services/user.ts @@ -892,7 +892,7 @@ export type CoreUserPreference = { export type CoreUserProfileField = { type: string; // The type of the custom field - text field, checkbox... value: string; // The value of the custom field. - displayvalue: string; // @since 4.2. Formatted value of the custom field. + displayvalue?: string; // @since 4.2. Formatted value of the custom field. name: string; // The name of the custom field. shortname: string; // The shortname of the custom field - to be able to build the field class in the code. };