Sep 26, 2016, 6:35 AM
[CLOSED] Using XML instead of JSON
Hello
We are trying to rewrite one of our very old backed application using Ext UI frontend
Now the problem is that old backend communicate only in XML
example
on input of the form editing ( basically load of the form) I get
Now the question on very generic level. How to approach app like that? On of obvious ways is to Convert XML on JSON on some level above old backed, sent to js, send back, compose xml and pass to old backed back. Howerer is there a way how to avoid XL to JSON conversions? I'm asking especially because of developper productivity.
I Check XmlStore, MVVM in sencha, I haven't found anything realy helpful. Idea is to write some kind of XmlReader/Writer (Extjs class), that would get XPath and bind directly to UI field. On writing add ISDIRTY attributes
Any hint or kick to the righ direction?
Thanks
Zdenek
We are trying to rewrite one of our very old backed application using Ext UI frontend
Now the problem is that old backend communicate only in XML
example
on input of the form editing ( basically load of the form) I get
<RESPONSE >
<DOCUMENT OBJECTID="37819" VERSIONSTAMP="71828096" VERSION="0.1">
<DOCNAME ISDIRTY="false" GDNFORMAT="">asd</DOCNAME>
<DOCTITLE ISDIRTY="false">Test1Doc2003</DOCTITLE>
</DOCUMENT>
</RESPONSE>
and when sending reply back ( esentially saving form) I'm supposed to send the same XML, with ISDIRTY attributes set to true, where value has been changed. I have to send complete XML, so for example if DOCNAME has changed and DOCTITLE not, I'm supposed to send<RESPONSE >
<DOCUMENT OBJECTID="37819" VERSIONSTAMP="71828096" VERSION="0.1">
<DOCNAME ISDIRTY="true" GDNFORMAT="">new name</DOCNAME>
<DOCTITLE ISDIRTY="false">Test1Doc2003</DOCTITLE>
</DOCUMENT>
</RESPONSE>
The xml is seriously long and whole system contains dozens of such formsNow the question on very generic level. How to approach app like that? On of obvious ways is to Convert XML on JSON on some level above old backed, sent to js, send back, compose xml and pass to old backed back. Howerer is there a way how to avoid XL to JSON conversions? I'm asking especially because of developper productivity.
I Check XmlStore, MVVM in sencha, I haven't found anything realy helpful. Idea is to write some kind of XmlReader/Writer (Extjs class), that would get XPath and bind directly to UI field. On writing add ISDIRTY attributes
Any hint or kick to the righ direction?
Thanks
Zdenek
Last edited by fabricio.murta; Oct 29, 2016 at 9:06 PM.
Reason: no user feedback for 7+ days