Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Entity Attribute conditional mandatority

ILya CycloneJan 10 2012 — edited Jan 10 2012
Hello OTN,
I've got an entity object which is used in different projects. In this entity there is an attribute which should be mandatory conditionally:
When (attributeA != 1 && attributeA != 2) attributeB should be mandatory.
This should be reflected in the UI with * symbol and an error message which I define in entity business rules.

The problem is I can't set Mandatory constraint to be conditional, there's no Validation Execution tab.

Well, I could add a Script Expression or Java method to EntityImpl as business rule but this woudln't give me the * symbol in the UI and I will have to set inputText required attribute on every page.
Could I avoid it somehow? I want the business rule to be defined only once in the entity object.

Thanks.

ADF 11.1.2.1

Edited by: ILya Cyclone on Jan 10, 2012 3:25 PM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 7 2012
Added on Jan 10 2012
1 comment
344 views