proccesing variable number of parameters

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

proccesing variable number of parameters

tuvok
Hi,

I have form in wich I can dinamically add additional input parameters. How can I define and implement java service that is able to procces different number of parameters. Obviously the number of parameters in service definition is constant, so what can I do?

tnx
Tuvok
Reply | Threaded
Open this post in threaded view
|

Re: proccesing variable number of parameters

Malin Nicolas
You can use a specific Map to pass your dynamical parammeters as
performFind service.

Nicolas

Le 06/10/2011 11:37, tuvok a écrit :

> Hi,
>
> I have form in wich I can dinamically add additional input parameters. How
> can I define and implement java service that is able to procces different
> number of parameters. Obviously the number of parameters in service
> definition is constant, so what can I do?
>
> tnx
> Tuvok
>
> --
> View this message in context: http://ofbiz.135035.n4.nabble.com/proccesing-variable-number-of-parameters-tp3877559p3877559.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.


--
Nicolas MALIN
Consultant
Tél : 06.17.66.40.06
Site projet : http://www.neogia.org/
-------
Société LibrenBerry
Tél : 02.48.02.56.12
Site : http://www.librenberry.net/

Reply | Threaded
Open this post in threaded view
|

Re: proccesing variable number of parameters

tuvok
Ok, tnx for fast reply

but how can I pass parameters map to specific map if I have form written in freemarker.
My service is called as an event to the request-map specified in forms "action" attribute.
I can't do something like:

<service service-name="performFind" result-map="result">
          <field-map field-name="inputFields" from-field="parameters"/>
</service>

in the <action> tag of a screen, or can I?
Reply | Threaded
Open this post in threaded view
|

Re: proccesing variable number of parameters

Malin Nicolas
Use string-map-prefix attribute :

<attribute mode="IN" name="identifications" optional="true"
string-map-prefix="ident_" type="Map"/>

And on your ftl code <input name="ident_one" vallue="100"/><input
name="ident_two" vallue="200"/> pass on your service [one|100][two|200]

Nicolas

Le 06/10/2011 12:14, tuvok a écrit :

> Ok, tnx for fast reply
>
> but how can I pass parameters map to specific map if I have form written in
> freemarker.
> My service is called as an event to the request-map specified in forms
> "action" attribute.
> I can't do something like:
>
> <service service-name="performFind" result-map="result">
>            <field-map field-name="inputFields" from-field="parameters"/>
> </service>
>
> in the<action>  tag of a screen, or can I?
>
> --
> View this message in context: http://ofbiz.135035.n4.nabble.com/proccesing-variable-number-of-parameters-tp3877559p3877645.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.


--
Nicolas MALIN
Consultant
Tél : 06.17.66.40.06
Site projet : http://www.neogia.org/
-------
Société LibrenBerry
Tél : 02.48.02.56.12
Site : http://www.librenberry.net/

Reply | Threaded
Open this post in threaded view
|

Re: proccesing variable number of parameters

tuvok
Tnx Nicolas, you've been very helpfull

live long and prosper :)

Malin Nicolas wrote
Use string-map-prefix attribute :

<attribute mode="IN" name="identifications" optional="true"
string-map-prefix="ident_" type="Map"/>

And on your ftl code <input name="ident_one" vallue="100"/><input
name="ident_two" vallue="200"/> pass on your service [one|100][two|200]

Nicolas