You may also want to check out the simple-method documentation which is in the MiniLang Guide, linked to on the Docs & Books page of the ofbiz.org site.

-David


On Oct 8, 2006, at 2:02 AM, Chris Howe wrote:

this by no means is a complete explanation...just a
quick usable one.  For a complete explanation you
might want to check out Undersun Consulting's Advanced
Framework Training ;)

--- "Alex D. Fleming" <[EMAIL PROTECTED]> wrote:

Hi,

 I am looking to have answer for some simple
questions : (I will be thankful if anybody of you
could help me ).

 The questions are related to the Mini Language/
Simple Methods :

 1) What's the Difference in :
 <entity-one entity-name="Product"
value-name="product" auto-field-map="true"/>
 &
 <make-value value-name="lookupPKMap"
entity-name="Product"/>


<entity-one> is a search by primary key productId will
need to be somewhere in the context (i'm not sure if
it needs to be the field parameters.productId or
simply productId)
instead of using auto-field-map="true" you may find it
easier as you're getting used to the minilang to be
specific and do the following
<entity-one ...>
 <field-map field-name="" value="" (or env-name=""/>
</entity-one>
just remember that you must specify the complete
primary key

<make-value> returns an empty generic entity of the
entity you specify.  This makes it much easier (less
error prone) to do a create, store, remove than does
creating the map by hand.

 2)  What's the Difference in :
 <if-compare> & <if-compare-field>


<if-compare> will compare the field to the value
specified in the value=""

<if-compare-field> will compare the field to another
field.

 3) What's the difference in the following two
sentence :
 <field-to-field field-name="productId"
to-field-name="productIdToCheck"/>
 &
 <set field="productId" value="productIdToCheck"/>


<field-to-field I believe has been deprecated in usage
in favor of <set> however notice your
value="productIdToCheck" is the string literal
"productIdToCheck" and not the field productIdToCheck

to make them equivalent statements, it should be <set
field="productId" from-field="productIdToCheck"/>

 It may be some stupid questions but I will feel
happy if somebody clears my doughts.

Hope that helped

                
---------------------------------
Yahoo! Messenger with Voice. Make PC-to-Phone Calls
to the US (and 30+ countries) for 2ยข/min or less.



Reply via email to