Re: Laszlo client for Keel?
Max <maxxam-cuDQgYkrLFxfAa1EqD/[email protected]>
| Newsgroups | gmane.comp.java.keel.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi Nils,
Thanks a ton. I've now got the model execute call working but am
struggling to dereference the returned data. For e.g., for the soap
message that gets returned how do I dereference the <added> output and
the <command> "label" attribute in Flex?
The following Flex code doesn't display anything:
<mx:Label text="{process_mydata.execute.result.model.added}" />
<mx:Button
label="{process_mydata.execute.result.model.command.label}"
click="prompt_mydata.execute.send();
apphojpages.selectedChild=promptmydata;" />
SOAP message:
<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<model forward="hoj.process-mydata" name="hoj.process-mydata">
<added element-type="output">Added data</added>
<command label="Prompt For Data" model="hoj.prompt-mydata"
name="prompt">
</command>
</model>
</soapenv:Body>
</soapenv:Envelope>
Thanks for the help,
Max
Nils Döhring wrote:
> sure. note that you need clnt-axis up and running (see one of my last
> posts).
>
> here's the shortest possible demo for posting data to the hoj example
> app:
>
> <?xml version="1.0" encoding="utf-8"?>
> <mx:Application xmlns:mx="http://www.macromedia.com/2003/mxml">
> <mx:WebService id="ws"
> wsdl="http://localhost/default/services/ModelService?wsdl">
> <mx:operation name="execute" result="alert(event.result)"
> resultFormat="xml">
> <mx:request format="xml">
> <request model="hoj.process-mydata">
> <parameters>
> <parameter name="mystring" value="{mystring.text}"/>
> </parameters>
> </request>
> </mx:request>
> </mx:operation>
> </mx:WebService>
> <mx:Form>
> <mx:FormItem label="mystring" required="true">
> <mx:TextInput id="mystring" width="200"/>
> </mx:FormItem>
> <mx:FormItem>
> <mx:Button label="Add" click="ws.execute.send()"/>
> </mx:FormItem>
> </mx:Form>
> <mx:Label text="{ws.execute.result}" width="400"/>
> <mx:Repeater id="errorList"
> dataProvider="{ws.execute.result.model.errors.item}">
> <mx:Label text="{errorList.currentItem.message}"/>
> </mx:Repeater>
>
> </mx:Application>
>
http://keelframework.org/documentation.shtml
Keelgroup mailing list
[email protected]
http://lists.keelframework.com/listinfo.cgi/keelgroup-keelframework.com