ExtJS /CQ Widget API Tips
How to get the component node path dialog listeners like beforeshow,afterrender ....etc
beforeshow : function(compDialog){
console.log(compDialog.path);//currentNode.getPath();
}
How to do get AJAX call for no cache
var curNodeRes = CQ.Util.eval( CQ.HTTP.noCaching(compDialog.path+".json") ); // gives json of component node/currentNode
How to get the dialog fields in listeners
1) by using name
selectionchanged : function(el,val,check){
var dialog = el.findParentByType('dialog');//gives dialog
var field = dialog.getField('./fieldNameGivenInDialog')
}
2) by using id -- if item has id
selectionchanged : function(el,val,check){
var field = CQ.Ext.getCmp('id-given-for-field');
}
No comments:
Post a Comment