There is already a similar thread, but I want to more specifically explain what I would like. First of all, let me say that this is an excellent framework, incredible performance, I can hardly believe this is dhtml. That grid is work of art.
Now... I believe there is a flaw in the design of the databinding model. When binding to nested datasources, I currently have to use the 'name' field of the form item to match a property in the datasource. Furthermore, I have to call 'form.editRecord(record.nestedObj)' and set the datasource of the form to the datasource of the nested object. It would be much, much better if I could set the datasource of the form to the same as the parent record, and then have an explicit field on the fieldItems (i.e. 'datapath'), which I could set to something like 'nestedObj/field1' or 'nestedObj.field1'. The form would act as data container, allowing me to keep everthing more organized. The way it stands now, it seems like I have 3 options for showing multiple nested items in a form:
1. create multiple forms, one for each nested item. Not that elegant.
2. flatten my data in the dataset for each property w/ xpathvalue. I lose my intuitive hierarchy this way.
3. use form.setValues and write plumbing code to pass custom object in, and out again. Ugh.
Thanks,
Chris
Now... I believe there is a flaw in the design of the databinding model. When binding to nested datasources, I currently have to use the 'name' field of the form item to match a property in the datasource. Furthermore, I have to call 'form.editRecord(record.nestedObj)' and set the datasource of the form to the datasource of the nested object. It would be much, much better if I could set the datasource of the form to the same as the parent record, and then have an explicit field on the fieldItems (i.e. 'datapath'), which I could set to something like 'nestedObj/field1' or 'nestedObj.field1'. The form would act as data container, allowing me to keep everthing more organized. The way it stands now, it seems like I have 3 options for showing multiple nested items in a form:
1. create multiple forms, one for each nested item. Not that elegant.
2. flatten my data in the dataset for each property w/ xpathvalue. I lose my intuitive hierarchy this way.
3. use form.setValues and write plumbing code to pass custom object in, and out again. Ugh.
Thanks,
Chris
Comment