You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ofbiz.apache.org by Patrick <pa...@gmail.com> on 2010/05/19 01:40:25 UTC

how to get post variables from a service?

I have an ofbizUrl in an FTL file
<@ofbizUrl>AddProducerToFacilityButtonClicked?facilityId=${facility.facilityId}&partyId=${partyId}"

the controller calls a service.

how do I get facilityId, and partyId from the service?  I looked in
context, but it wasn't there.

Re: how to get post variables from a service?

Posted by Vikas Raikwar <ra...@gmail.com>.
 Hello Patrick,

>
> "AddProducerToFacilityButtonClicked" is this a service ?
>
    if yes, so define out parameters inside the service definition
    through which you will get facilityId and partyId out from this service.



On Wed, May 19, 2010 at 5:10 AM, Patrick <pa...@gmail.com>wrote:

> I have an ofbizUrl in an FTL file
>
> <@ofbizUrl>AddProducerToFacilityButtonClicked?facilityId=${facility.facilityId}&partyId=${partyId}"
>
> the controller calls a service.
>
> how do I get facilityId, and partyId from the service?  I looked in
> context, but it wasn't there.
>

Re: how to get post variables from a service?

Posted by Bilgin Ibryam <bi...@gmail.com>.
Patrick wrote:
> I have an ofbizUrl in an FTL file
> <@ofbizUrl>AddProducerToFacilityButtonClicked?facilityId=${facility.facilityId}&partyId=${partyId}"
>
> the controller calls a service.
>
> how do I get facilityId, and partyId from the service?  I looked in
> context, but it wasn't there.
>   
After recent security refactoring, ofbiz services don't accept 
parameters sent using GET method. If you want to pass these parameters 
to a service, you have to use POST method, instead.
So you have to create a form and put these parameters as hidden field, 
then submit the form.

Bilgin