How to set a mandatory field on ANGULAR Web Portal form

Hi all,

In the old web portal, it was possible to arbitrarily configure a mandatory field, as mentioned in this post: https://support.oneidentity.com/identity-manager/kb/4347249/how-to-set-a-mandatory-field-on-web-portal-form, by setting 1 as the minimum character count for the field to be made mandatory.

How can I replicate the same behavior on the Angular portal? Both for default forms, such as "data administration->Identities->create identity" configured via the administration portal, and for custom pages created specifically in Angular.

Thank you for your support.

  • Hello Davide,

    for this you will have to add a few lines of code into the component that generates the identity form. In this case I have added this code into a custom method that returns the form with the mandatory field. Hope this will solve the problem.

    this.cdrListPersonal = this.cdrFactoryService.buildCdrFromColumnListAdvanced(this.data.selectedIdentity.GetEntity(), columsThatWillBeShown, readOnlyColumns);
    
    // add mendatory fields here
    this.cdrListPersonal.map((field) => {
    if(field.column.ColumnName === "The column name goes in here") {
    field.minLength = 1;
    }
    })
    
    return this.cdrListPersonal;