0
我使用的是同一個頁面上此兩個電網的ExtJS 4
Ext.define('Wifi.view.widget', {
extend: 'Ext.grid.Panel',
xtype: 'customerlist',
selModel: {
selType: 'cellmodel'
},
height: 380,
width: 700,
viewConfig: {
stripeRows: true
},
initComponent: function() {
Ext.apply(this, {
// Each grid will create its own store now when it is initialized.
store: Ext.create('Wifi.store.Customers'),
plugins: Ext.create('Ext.grid.plugin.CellEditing'),
columns: [{
text: 'Column Name', // Two line header! Test header height synchronization!
locked : false,
width : 200,
sortable : false,
dataIndex: 'columnName'
},{
text : 'Display Name',
width : 200,
sortable : true,
dataIndex: 'displayName',
editor: {
xtype: 'textfield'
}
},{
text : 'Column Width',
width : 150,
sortable : true,
dataIndex: 'columnWidth',
editor: {
xtype: 'numberfield'
}
},{
text : 'Column Type',
width : 100,
sortable : true,
dataIndex: 'columnType',
editor: {
xtype: 'ColumnTypeCombo'
}
}]
});
this.callParent(arguments);
}
});
格..
Ext.define('Wifi.view.ViewPortletConfig', {
extend: 'Ext.container.Viewport',
requires: ['Wifi.view.ViewDetailCombo'],
initComponent: function() {
var me = this;
Ext.apply(me, {
items: [
{
region: 'center',
layout:'column',
items : [
{
columnWidth: 1/2,
title: 'Table 1 Column Details',
border:true,
margin:'5 5 5 5',
items:[
{
xtype : 'toolbar',
height:35,
width:700,
border:true,
frame:true,
items: [
'->',
'Select Table: ',
{
margin:'0 50 0 0',
xtype : 'ViewDetailCombo'
}
]
},
{
xtype : 'customerlist'
}
]
},{
columnWidth: 1/2,
title: 'Table 2 Column Details',
border:true,
margin:'5 5 5 5',
items:[
{
xtype : 'toolbar',
height:35,
width:700,
border:true,
frame:true,
items: [
'->',
'Select Table: ',
{
margin:'0 50 0 0',
xtype : 'ViewDetailCombo'
},
]
},
{xtype : 'customerlist'}
]
}
]
}
]
});
me.callParent(arguments);
}
});
只有第一格商店裝上的表1的組合框的變化和表2.有人可以指導我,問題在哪裏。提前致謝。
'ViewDetailCombo'的代碼是什麼? – kevhender