Jan 30, 2019, 12:34 PM
Double data binding
Hello again)
i have gridpanel with componentcolumn. As component i use formpanel.
In ComponentColumn`s listeners i have released bind method.
Why it works twice and after rendering my grid i get two forms with same ids, one of them has property destroyed = true, ohter doesn`t have such property?
i have gridpanel with componentcolumn. As component i use formpanel.
In ComponentColumn`s listeners i have released bind method.
Why it works twice and after rendering my grid i get two forms with same ids, one of them has property destroyed = true, ohter doesn`t have such property?
X.GridPanel()
.ColumnModel(
X.ComponentColumn()
.Listeners(ls =>
{
ls.Bind.Handler = @"bind(item,cmp,record);";
})
.Component(
X.FormPanel()
...
)
)
bind method:function bind(item, cmp, record) {
idPrefix = "ef_";
cmp.setId(idPrefix + record.data.ItemValue);
cmp.getForm().loadRecord(record);
}