diff --git a/src/app/core/services/form/form.service.ts b/src/app/core/services/form/form.service.ts index 693d2353..195716ba 100644 --- a/src/app/core/services/form/form.service.ts +++ b/src/app/core/services/form/form.service.ts @@ -69,6 +69,10 @@ export class FormService { allow_custom_entities: entity.allow_custom_entities, allow_filtering: entity.allow_filtering }; + formData.validators = { + ...formData.validators, + required: entity.required + } } }); return formData diff --git a/src/app/core/services/util/util.service.ts b/src/app/core/services/util/util.service.ts index 5870d189..0598f242 100644 --- a/src/app/core/services/util/util.service.ts +++ b/src/app/core/services/util/util.service.ts @@ -209,5 +209,26 @@ export class UtilService { snakeToNormal(text: string): string { return text.split('_').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join(' '); } + + async profileUpdatePopup(msg){ + let texts; + this.translate.get([msg.header, msg.message, msg.cancel]).subscribe(text => { + texts = text; + }) + const alert = await this.alert.create({ + cssClass: 'my-custom-class', + header: texts[msg.header], + message: texts[msg.message], + buttons: [ + { + text: texts[msg.cancel], + role: 'cancel', + cssClass: 'alert-button-red' + }, + ], + backdropDismiss: false + }); + await alert.present(); + } } diff --git a/src/app/modules/private/private.page.html b/src/app/modules/private/private.page.html index 868a5085..42d916dc 100644 --- a/src/app/modules/private/private.page.html +++ b/src/app/modules/private/private.page.html @@ -1,6 +1,6 @@ - +
- +