Aug 12, 2015, 2:54 PM
[CLOSED] Form items property implementation
Hi,
I need to port the following DocumentReady handler code from 1.7:
I need to port the following DocumentReady handler code from 1.7:
var onDocumentReady = function () {
App.FormPanel1.getForm().reset = function (ctlsToExclude) {
this.items.each(function (f) {
if (!ctlsToExclude[f.id])
f.reset();
});
return this;
};
};
There're two problems with this code. Firstly, the "this" variable doesn't contain the same form object prototype that worked well in 1.7. Is my syntax off? Secondly, even if "this" reference is replaced with App.FormPanel1, the items property that used to return a collection of meaningful form elements like text fields, combo boxes, check boxes, etc, doesn't do it any longer. This behavior has been apparently altered in ExtJs 5.0 so the items are populated with the top level controls in the form controls tree, e.g., Container, ToolbarSpacer, etc. How can one arrive at the collection of the "true" form elements?
Last edited by Daniil; Aug 14, 2015 at 2:18 PM.
Reason: [CLOSED]