Posted by
Oleg Kozyrev Jr. on
Apr 18, 2006; 2:45pm
URL: http://ofbiz.116.s1.nabble.com/Dev-how-to-set-entity-constraint-for-null-values-in-form-def-tp167666p167669.html
Jacopo,
Just an idea (don't know whether it'll help). Try ignore-if-empty, ignore-if-null attributes of <entity-constraint>.
As for me, I usually work with <list-options>, selecting data in .bsh. You can try this way.
Oleg.
-----Original Message-----
From: Jacopo Cappellato <
[hidden email]>
To: "OFBiz Project Development Discussion (High Traffic)" <
[hidden email]>
Date: Tue, 18 Apr 2006 12:35:29 +0200
Subject: [OFBiz] Dev - how to set entity-constraint for null values in formdef?
>
> Hi all,
>
> in form widget, is there a way to select records
>
> I need to define the following selection for a drop-down field in a form
> widget:
>
> "select * from CostComponentType where parentTypeId is null"
>
> This is what I've tried to do:
>
> <field name="costComponentTypeId">
> <drop-down allow-empty="false">
> <entity-options entity-name="CostComponentType"
> description="${description}">
> <entity-constraint name="parentTypeId" operator="equals" value=""/>
> </entity-options>
> </drop-down>
> </field>
>
> Unfortunately this doesn't seem to work (the constraint is ignored)...
> can you help me?
>
> Thanks,
>
> Jacopo
>
> _______________________________________________
> Dev mailing list
>
[hidden email]
>
http://lists.ofbiz.org/mailman/listinfo/dev>
Как познакомиться с десятками людей за один день? Мы знаем один простой способ
http://r.mail.ru/cln2844/agent.mail.ru/talk.html
_______________________________________________
Dev mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/dev