1. 程式人生 > >ExtJs 日期相加,Grid表格列可編輯

ExtJs 日期相加,Grid表格列可編輯

for CI tex lec combox ant head tool RM

1、日期相加:

Ext.Date.add(new Date(), Ext.Date.DAY, 15)

2、Grid表格列可編輯:

{
header : "實際已交貨量",
tooltip : ‘實際已交貨量‘,
dataIndex : ‘actualQuantityDelivered‘,
width : 100,
editor : {
xtype : ‘numberfield‘,
maxLength : 100,
allowNegative : false,
allowDecimals : true,

decimalPrecision : 4
},
sortable : true
}
{
header : "包裝說明",
tooltip : ‘包裝說明‘,
dataIndex : ‘packDesc‘,
id : ‘packDesc‘,
width : 100,
editor : Ext.create(‘Ext.form.ComboBox‘, {
store : packDescStore,
defaultListConfig : {
maxHeight : 150
},
valueField : COMMON.COMBOX_KEY,
displayField : COMMON.COMBOX_VALUE,
anchor : ‘100%‘,
editable : false,
mode : ‘local‘,
triggerAction : ‘all‘,
selectOnFocus : true,
emptyText : ‘請選擇‘
}),
sortable : true
}

ExtJs 日期相加,Grid表格列可編輯