Why no data is displayed on the screen? Or tell me a good/correct way to fix or avoid this.
Thank you.
[in view block]
Ext.define('CreditQuery.view.QueryResult', {
extend: 'Ext.tab.Panel',
xtype: 'queryresult',
config: {
defaults: {
defaultType: 'textfield'
},
items: [{
title: 'Credit',
},
items: [{
label: 'CustNo',
name: 'ACCOUNT_ID'
},{
label: 'CustName',
name: 'ACCOUNT_TEXT'
}]
}]
}
})
[in controller block]
function setData(data){
data = {
ACCOUNT_ID: "FN2180004",
ACCOUNT_TEXT: "John1218"
}
Ext.ComponentQuery.query('queryresult textfield')[0].setValue(data.ACCOUNT_ID);
Ext.ComponentQuery.query('queryresult textfield')[1].setValue(data.ACCOUNT_TEXT);
Ext.ComponentQuery.query('main')[0].push([{ xtype: 'queryresult' }]);
}
Access the textfields like this: -
Controller-