Explorar el Código

修改采购模块,仓库模块列表

zhoudw hace 7 años
padre
commit
aef3271d39

+ 30 - 0
applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/po/ProdInOutList.java

@@ -144,4 +144,34 @@ public class ProdInOutList extends CommonBaseEntity{
 
     private Long pd_ioid;
 
+    //private ProductDTO productDTO;
+    private Long pr_id;
+    private String pr_code;
+    private String pr_detail;
+    private String pr_spec;
+    private String pr_unit;
+    private String pr_kind;
+    private String pr_orispeccode;
+    private long pr_whid;
+    private String pr_whcode;
+    private String pr_whname;
+    private long pr_zxbzs;
+    private long pr_leadtime;
+    private String pr_brand;
+    private String pr_standardprice;
+    private String pr_purcprice;
+    private String pr_saleprice;
+    private long pr_vendid;
+    private String pr_vendname;
+    private String pr_vendcode;
+    private Date pr_docdate;
+    private long pr_recordmanid;
+    private String pr_recordman;
+    private String pr_status;
+    private String pr_statuscode;
+    private String pr_text1;
+    private String pr_text2;
+    private String pr_text3;
+    private String pr_text4;
+
 }

+ 28 - 1
applications/purchase/purchase-server/src/main/resources/mapper/ProdInOutListMapper.xml

@@ -71,7 +71,34 @@
     <result column="pd_ym" jdbcType="INTEGER" property="pd_ym" />
     <result column="pd_yqty" jdbcType="DOUBLE" property="pd_yqty" />
     <result column="pd_ioid" jdbcType="INTEGER" property="pd_ioid" />
-
+    <result column="pr_id" property="pr_id"/>
+    <result column="pr_code" property="pr_code"/>
+    <result column="pr_detail" property="pr_detail"/>
+    <result column="pr_spec" property="pr_spec"/>
+    <result column="pr_unit" property="pr_unit"/>
+    <result column="pr_kind" property="pr_kind"/>
+    <result column="pr_orispeccode" property="pr_orispeccode"/>
+    <result column="pr_whid" property="pr_whid"/>
+    <result column="pr_whcode" property="pr_whcode"/>
+    <result column="pr_whname" property="pr_whname"/>
+    <result column="pr_zxbzs" property="pr_zxbzs"/>
+    <result column="pr_leadtime" property="pr_leadtime"/>
+    <result column="pr_brand" property="pr_brand"/>
+    <result column="pr_standardprice" property="pr_standardprice"/>
+    <result column="pr_purcprice" property="pr_purcprice"/>
+    <result column="pr_saleprice" property="pr_saleprice"/>
+    <result column="pr_vendid" property="pr_vendid"/>
+    <result column="pr_vendname" property="pr_vendname"/>
+    <result column="pr_vendcode" property="pr_vendcode"/>
+    <result column="pr_docdate" property="pr_docdate"/>
+    <result column="pr_recordmanid" property="pr_recordmanid"/>
+    <result column="pr_recordman" property="pr_recordman"/>
+    <result column="pr_status" property="pr_status"/>
+    <result column="pr_statuscode" property="pr_statuscode"/>
+    <result column="pr_text1" property="pr_text1"/>
+    <result column="pr_text2" property="pr_text2"/>
+    <result column="pr_text3" property="pr_text3"/>
+    <result column="pr_text4" property="pr_text4"/>
   </resultMap>
 
   <select id="selectProdInOutBycondition"  resultMap="BaseResultMap">

+ 30 - 0
applications/storage/storage-dto/src/main/java/com/usoftchina/saas/storage/po/ProdInOutList.java

