|
|
@@ -0,0 +1,274 @@
|
|
|
+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 : "pd_pdno",
|
|
|
+ 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_inqty",
|
|
|
+ width : 120.0,
|
|
|
+ xtype : "numbercolumn",
|
|
|
+ items : null
|
|
|
+ },
|
|
|
+ {
|
|
|
+ text : "仓库",
|
|
|
+ dataIndex : "pd_whname",
|
|
|
+ width : 120.0,
|
|
|
+ xtype : "numbercolumn",
|
|
|
+ items : null,
|
|
|
+ editor : {
|
|
|
+ displayField : "display",
|
|
|
+ editable : true,
|
|
|
+ format : "",
|
|
|
+ hideTrigger : false,
|
|
|
+ maxLength : 100.0,
|
|
|
+ minValue : null,
|
|
|
+ positiveNum : false,
|
|
|
+ queryMode : "local",
|
|
|
+ store : null,
|
|
|
+ valueField : "value",
|
|
|
+ xtype : "dbfindtrigger"
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ text : "单价",
|
|
|
+ dataIndex : "pd_orderprice",
|
|
|
+ width : 120.0,
|
|
|
+ xtype : "numbercolumn",
|
|
|
+ items : null
|
|
|
+ },
|
|
|
+ {
|
|
|
+ text : "含税金额",
|
|
|
+ dataIndex : "pd_total",
|
|
|
+ width : 120.0,
|
|
|
+ xtype : "numbercolumn"
|
|
|
+ }, {
|
|
|
+ text : "税率",
|
|
|
+ dataIndex : "pd_taxrate",
|
|
|
+ width : 120.0,
|
|
|
+ xtype : "numbercolumn",
|
|
|
+ items : null
|
|
|
+ },
|
|
|
+ {
|
|
|
+ text : "未税金额",
|
|
|
+ dataIndex : "pd_nettotal",
|
|
|
+ xtype : "numbercolumn"
|
|
|
+ },
|
|
|
+ {
|
|
|
+ text : "采购单号",
|
|
|
+ dataIndex : "pd_ordercode",
|
|
|
+ width : 120.0,
|
|
|
+ flex : 1.0,
|
|
|
+ editor : {
|
|
|
+ displayField : "display",
|
|
|
+ editable : true,
|
|
|
+ format : "",
|
|
|
+ hideTrigger : false,
|
|
|
+ maxLength : 100.0,
|
|
|
+ minValue : null,
|
|
|
+ positiveNum : false,
|
|
|
+ queryMode : "local",
|
|
|
+ store : null,
|
|
|
+ valueField : "value",
|
|
|
+ xtype : "dbfindtrigger"
|
|
|
+ }
|
|
|
+ },{
|
|
|
+ text : "采购序号",
|
|
|
+ dataIndex : "pd_orderdetno",
|
|
|
+ xtype : "numbercolumn",
|
|
|
+ flex:1
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }, {
|
|
|
+ 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
|
|
|
+ }]
|
|
|
+});
|