Ext.define('saas.view.purchase.purchaseIn.FormPanel', { extend: 'saas.view.core.form.FormPanel', xtype: 'purchase-purchaseIn-formpanel', controller: 'purchase-purchaseIn-formcontroller', viewModel: 'purchase-purchaseIn-formmodel', _title:'采购验收单', _codeField: 'pi_inoutno', _statusField: 'pi_statuscode', _idField: 'id', _detnoColumn: 'pd_pdno', _dataModelUrl:'http://192.168.253.58:8800/purchase/read/', _saveUrl:'http://192.168.253.58:8800/purchase/save', _auditUrl:'http://192.168.253.58:8800/purchase/audit', _deleteUrl:'http://192.168.253.58:8800/purchase/delete/', _deleteDetailUrl:'http://192.168.253.58:8800/purchase/deleteItem/', initId:0, toolBtns: [{ xtype: 'button', text: '转单按钮', handler: function() { console.log('11'); } }], defaultItems: [{ xtype: 'hidden', name: 'id', bind: '{id}', fieldLabel: 'id', allowBlank: true, columnWidth: 0 }, { xtype : "textfield", name : "pi_inoutno", bind : "{pi_inoutno}", fieldLabel : "验收单号", allowBlank : true, columnWidth : 0.25 },{ xtype : "textfield", name : "pi_class", bind : "{pi_class}", fieldLabel : "类型", readOnly:true, allowBlank : true, columnWidth : 0.25 }, { xtype : "hidden", name : "pu_vendid", bind : "{pu_vendid}", fieldLabel : "供应商ID", allowBlank : true, columnWidth : 0.0 }, { xtype : "textfield", name : "pu_vendcode", bind : "{pu_vendcode}", fieldLabel : "供应商编号", hidden:true, allowBlank : true, columnWidth : 0, }, { xtype : "dbfindtrigger", name : "pu_vendname", bind : "{pu_vendname}", fieldLabel : "供应商名称", allowBlank : true, columnWidth : 0.25 },{ xtype : "datefield", name : "pu_date", bind : "{pu_date}", fieldLabel : "采购日期", allowBlank : false, columnWidth : 0.25 }, { xtype : "hidden", name : "pu_buyerid", bind : "{pu_buyerid}", fieldLabel : "采购员ID", allowBlank : true, columnWidth : 0.0 }, { xtype : "textfield", name : "pu_buyercode", bind : "{pu_buyercode}", fieldLabel : "采购员编号", allowBlank : true, hidden:true, columnWidth : 0 }, { xtype : "dbfindtrigger", name : "pu_buyername", bind : "{pu_buyername}", fieldLabel : "采购员名称", allowBlank : true, columnWidth : 0.25 }, { xtype : "textfield", name : "pu_shipaddresscode", bind : "{pu_shipaddresscode}", fieldLabel : "交货地址", allowBlank : true, columnWidth : 0.25 }, { xtype : "textfield", name : "pu_total", bind : "{pu_total}", fieldLabel : "单据金额", allowBlank : true, columnWidth : 0.25 }, { name : "detailGridField", xtype : "detailGridField", bind: { store:{ data:'{detailGridField}' } }, columns : [ { text : "序号", dataIndex : "pdDetno", width : 80.0, xtype : "rownumberer" }, { text : "id", dataIndex : "id", xtype : "numbercolumn" }, { editor : { displayField : "display", editable : true, format : "", hideTrigger : false, maxLength : 100.0, minValue : null, positiveNum : false, queryMode : "local", store : null, valueField : "value", xtype : "dbfindtrigger" }, text : "物料编号", width : 200.0, dataIndex : "pd_prodcode", xtype : "", items : null }, { text : "单位", editor : { xtype : "textfield" }, dataIndex : "pd_unit", width : 120.0, xtype : "", items : null }, { text : "数量", dataIndex : "pd_yqty", width : 120.0, xtype : "numbercolumn", items : null }, { text : "单价", dataIndex : "pd_price", width : 120.0, xtype : "numbercolumn", items : null }, { text : "税率", dataIndex : "pd_taxrate", width : 120.0, xtype : "numbercolumn", items : null }, { text : "含税金额", dataIndex : "pd_total", width : 120.0, xtype : "numbercolumn" }, { text : "未税金额", dataIndex : "pd_taxtotal", xtype : "numbercolumn" },{ text : "需求日期", dataIndex : "pd_delivery", flex : 1.0, xtype:'datecolumn', format : "Y-m-d H:i:s", editor : { xtype : "datetimefield", editable : true, format : "Y-m-d H:i:s", hideTrigger : false } }, { text : "关联销售单号", dataIndex : "pd_salecode", width : 120.0, flex : 1.0 } ] }, { format : "Y-m-d", xtype : "datetimefield", name : "createTime", bind : "{createTime}", fieldLabel : "创建时间", allowBlank : true, columnWidth : 0.25 }, { xtype : "datefield", name : "updateTime", bind : "{updateTime}", fieldLabel : "更新时间", allowBlank : true, columnWidth : 0.25 }, { xtype : "textfield", readOnly : true, editable : false, name : "puStatus", bind : "{puStatus}", fieldLabel : "单据状态", allowBlank : true, columnWidth : 0.25 }, { xtype : "hidden", readOnly : true, editable : false, name : "pu_statuscode", bind : "{pu_statuscode}", fieldLabel : "单据状态码", allowBlank : true, columnWidth : 0.0 }] });