@@ -145,4 +145,34 @@ public class ProdInOutList extends CommonBaseEntity{
     private Double pi_nettotal;
 
     private String pi_remark;
+
+    //private ProductDTO productDTO;
+    private Long pr_id;
+    private String pr_code;
+    private String pr_detail;
+    private String pr_spec;
+    private String pr_unit;
+    private String pr_kind;
+    private String pr_orispeccode;
+    private long pr_whid;
+    private String pr_whcode;
+    private String pr_whname;
+    private long pr_zxbzs;
+    private long pr_leadtime;
+    private String pr_brand;
+    private String pr_standardprice;
+    private String pr_purcprice;
+    private String pr_saleprice;
+    private long pr_vendid;
+    private String pr_vendname;
+    private String pr_vendcode;
+    private Date pr_docdate;
+    private long pr_recordmanid;
+    private String pr_recordman;
+    private String pr_status;
+    private String pr_statuscode;
+    private String pr_text1;
+    private String pr_text2;
+    private String pr_text3;
+    private String pr_text4;
 }

+ 2 - 2
applications/storage/storage-server/src/main/java/com/usoftchina/saas/storage/service/impl/ProdInOutServiceImpl.java

@@ -77,9 +77,9 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
             con = "1=1";
         }
         if (null == req || StringUtils.isEmpty(req.getMode()) || "MAIN".equals(req.getMode())) {
-            list = prodInOutListMapper.selectProdInOutListByCondition(con,companyId);
-        } else {
             list = prodInOutListMapper.selectProdInOutBycondition(con,companyId);
+        } else {
+            list = prodInOutListMapper.selectProdInOutListByCondition(con,companyId);
         }
         return list;
     }

+ 29 - 1
applications/storage/storage-server/src/main/resources/mapper/ProdInOutListMapper.xml

@@ -73,12 +73,40 @@
     <result column="pd_ym" jdbcType="INTEGER" property="pd_ym" />
     <result column="pd_yqty" jdbcType="DOUBLE" property="pd_yqty" />
     <result column="pd_ioid" jdbcType="INTEGER" property="pd_ioid" />
-
+    <result column="pr_id" property="pr_id"/>
+    <result column="pr_code" property="pr_code"/>
+    <result column="pr_detail" property="pr_detail"/>
+    <result column="pr_spec" property="pr_spec"/>
+    <result column="pr_unit" property="pr_unit"/>
+    <result column="pr_kind" property="pr_kind"/>
+    <result column="pr_orispeccode" property="pr_orispeccode"/>
+    <result column="pr_whid" property="pr_whid"/>
+    <result column="pr_whcode" property="pr_whcode"/>
+    <result column="pr_whname" property="pr_whname"/>
+    <result column="pr_zxbzs" property="pr_zxbzs"/>
+    <result column="pr_leadtime" property="pr_leadtime"/>
+    <result column="pr_brand" property="pr_brand"/>
+    <result column="pr_standardprice" property="pr_standardprice"/>
+    <result column="pr_purcprice" property="pr_purcprice"/>
+    <result column="pr_saleprice" property="pr_saleprice"/>
+    <result column="pr_vendid" property="pr_vendid"/>
+    <result column="pr_vendname" property="pr_vendname"/>
+    <result column="pr_vendcode" property="pr_vendcode"/>
+    <result column="pr_docdate" property="pr_docdate"/>
+    <result column="pr_recordmanid" property="pr_recordmanid"/>
+    <result column="pr_recordman" property="pr_recordman"/>
+    <result column="pr_status" property="pr_status"/>
+    <result column="pr_statuscode" property="pr_statuscode"/>
+    <result column="pr_text1" property="pr_text1"/>
+    <result column="pr_text2" property="pr_text2"/>
+    <result column="pr_text3" property="pr_text3"/>
+    <result column="pr_text4" property="pr_text4"/>
   </resultMap>
 
 
   <select id="selectProdInOutListByCondition"  resultMap="BaseResultMap">
     select  *  from prodinout left join prodiodetail on pi_id = pd_piid
+    left join product on pd_prodcode=pr_code
     <where>
       <if test="con != null">
         ${con}

+ 44 - 9
frontend/saas-web/app/view/purchase/purchase/QueryPanel.js

