The automatic update of the data itself
will be available in the Framework, the data services is what allows for
automatic transfer back to the server.
The cell renderer APIs may help show you
what can be done in Flex 2 as well.
Matt
This will be handled in the
Flex2 data services. More importantly is
that the changes (inserted, added and deleted
buffers) will be
marshalled to the server as needed and can be
bound to a persistence
adapter (say Hibernate) to even manage updating
the data store with
the changes.
That's where the real power comes in.
--
Dave Wolf
Cynergy Systems, Inc.
Macromedia Flex Alliance Partner
http://www.cynergysystems.com
Email: [EMAIL PROTECTED]
Office: 866-CYNERGY x85
--- In [email protected],
"ddwoske" <[EMAIL PROTECTED]> wrote:
>
> I have big problems understanding something.
>
> I basically want to build UI components which
modify underlying XML so
> that I can send the modified XML back to the
server. I want to bind
> some TextInput components to portions of the
XML and when I change the
> text then I want the XML to be automatically
updated. This doesn't
> seem possible, and if it is, it doesn't seem
very easy.
>
>
> Using OpenLaszlo here is a simple, but
complete program for modifying
> the price of a list of items:
>
> <canvas height="400"
debug="true" >
> <debug y="200" />
> <dataset name="inventory" >
> <items>
>
<item><name>One</name><price>100</price></item>
>
<item><name>Two</name><price>200</price></item>
>
<item><name>Three</name><price>300</price></item>
> </items>
> </dataset>
>
> <view>
> <simplelayout
axis="y" />
> <!-- Laszlo creates a
replicated view for each
> of
my item -->
> <view
datapath="inventory:/items/item" >
> <text
datapath="name/text()" />
> <edittext
x="100" datapath="price/text()">
>
<method event="onblur">
>
this.datapath.updateData();
>
</method>
> </edittext>
> </view>
>
> <button
>
canvas.datasets.inventory.serialize() )">
> Dump XML</button>
>
> </view>
> </canvas>
>
> You can try running it here:
>
http://www.laszlosystems.com/lps-3.0/laszlo-explorer/editor.jsp?src="">
>
> I can change the prices on the screen, and
the underlying XML is
> automatically updated through the use of the
updateData() method.
>
> Does this two-way binding exist in Flex 2.0 ?
>
> I see how you can add a mouseOut handler, but
I don't see how to push
> the data back into the XML model from where
it came from without some
> fancy code in the handler.. can someone tell
me how to do this?
>
>
> Cheers,
> Don
>
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
SPONSORED LINKS
YAHOO! GROUPS LINKS
|
- RE: [flexcoders] Re: Two way data binding? Matt Chotin
-