You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by Jacques Le Roux <ja...@les7arts.com> on 2007/06/05 18:07:31 UTC

MiniLang : value in

It's perhaps a stupid question (just a quick one, actually I did not
look at simple-method.xsd)

Why is there no value attribute in the if-compare-field element ?

So we have to write something like

<set field="Not" value="N"/>
<if-compare-field field-name="res.res1" operator="equals"
to-field-name="Not">

Where we could have something intuitive like

<if-compare-field field-name="res.res1" operator="equals"  value="N">

Thanks

Jacques


Re: MiniLang : value in

Posted by Jacques Le Roux <ja...@les7arts.com>.
Thanks Chris and Jacopo ,

I guessed it was a stupid question :o)

Jacques

----- Message d'origine ----- 
De : "Jacopo Cappellato" <ti...@sastau.it>
À : <de...@ofbiz.apache.org>
Envoyé : mardi 5 juin 2007 18:21
Objet : Re: MiniLang : value in


> Hi Jacques,
>
> you should use <if-compare> instead.
>
> Jacopo
>
> Jacques Le Roux wrote:
> > It's perhaps a stupid question (just a quick one, actually I did not
> > look at simple-method.xsd)
> >
> > Why is there no value attribute in the if-compare-field element ?
> >
> > So we have to write something like
> >
> > <set field="Not" value="N"/>
> > <if-compare-field field-name="res.res1" operator="equals"
> > to-field-name="Not">
> >
> > Where we could have something intuitive like
> >
> > <if-compare-field field-name="res.res1" operator="equals"
value="N">
> >
> > Thanks
> >
> > Jacques
>


Re: MiniLang : value in

Posted by Jacopo Cappellato <ti...@sastau.it>.
Hi Jacques,

you should use <if-compare> instead.

Jacopo

Jacques Le Roux wrote:
> It's perhaps a stupid question (just a quick one, actually I did not
> look at simple-method.xsd)
> 
> Why is there no value attribute in the if-compare-field element ?
> 
> So we have to write something like
> 
> <set field="Not" value="N"/>
> <if-compare-field field-name="res.res1" operator="equals"
> to-field-name="Not">
> 
> Where we could have something intuitive like
> 
> <if-compare-field field-name="res.res1" operator="equals"  value="N">
> 
> Thanks
> 
> Jacques



Re: MiniLang : value in

Posted by Chris Howe <cj...@yahoo.com>.
you're looking for the <if-compare> method.  if-copmpare compares a
field to a value

<if-compare operator="less" field-name="" value="" format=""
map-name="" type="String">

--- Jacques Le Roux <ja...@les7arts.com> wrote:

> It's perhaps a stupid question (just a quick one, actually I did not
> look at simple-method.xsd)
> 
> Why is there no value attribute in the if-compare-field element ?
> 
> So we have to write something like
> 
> <set field="Not" value="N"/>
> <if-compare-field field-name="res.res1" operator="equals"
> to-field-name="Not">
> 
> Where we could have something intuitive like
> 
> <if-compare-field field-name="res.res1" operator="equals"  value="N">
> 
> Thanks
> 
> Jacques
> 
>