Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Make mandatory field if we select a specific value in picklist

I know that we can do this using a custom validations script to my module, like you can read here:

But I'm not sure if we can do this with Business Maps. Maybe with a combination of Validations and Dependency Business Maps.

Is possible?

In my case I want to make mandatory a date field when we select a concrete value form a picklist.


Hello  Omar,

I think that what you are asking for, can be done using a Validations Map. You can use an Expression for making the field mandatory or if you need to do more complicated validations go on creating a custom function.

I'm writing you here a simple example where an expression is used to make mandatory the field Codice Fiscale when the picklist field  Natura Fiscale contains the value "Ditta Individuale"

Validation Map


Expression Map (Make_CF_Mandatory)


    <expression>if ($(account_id : (Accounts) naturafisc_account)  == 'Ditta Individuale')  then (if ($(account_id : (Accounts) codice_fiscale) != '' or account_id : (Accounts) codice_fiscale) != 0) then 1 else 0 end) else 0 end</expression>

Let me know if this helps


Forum Jump:

Users browsing this thread: 1 Guest(s)