目的: V20305零件需求登錄 – grid_M加入 ToolBar 且放在分頁的下方 - AddDocked
處理程序: 1> Ext.getCmp('grid_M').addDocked({:Toolbar元件},index);
Ext.getCmp('grid_M').addDocked({
xtype: 'toolbar',
dock: 'bottom',
items: [cmp_myToolBar]
},1);
xtype: 'toolbar',
dock: 'bottom',
items: [cmp_myToolBar]
},1);
1>*.js
var cmp_myToolBar =
{
xtype: 'toolbar',
dock: 'bottom',
id: 'mytoolBar1',
items: [
'-', { xtype: 'label', text: '', width: 100 },
{
xtype: 'button', text: 'MAIL人員修訂', id: 'btn_V60202K',
iconCls: 'icon-edit',
listeners: {
click: function () {
CALL_V60202K();
}
} //end of listeners
}, //end of MAIL人員修訂
{
xtype: 'button', text: '進貨記錄查詢', id: 'btn_V60202I',
iconCls: 'icon-search',
listeners: {
click: function () {
var cur_recs = Ext.getCmp('grid_M').getSelectionModel().getSelection();
var cur_rec = cur_recs[0];
CALL_V60202I(cur_rec);
}
} //end of listeners
}, //end of 進貨記錄查詢
{
xtype: 'button', text: '領料記錄查詢', id: 'btn_V60202J',
iconCls: 'icon-search',
listeners: {
click: function () {
var cur_recs = Ext.getCmp('grid_M').getSelectionModel().getSelection();
var cur_rec = cur_recs[0];
CALL_V60202J(cur_rec);
}
} //end of listeners
}, //end of 領料記錄查詢
]
};
Ext.getCmp('grid_M').addDocked({
xtype: 'toolbar',
dock: 'bottom',
items: [cmp_myToolBar]
},1);


沒有留言:
張貼留言