@@ -143,24 +143,32 @@ Ext.define('saas.view.purchase.purchase.QueryPanel', {
             width: 100,
             hidden: true
         }, {
-            text: '单据编号',
+            text: '采购单号',
             dataIndex: 'pu_code',
             width: 200
+        },{
+            text: '供应商编号',
+            dataIndex: 'pu_vendcode',
+            width: 120
+        },{
+            text: '供应商名称',
+            dataIndex: 'pu_vendname',
+            width: 120
         }, {
             text: '审核状态',
             dataIndex: 'pu_status',
             width: 120
+        },{
+            text: '业务状态',
+            dataIndex: 'pu_acceptstatus',
+            width: 120
         }, {
             text: '单据日期',
             dataIndex: 'pu_indate',
             xtype: 'datecolumn',
             width: 200
         }, {
-            text: '供应商名称',
-            dataIndex: 'pu_vendname',
-            width: 120
-        }, {
-            text: '采购序号',
+            text: '序号',
             dataIndex: 'pd_detno',
             xtype: 'numbercolumn',
             width: 120
@@ -168,19 +176,46 @@ Ext.define('saas.view.purchase.purchase.QueryPanel', {
             text: '物料编号',
             dataIndex: 'pd_prodcode',
             width: 120
+        },{
+            text: '物料名称',
+            dataIndex: 'pr_detail',
+            width: 120
+        }, {
+            text: '物料规格',
+            dataIndex: 'pr_spec',
+            width: 120
         }, {
-            text: '数量',
+            text: '单位',
+            dataIndex: 'pr_spec',
+            width: 120
+        },{
+            text: '采购数量',
             dataIndex: 'pd_qty',
             xtype: 'numbercolumn',
             width: 120
         }, {
+            text: '交货日期',
+            dataIndex: 'pd_delivery',
+            xtype: 'datecolumn',
+            width: 200
+        },{
             text: '单价',
             dataIndex: 'pd_price',
             xtype: 'numbercolumn',
             width: 120
         }, {
-            text: '已转数',
-            dataIndex: 'pd_ytqy',
+            text: '税率',
+            dataIndex: 'pd_taxrate',
+            xtype: 'numbercolumn',
+            width: 120
+        },{
+            text: '金额',
+            dataIndex: 'pd_total',
+            xtype: 'numbercolumn',
+            width: 120
+        },{
+            text: '备注',
+            dataIndex: 'pu_remark',
             xtype: 'numbercolumn',
             width: 120
         }]

+ 35 - 21
frontend/saas-web/app/view/purchase/purchaseIn/QueryPanel.js

@@ -115,6 +115,10 @@ Ext.define('saas.view.purchase.purchaseIn.QueryPanel', {
             text: '审核状态',
             dataIndex: 'pi_status',
             width: 120
+        },{
+            text: '供应商编号',
+            dataIndex: 'pi_vendcode',
+            width: 120
         },{
             text: '供应商名称',
             dataIndex: 'pi_vendname',
@@ -139,47 +143,52 @@ Ext.define('saas.view.purchase.purchaseIn.QueryPanel', {
             hidden:true
         }, {
             text: '单据编号',
-            dataIndex: 'pd_inoutno',
+            dataIndex: 'pi_inoutno',
             width: 200
         }, {
+            text: '单据类型',
+            dataIndex: 'pd_piclass',
+            width: 200
+        },{
             text: '审核状态',
             dataIndex: 'pi_status',
             width: 120
-        }, {
-            text: '单据日期',
-            dataIndex: 'pi_date',
-            xtype:'datecolumn',
-            width: 200
+        },{
+            text: '供应商编号',
+            dataIndex: 'pi_vendcode',
+            width: 120
         },{
             text: '供应商名称',
             dataIndex: 'pi_vendname',
             width: 120
         },{
-            text: '采购单号',
-            dataIndex: 'pd_ordercode',
+            text: '物料编号',
+            dataIndex: 'pd_prodcode',
             width: 120
         },{
-            text: '采购序号',
-            dataIndex: 'pd_orderdetno',
-            xtype:'numbercolumn',
+            text: '物料名称',
+            dataIndex: 'pr_detail',
             width: 120
         },{
-            text: '物料编号',
-            dataIndex: 'pd_prodcode',
+            text: '物料规格',
+            dataIndex: 'pr_spec',
+            width: 120
+        },{
+            text: '单位',
+            dataIndex: 'pr_unit',
             width: 120
         },{
-            text: '验收数量',
+            text: '数量',
             dataIndex: 'pd_inqty',
             xtype:'numbercolumn',
             width: 120
         },{
-            text: '采购单价',
-            dataIndex: 'pd_orderprice',
-            xtype:'numbercolumn',
+            text: '仓库',
+            dataIndex: 'pd_whname',
             width: 120
         },{
-            text: '金额',
-            dataIndex: 'pd_total',
+            text: '单位成本',
+            dataIndex: 'pd_orderprice',
             xtype:'numbercolumn',
             width: 120
         },{
@@ -188,8 +197,13 @@ Ext.define('saas.view.purchase.purchaseIn.QueryPanel', {
             xtype:'numbercolumn',
             width: 120
         },{
-            text: '成本单价',
-            dataIndex: 'pd_price',
+            text: '金额',
+            dataIndex: 'pd_total',
+            xtype:'numbercolumn',
+            width: 120
+        },{
+            text: '相关单号',
+            dataIndex: 'pd_ordercode',
             xtype:'numbercolumn',
             width: 120
         }]

+ 34 - 24
frontend/saas-web/app/view/purchase/purchaseOut/QueryPanel.js

@@ -143,51 +143,56 @@ Ext.define('saas.view.purchase.purchaseOut.QueryPanel', {
         relativeColumn: [{
             text: 'id',
             dataIndex: 'pu_id',
-            width: 0,
-            xtype: 'numbercolumn'
+            xtype: 'numbercolumn',
+            hidden:true
         }, {
             text: '单据编号',
-            dataIndex: 'pd_inoutno',
+            dataIndex: 'pi_inoutno',
             width: 200
         }, {
+            text: '单据类型',
+            dataIndex: 'pd_piclass',
+            width: 200
+        },{
             text: '审核状态',
             dataIndex: 'pi_status',
             width: 120
-        }, {
-            text: '单据日期',
-            dataIndex: 'pi_date',
-            xtype:'datecolumn',
-            width: 200
+        },{
+            text: '供应商编号',
+            dataIndex: 'pi_vendcode',
+            width: 120
         },{
             text: '供应商名称',
             dataIndex: 'pi_vendname',
             width: 120
         },{
-            text: '采购单号',
-            dataIndex: 'pd_ordercode',
+            text: '物料编号',
+            dataIndex: 'pd_prodcode',
             width: 120
         },{
-            text: '采购序号',
-            dataIndex: 'pd_orderdetno',
-            xtype:'numbercolumn',
+            text: '物料名称',
+            dataIndex: 'pr_detail',
             width: 120
         },{
-            text: '物料编号',
-            dataIndex: 'pd_prodcode',
+            text: '物料规格',
+            dataIndex: 'pr_spec',
+            width: 120
+        },{
+            text: '单位',
+            dataIndex: 'pr_unit',
             width: 120
         },{
-            text: '验收数量',
+            text: '数量',
             dataIndex: 'pd_inqty',
             xtype:'numbercolumn',
             width: 120
         },{
-            text: '采购单价',
-            dataIndex: 'pd_orderprice',
-            xtype:'numbercolumn',
+            text: '仓库',
+            dataIndex: 'pd_whname',
             width: 120
         },{
-            text: '金额',
-            dataIndex: 'pd_total',
+            text: '单位成本',
+            dataIndex: 'pd_orderprice',
             xtype:'numbercolumn',
             width: 120
         },{
@@ -196,10 +201,15 @@ Ext.define('saas.view.purchase.purchaseOut.QueryPanel', {
             xtype:'numbercolumn',
             width: 120
         },{
-            text: '成本单价',
-            dataIndex: 'pd_price',
+            text: '金额',
+            dataIndex: 'pd_total',
+            xtype:'numbercolumn',
+            width: 120
+        },{
+            text: '相关单号',
+            dataIndex: 'pd_ordercode',
             xtype:'numbercolumn',
-            width: 120,
+            width: 120
         }]
     }
 });

+ 0 - 17
frontend/saas-web/app/view/stock/otherIn/FormPanel.js

@@ -49,23 +49,6 @@ Ext.define('saas.view.stock.otherIn.FormPanel', {
         readOnly:true,
         allowBlank : true, 
         columnWidth : 0.25
-    }, {
-        xtype : "hidden", 
-        name : "pi_vendid", 
-        bind : "{pi_vendid}", 
-        fieldLabel : "供应商ID", 
-        allowBlank : true, 
-        columnWidth : 0.0
-    },{
-        xtype: 'hidden',
-        name: 'pi_vendcode',
-        bind: '{pi_vendcode}',
-        fieldLabel: '供应商编号'
-    }, {
-        xtype: 'dbfindtrigger',
-        name: 'pi_vendname',
-        bind: '{pi_vendname}',
-        fieldLabel: '供应商名称'
     },{
         xtype : "hidden", 
         name : "pi_custid", 

+ 40 - 30
frontend/saas-web/app/view/stock/otherIn/QueryPanel.js

@@ -30,15 +30,15 @@ Ext.define('saas.view.stock.otherIn.QueryPanel', {
         columnWidth: 0.5
     }, {
         xtype: 'textfield',
-        name: 'pi_vendcode',
-        fieldLabel: '供应商编号',
+        name: 'pi_custcode',
+        fieldLabel: '客户编号',
         allowBlank: true,
         hidden:true,
         columnWidth: 0.25
     }, {
         xtype: 'dbfindtrigger',
-        name: 'pi_vendname',
-        fieldLabel: '供应商名称',
+        name: 'pi_custname',
+        fieldLabel: '客户名称',
         allowBlank: true,
         columnWidth: 0.25
     }, {
@@ -128,51 +128,56 @@ Ext.define('saas.view.stock.otherIn.QueryPanel', {
         relativeColumn: [{
             text: 'id',
             dataIndex: 'pu_id',
-            width: 0,
-            xtype: 'numbercolumn'
+            xtype: 'numbercolumn',
+            hidden:true
         }, {
             text: '单据编号',
-            dataIndex: 'pd_inoutno',
+            dataIndex: 'pi_inoutno',
             width: 200
         }, {
-            text: '审核状态',
-            dataIndex: 'pi_status',
-            width: 120
-        }, {
-            text: '单据日期',
-            dataIndex: 'pi_date',
-            xtype:'datecolumn',
+            text: '单据类型',
+            dataIndex: 'pd_piclass',
             width: 200
         },{
-            text: '供应商名称',
-            dataIndex: 'pi_vendname',
+            text: '审核状态',
+            dataIndex: 'pi_status',
             width: 120
         },{
-            text: '采购单号',
-            dataIndex: 'pd_ordercode',
+            text: '客户编号',
+            dataIndex: 'pi_custcode',
             width: 120
         },{
-            text: '采购序号',
-            dataIndex: 'pd_orderdetno',
-            xtype:'numbercolumn',
+            text: '客户名称',
+            dataIndex: 'pi_custname',
             width: 120
         },{
             text: '物料编号',
             dataIndex: 'pd_prodcode',
             width: 120
         },{
-            text: '验收数量',
+            text: '物料名称',
+            dataIndex: 'pr_detail',
+            width: 120
+        },{
+            text: '物料规格',
+            dataIndex: 'pr_spec',
+            width: 120
+        },{
+            text: '单位',
+            dataIndex: 'pr_unit',
+            width: 120
+        },{
+            text: '数量',
             dataIndex: 'pd_inqty',
             xtype:'numbercolumn',
             width: 120
         },{
-            text: '采购单价',
-            dataIndex: 'pd_orderprice',
-            xtype:'numbercolumn',
+            text: '仓库',
+            dataIndex: 'pd_whname',
             width: 120
         },{
-            text: '金额',
-            dataIndex: 'pd_total',
+            text: '单位成本',
+            dataIndex: 'pd_orderprice',
             xtype:'numbercolumn',
             width: 120
         },{
@@ -181,10 +186,15 @@ Ext.define('saas.view.stock.otherIn.QueryPanel', {
             xtype:'numbercolumn',
             width: 120
         },{
-            text: '成本单价',
-            dataIndex: 'pd_price',
+            text: '金额',
+            dataIndex: 'pd_total',
+            xtype:'numbercolumn',
+            width: 120
+        },{
+            text: '相关单号',
+            dataIndex: 'pd_ordercode',
             xtype:'numbercolumn',
-            width: 120,
+            width: 120
         }]
     }
 });

+ 80 - 2
frontend/saas-web/app/view/stock/otherIn/QueryPanelController.js

@@ -90,6 +90,8 @@ Ext.define('saas.view.stock.otherIn.QueryPanelController', {
                         addXtype: 'document-product-formpanel',
                         addTitle: '物料资料',
                         dbfinds:[{
+                            from:'pr_detail',to:'pr_detail',
+                        },{
                             from:'pr_code',to:'pd_prodcode',
                         }, {
                             from:'pr_detail',to:'pr_detail'
@@ -101,7 +103,7 @@ Ext.define('saas.view.stock.otherIn.QueryPanelController', {
                         }],
                         defaultCondition: "pr_statuscode='OPEN'",
                         dbSearchFields:[{
-                            emptyText:'输入物料编号、名称或规格',
+                            emptyText:'输入物料编号或名称',
                             xtype : "textfield", 
                             name : "search", 
                             width: 200,
@@ -179,7 +181,83 @@ Ext.define('saas.view.stock.otherIn.QueryPanelController', {
                     }) ;   
 
                 }
-            }
+            },
+            'dbfindtrigger[name=pi_custname]': {
+                beforerender: function (f) {
+                    Ext.apply(f, {
+                        addXtype: 'document-customer-formpanel',
+                        addTitle: '客户资料',
+                        dataUrl: '/api/document/customer/list',
+                        // dataUrl:'http://localhost:9480/customer/list',
+                        dbfinds: [{
+                            from: 'id',to: 'pi_custid',ignore:true
+                        }, {
+                            from: 'cu_code',to: 'pi_custcode'
+                        }, {
+                            from: 'cu_name',to: 'pi_custname'
+                        }],
+                        dbtpls: [{
+                            field: 'cu_code',
+                            width: 100
+                        }, {
+                            field: 'cu_name',
+                            width: 100
+                        }],
+                        defaultCondition:"cu_statuscode='OPEN'",
+                        //放大镜窗口字段
+                        dbSearchFields:[{
+                            emptyText:'输入客户编号或名称',
+                            xtype : "textfield", 
+                            name : "cu_name", 
+                            allowBlank : true, 
+                            columnWidth : 0.25,
+                            getCondition:function(v){
+                                return "(upper(cu_name) like '%"+v.toUpperCase()+"%' or upper(cu_code) like '%"+v.toUpperCase()+"%')";
+                            }
+                        }],
+                        dbColumns:[{
+                            "text": "客户ID",
+                            "hidden": true,
+                            "dataIndex": "id",
+                        },{
+                            "text": "客户编号",
+                            "dataIndex": "cu_code",
+                            "width": 200,
+                        }, {
+                            "text": "客户名称",
+                            "dataIndex": "cu_name",
+                            "width": 200
+                        },{
+                            "text": "客户类型",
+                            "dataIndex": "cu_name",
+                            "width": 100
+                        },{
+                            "text": "业务员",
+                            "dataIndex": "cu_sellername",
+                            "width": 100
+                        },{
+                            "text": "税率",
+                            "dataIndex": "cu_taxrate",
+                            "width": 100,
+                            xtype: 'numbercolumn',
+                            align:'end'
+                        },{
+                            "text": "承付天数",
+                            "dataIndex": "cu_promisedays",
+                            "width": 100,
+                            xtype: 'numbercolumn',
+                            align:'end'
+                        },{
+                            "text": "额度",
+                            "dataIndex": "cu_credit",
+                            "width": 100,
+                            xtype: 'numbercolumn',
+                            align:'end'
+                        }]
+                    });
+
+                }
+            },            
         });
 
     }

+ 0 - 17
frontend/saas-web/app/view/stock/otherOut/FormPanel.js

@@ -47,23 +47,6 @@ Ext.define('saas.view.stock.otherOut.FormPanel', {
         readOnly: true,
         allowBlank: true,
         columnWidth: 0.25
-    }, {
-        xtype: "hidden",
-        name: "pi_vendid",
-        bind: "{pi_vendid}",
-        fieldLabel: "供应商ID",
-        allowBlank: true,
-        columnWidth: 0.0
-    }, {
-        xtype: 'hidden',
-        name: 'pi_vendcode',
-        bind: '{pi_vendcode}',
-        fieldLabel: '供应商编号'
-    }, {
-        xtype: 'dbfindtrigger',
-        name: 'pi_vendname',
-        bind: '{pi_vendname}',
-        fieldLabel: '供应商名称'
     }, {
         xtype: "hidden",
         name: "pi_custid",

+ 40 - 32
frontend/saas-web/app/view/stock/otherOut/QueryPanel.js

@@ -30,17 +30,15 @@ Ext.define('saas.view.stock.otherOut.QueryPanel', {
         columnWidth: 0.5
     }, {
         xtype: 'textfield',
-        name: 'pi_vendcode',
-        bind: '{pi_vendcode}',
-        fieldLabel: '供应商编号',
+        name: 'pi_custcode',
+        fieldLabel: '客户编号',
         allowBlank: true,
         hidden:true,
         columnWidth: 0.25
     }, {
         xtype: 'dbfindtrigger',
-        name: 'pi_vendname',
-        bind: '{pi_vendname}',
-        fieldLabel: '供应商名称',
+        name: 'pi_custname',
+        fieldLabel: '客户名称',
         allowBlank: true,
         columnWidth: 0.25
     }, {
@@ -130,51 +128,56 @@ Ext.define('saas.view.stock.otherOut.QueryPanel', {
         relativeColumn: [{
             text: 'id',
             dataIndex: 'pu_id',
-            width: 0,
-            xtype: 'numbercolumn'
+            xtype: 'numbercolumn',
+            hidden:true
         }, {
             text: '单据编号',
-            dataIndex: 'pd_inoutno',
+            dataIndex: 'pi_inoutno',
             width: 200
         }, {
-            text: '审核状态',
-            dataIndex: 'pi_status',
-            width: 120
-        }, {
-            text: '单据日期',
-            dataIndex: 'pi_date',
-            xtype:'datecolumn',
+            text: '单据类型',
+            dataIndex: 'pd_piclass',
             width: 200
         },{
-            text: '供应商名称',
-            dataIndex: 'pi_vendname',
+            text: '审核状态',
+            dataIndex: 'pi_status',
             width: 120
         },{
-            text: '采购单号',
-            dataIndex: 'pd_ordercode',
+            text: '客户编号',
+            dataIndex: 'pi_custcode',
             width: 120
         },{
-            text: '采购序号',
-            dataIndex: 'pd_orderdetno',
-            xtype:'numbercolumn',
+            text: '客户名称',
+            dataIndex: 'pi_custname',
             width: 120
         },{
             text: '物料编号',
             dataIndex: 'pd_prodcode',
             width: 120
         },{
-            text: '验收数量',
+            text: '物料名称',
+            dataIndex: 'pr_detail',
+            width: 120
+        },{
+            text: '物料规格',
+            dataIndex: 'pr_spec',
+            width: 120
+        },{
+            text: '单位',
+            dataIndex: 'pr_unit',
+            width: 120
+        },{
+            text: '数量',
             dataIndex: 'pd_inqty',
             xtype:'numbercolumn',
             width: 120
         },{
-            text: '采购单价',
-            dataIndex: 'pd_orderprice',
-            xtype:'numbercolumn',
+            text: '仓库',
+            dataIndex: 'pd_whname',
             width: 120
         },{
-            text: '金额',
-            dataIndex: 'pd_total',
+            text: '单位成本',
+            dataIndex: 'pd_orderprice',
             xtype:'numbercolumn',
             width: 120
         },{
@@ -183,10 +186,15 @@ Ext.define('saas.view.stock.otherOut.QueryPanel', {
             xtype:'numbercolumn',
             width: 120
         },{
-            text: '成本单价',
-            dataIndex: 'pd_price',
+            text: '金额',
+            dataIndex: 'pd_total',
+            xtype:'numbercolumn',
+            width: 120
+        },{
+            text: '相关单号',
+            dataIndex: 'pd_ordercode',
             xtype:'numbercolumn',
-            width: 120,
+            width: 120
         }]
     }
 });

+ 80 - 2
frontend/saas-web/app/view/stock/otherOut/QueryPanelController.js

@@ -90,6 +90,8 @@ Ext.define('saas.view.stock.otherOut.QueryPanelController', {
                         addXtype: 'document-product-formpanel',
                         addTitle: '物料资料',
                         dbfinds:[{
+                            from:'pr_detail',to:'pr_detail',
+                        },{
                             from:'pr_code',to:'pd_prodcode',
                         }, {
                             from:'pr_detail',to:'pr_detail'
@@ -101,7 +103,7 @@ Ext.define('saas.view.stock.otherOut.QueryPanelController', {
                         }],
                         defaultCondition: "pr_statuscode='OPEN'",
                         dbSearchFields:[{
-                            emptyText:'输入物料编号、名称或规格',
+                            emptyText:'输入物料编号或名称',
                             xtype : "textfield", 
                             name : "search", 
                             width: 200,
@@ -179,7 +181,83 @@ Ext.define('saas.view.stock.otherOut.QueryPanelController', {
                     }) ;   
 
                 }
-            }
+            },
+            'dbfindtrigger[name=pi_custname]': {
+                beforerender: function (f) {
+                    Ext.apply(f, {
+                        addXtype: 'document-customer-formpanel',
+                        addTitle: '客户资料',
+                        dataUrl: '/api/document/customer/list',
+                        // dataUrl:'http://localhost:9480/customer/list',
+                        dbfinds: [{
+                            from: 'id',to: 'pi_custid',ignore:true
+                        }, {
+                            from: 'cu_code',to: 'pi_custcode'
+                        }, {
+                            from: 'cu_name',to: 'pi_custname'
+                        }],
+                        dbtpls: [{
+                            field: 'cu_code',
+                            width: 100
+                        }, {
+                            field: 'cu_name',
+                            width: 100
+                        }],
+                        defaultCondition:"cu_statuscode='OPEN'",
+                        //放大镜窗口字段
+                        dbSearchFields:[{
+                            emptyText:'输入客户编号或名称',
+                            xtype : "textfield", 
+                            name : "cu_name", 
+                            allowBlank : true, 
+                            columnWidth : 0.25,
+                            getCondition:function(v){
+                                return "(upper(cu_name) like '%"+v.toUpperCase()+"%' or upper(cu_code) like '%"+v.toUpperCase()+"%')";
+                            }
+                        }],
+                        dbColumns:[{
+                            "text": "客户ID",
+                            "hidden": true,
+                            "dataIndex": "id",
+                        },{
+                            "text": "客户编号",
+                            "dataIndex": "cu_code",
+                            "width": 200,
+                        }, {
+                            "text": "客户名称",
+                            "dataIndex": "cu_name",
+                            "width": 200
+                        },{
+                            "text": "客户类型",
+                            "dataIndex": "cu_name",
+                            "width": 100
+                        },{
+                            "text": "业务员",
+                            "dataIndex": "cu_sellername",
+                            "width": 100
+                        },{
+                            "text": "税率",
+                            "dataIndex": "cu_taxrate",
+                            "width": 100,
+                            xtype: 'numbercolumn',
+                            align:'end'
+                        },{
+                            "text": "承付天数",
+                            "dataIndex": "cu_promisedays",
+                            "width": 100,
+                            xtype: 'numbercolumn',
+                            align:'end'
+                        },{
+                            "text": "额度",
+                            "dataIndex": "cu_credit",
+                            "width": 100,
+                            xtype: 'numbercolumn',
+                            align:'end'
+                        }]
+                    });
+
+                }
+            },             
         });
 
     }