Преглед изворни кода

Merge branch 'purchaseDev' of http://172.16.100.139/new-business/drp-web into purchaseDev

002390 пре 2 година
родитељ
комит
2bbce4b2ea

+ 20 - 16
src/views/purchase/DemandSummary/add.vue

@@ -3,11 +3,11 @@
     <el-card>
       <span>采购需求处理详情</span>
       <div class="btn_grooup">
-        <el-button type="primary" size="small" @click="editLine">编辑</el-button>
-        <el-button type="danger" size="small" v-if="!lineDisable" @click="cancelEdit">取消编辑</el-button>
-        <el-button type="success" size="small" v-if="!lineDisable" @click="saveLine">保存</el-button>
-        <el-button type="primary" size="small" @click="closeLine">行关闭</el-button>
-        <el-button type="primary" size="small" @click="reloadBatch">重取批量</el-button>
+        <el-button type="primary" size="mini" @click="editLine">编辑</el-button>
+        <el-button type="danger" size="mini" v-if="!lineDisable" @click="cancelEdit">取消编辑</el-button>
+        <el-button type="success" size="mini" v-if="!lineDisable" @click="saveLine">保存</el-button>
+        <el-button type="primary" size="mini" @click="closeLine">行关闭</el-button>
+        <el-button type="primary" size="mini" @click="reloadBatch">重取批量</el-button>
       </div>
 
       <el-table 
@@ -18,7 +18,11 @@
         >
         <el-table-column show-overflow-tooltip type="selection" width="55" />
         <el-table-column show-overflow-tooltip label="序号" align="center" type="index"/>
-        <el-table-column show-overflow-tooltip label="行号" align="center" prop="rowNo"/>
+        <el-table-column show-overflow-tooltip label="行号" align="center" prop="rowNo">
+          <template slot-scope="scope">
+            {{ scope.$index + 1 + '0' }}
+          </template>
+        </el-table-column>
         <el-table-column show-overflow-tooltip label="行状态" align="center" prop="status" width="120px" :formatter="hangStatus"/>
         <el-table-column show-overflow-tooltip label="物料编码" align="center" prop="materialCode" width="150px"/>
         <el-table-column show-overflow-tooltip label="品名" align="center" prop="materialName" width="180"/>
@@ -43,7 +47,7 @@
           <template slot-scope="scope">
             <el-switch
               v-model="scope.row.isUrgency"
-              :disabled="lineDisable"
+              :disabled="scope.row.status !== '1' || lineDisable"
               active-value="Y"
               inactive-value="N"
               active-color="#13ce66"
@@ -55,7 +59,7 @@
           <template slot-scope="scope">
             <el-switch
               v-model="scope.row.isReplenishment"
-              :disabled="lineDisable"
+              :disabled="scope.row.status !== '1' || lineDisable"
               active-value="Y"
               inactive-value="N"
               active-color="#13ce66"
@@ -71,8 +75,8 @@
         <el-table-column show-overflow-tooltip label="收货仓库" align="center" prop="deliveryWarehouseName" width="150"/>
         <el-table-column show-overflow-tooltip label="收货货位" align="center" prop="deliveryAllocationName" width="200">
           <template slot-scope="scope">
-            <el-input clearable :disabled="lineDisable" size="small" v-model="scope.row.deliveryAllocationName" @clear="clean(scope.row)" @focus="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '收货货位', scope.row.deliveryWarehouse)">
-              <el-button size="small" :disabled="lineDisable" slot="append" icon="el-icon-more" @click="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '收货货位', scope.row.deliveryWarehouse)"></el-button>
+            <el-input clearable :disabled="scope.row.status !== '1' || lineDisable" size="mini" v-model="scope.row.deliveryAllocationName" @clear="clean(scope.row)" @focus="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '收货货位', scope.row.deliveryWarehouse)">
+              <el-button size="mini" :disabled="scope.row.status !== '1' || lineDisable" slot="append" icon="el-icon-more" @click="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '收货货位', scope.row.deliveryWarehouse)"></el-button>
             </el-input>
           </template>
         </el-table-column>
@@ -93,7 +97,7 @@
           <template slot-scope="scope">
             <el-switch
               v-model="scope.row.isBatchLock"
-              :disabled="lineDisable"
+              :disabled="scope.row.status !== '1' || lineDisable"
               active-value="Y"
               inactive-value="N"
               active-color="#13ce66"
@@ -117,7 +121,7 @@
 
     <div class="btn_group">
       <el-col :span="1.5">
-        <el-button size="small" plain @click="back">返回</el-button>
+        <el-button size="mini" plain @click="back">返回</el-button>
       </el-col>
     </div>
 
@@ -133,7 +137,7 @@ export default {
   components: {
     Refers
   },
-  props: ['pageStu','row', 'disable'],
+  props: ['pageStu','row', 'disable', 'query'],
   model: {
     prop: 'isList',
     event: 'jugislist'
@@ -183,9 +187,9 @@ export default {
   created() {
     if(this.pageStu == 'check') {
       console.log('数据', this.row)
-      this.getDetails(this.row)
-    } else if(this.pageStu == 'edit') {
-      this.getDetails(this.row)
+      let param = this.query
+      param.sumFlag = this.row.sumFlag
+      this.getDetails(param)
     }
   },
   methods: {

+ 40 - 40
src/views/purchase/DemandSummary/index.vue

@@ -6,7 +6,7 @@
           <el-row :gutter="10">
             <el-col :span="1.5">
               <el-form-item label="行状态">
-                <el-select multiple v-model="queryParams.rowStatus" size="small" style="width: 200px" clearable>
+                <el-select multiple v-model="queryParams.rowStatus" size="mini" style="width: 200px" clearable>
                   <el-option v-for="dict in dict.type.sys_row_status" :key="dict.value" :label="dict.label" :value="dict.value">
                   </el-option>
                 </el-select>
@@ -14,7 +14,7 @@
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="采购员">
-                <el-select clearable size="small" v-model="queryParams.buyer" @focus="chooseRefer('CONTACTS_PARAM', true, '采购员')" style="width: 200px">
+                <el-select clearable size="mini" v-model="queryParams.buyer" @focus="chooseRefer('CONTACTS_PARAM', true, '采购员')" style="width: 200px">
                   <el-option v-for="item in personOptions" :key="item.id" :label="item.name" :value="item.code" />
                 </el-select>
               </el-form-item>
@@ -23,7 +23,7 @@
               <el-form-item label="品类">
                 <el-select
                 v-model="queryParams.materialClassifyFourName"
-                size="small"
+                size="mini"
                 clearable
                 @focus="chooseTreeRefer('MATERIALCLASSIFY_PARAM', false, '选择品类')"
                 style="width: 200px"
@@ -34,8 +34,8 @@
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="" label-width="20px">
-                <el-button type="primary" size="small" icon="el-icon-search" plain @click="search">搜索</el-button>
-                <el-button size="small" icon="el-icon-refresh" plain @click="reset">重置</el-button>
+                <el-button type="primary" size="mini" icon="el-icon-search" plain @click="search">搜索</el-button>
+                <el-button size="mini" icon="el-icon-refresh" plain @click="reset">重置</el-button>
               </el-form-item>
             </el-col>
           </el-row>
@@ -47,7 +47,7 @@
                 <el-form-item label="生产厂家">
                   <el-input
                   v-model="queryParams.manufacturer"
-                  size="small"
+                  size="mini"
                   clearable
                   style="width: 200px"
                   />
@@ -55,7 +55,7 @@
               </el-col>
               <el-col :span="1.5">
                 <el-form-item label="预测分类">
-                  <el-select v-model="queryParams.forecastClassification" size="small" style="width: 200px" clearable>
+                  <el-select v-model="queryParams.forecastClassification" size="mini" style="width: 200px" clearable>
                     <el-option
                       v-for="dict in dict.type.predictive_classify" :key="dict.value" :label="dict.label" :value="dict.label">
                     </el-option>
@@ -64,14 +64,14 @@
               </el-col>
               <el-col :span="1.5">
                 <el-form-item label="审核人">
-                  <el-select clearable size="small" v-model="queryParams.puManagerAuditor" @focus="chooseRefer('CONTACTS_PARAM', true, '审核人')" style="width: 200px">
+                  <el-select clearable size="mini" v-model="queryParams.puManagerAuditor" @focus="chooseRefer('CONTACTS_PARAM', true, '审核人')" style="width: 200px">
                     <el-option v-for="item in auditOptions" :key="item.id" :label="item.name" :value="item.code" />
                   </el-select>
                 </el-form-item>
               </el-col>
               <!-- <el-col :span="1.5">
                 <el-form-item label="周期单位">
-                  <el-select v-model="queryParams.periodUnit" size="small" style="width: 200px" clearable>
+                  <el-select v-model="queryParams.periodUnit" size="mini" style="width: 200px" clearable>
                     <el-option
                       v-for="dict in dict.type.sys_period_unit" :key="dict.value" :label="dict.label" :value="dict.value">
                     </el-option>
@@ -85,7 +85,7 @@
                 <el-form-item label="转请购单号">
                   <el-input
                   v-model="queryParams.zqgdh"
-                  size="small"
+                  size="mini"
                   placeholder=""
                   clearable
                   style="width: 200px"
@@ -94,7 +94,7 @@
               </el-col> -->
               <!-- <el-col :span="1.5">
                 <el-form-item label="业务部门">
-                  <el-select clearable size="small" v-model="queryParams.departmentName" @focus="chooseRefer('DEPT_PARAM', true, '业务部门')" style="width: 200px">
+                  <el-select clearable size="mini" v-model="queryParams.departmentName" @focus="chooseRefer('DEPT_PARAM', true, '业务部门')" style="width: 200px">
                     <el-option v-for="item in deptOptions" :key="item.id" :label="item.name" :value="item.id" />
                   </el-select>
                 </el-form-item>
@@ -106,7 +106,7 @@
                 <el-form-item label="注册人">
                   <el-input
                   v-model="queryParams.registrant"
-                  size="small"
+                  size="mini"
                   clearable
                   style="width: 200px"
                   />
@@ -114,7 +114,7 @@
               </el-col>
               <el-col :span="1.5">
                 <el-form-item label="业务类型">
-                  <el-select v-model="queryParams.businessType" size="small" style="width: 200px" clearable>
+                  <el-select v-model="queryParams.businessType" size="mini" style="width: 200px" clearable>
                     <el-option
                       v-for="dict in dict.type.sys_business" :key="dict.value" :label="dict.label" :value="dict.value">
                     </el-option>
@@ -123,7 +123,7 @@
               </el-col>
               <el-col :span="1.5">
                 <el-form-item label="单据来源">
-                  <el-select v-model="queryParams.billSource" size="small" style="width: 200px" clearable>
+                  <el-select v-model="queryParams.billSource" size="mini" style="width: 200px" clearable>
                     <el-option
                       v-for="dict in dict.type.sys_bill_source" :key="dict.value" :label="dict.label" :value="dict.value">
                     </el-option>
@@ -135,28 +135,28 @@
             <el-row :gutter="10">
               <el-col :span="1.5">
                 <el-form-item label="需求客户">
-                  <el-select clearable size="small" v-model="queryParams.customer" @focus="chooseRefer('CUSTOMER_PARAM', true, '需求客户')" style="width: 200px">
+                  <el-select clearable size="mini" v-model="queryParams.customer" @focus="chooseRefer('CUSTOMER_PARAM', true, '需求客户')" style="width: 200px">
                     <el-option v-for="item in customerOptions" :key="item.id" :label="item.name" :value="item.id" />
                   </el-select>
                 </el-form-item>
               </el-col>
               <el-col :span="1.5">
                 <el-form-item label="末级供应仓库">
-                  <el-select clearable size="small" v-model="queryParams.lastWarehouse" @focus="chooseRefer('WAREHOUSE_PARAM', true, '末级供应仓库')" style="width: 200px">
+                  <el-select clearable size="mini" v-model="queryParams.lastWarehouse" @focus="chooseRefer('WAREHOUSE_PARAM', true, '末级供应仓库')" style="width: 200px">
                     <el-option v-for="item in lastWarehouseOptions" :key="item.id" :label="item.name" :value="item.id" />
                   </el-select>
                 </el-form-item>
               </el-col>
               <el-col :span="1.5">
                 <el-form-item label="末级供应库位">
-                  <el-select clearable size="small" v-model="queryParams.lastAllocation" @focus="chooseRefer('ALLOCATION_PARAM', true, '末级供应库位', queryParams.lastWarehouse)" style="width: 200px">
+                  <el-select clearable size="mini" v-model="queryParams.lastAllocation" @focus="chooseRefer('ALLOCATION_PARAM', true, '末级供应库位', queryParams.lastWarehouse)" style="width: 200px">
                     <el-option v-for="item in lastAllocationOptions" :key="item.id" :label="item.name" :value="item.id" />
                   </el-select>
                 </el-form-item>
               </el-col>
               <!-- <el-col :span="1.5">
                 <el-form-item label="转请购时间">
-                  <el-select v-model="queryParams.ywlx" size="small" style="width: 200px" clearable>
+                  <el-select v-model="queryParams.ywlx" size="mini" style="width: 200px" clearable>
                     <el-option
                       v-for="item in options"
                       :key="item.value"
@@ -171,15 +171,15 @@
             <el-row :gutter="10">
               <el-col :span="1.5">
                 <el-form-item label="物料编码">
-                  <el-input clearable size="small" v-model="queryParams.names" @focus="chooseMaterial" style="width: 200px">
-                    <el-button size="small" slot="append" icon="el-icon-more" @click="chooseMaterial"></el-button>
+                  <el-input clearable size="mini" v-model="queryParams.names" @focus="chooseMaterial" style="width: 200px">
+                    <el-button size="mini" slot="append" icon="el-icon-more" @click="chooseMaterial"></el-button>
                   </el-input>
                   <el-input v-show="false" v-model="queryParams.materialCode"></el-input>
                 </el-form-item>
               </el-col>
               <el-col :span="1.5">
                 <el-form-item label="默认采购组织">
-                  <el-select clearable size="small" v-model="queryParams.purchaseOrg" @focus="chooseRefer('ORG_PARAM', true, '默认采购组织')" style="width: 200px">
+                  <el-select clearable size="mini" v-model="queryParams.purchaseOrg" @focus="chooseRefer('ORG_PARAM', true, '默认采购组织')" style="width: 200px">
                     <el-option v-for="item in orgOptions" :key="item.id" :label="item.name" :value="item.id" />
                   </el-select>
                 </el-form-item>
@@ -190,7 +190,7 @@
                     v-model="queryParams.demandDate"
                     type="date"
                     value-format="yyyy-MM-dd"
-                    size="small"
+                    size="mini"
                     style="width: 200px"
                   >
                   </el-date-picker>
@@ -203,7 +203,7 @@
                 <el-form-item label="采购需求单号">
                   <el-input
                   v-model.trim="queryParams.code"
-                  size="small"
+                  size="mini"
                   clearable
                   style="width: 200px"
                   />
@@ -216,7 +216,7 @@
                     type="date"
                     clearable
                     value-format="yyyy-MM-dd"
-                    size="small"
+                    size="mini"
                     style="width: 200px"
                   >
                   </el-date-picker>
@@ -230,16 +230,16 @@
     
       
         <div class="btn_grooup">
-          <el-button type="primary" size="small" @click="editList">编辑</el-button>
-          <el-button type="danger" size="small" v-if="!lineDisable" @click="cancelEdit">取消编辑</el-button>
-          <el-button type="success" size="small" v-if="!lineDisable" @click="saveList">保存</el-button>
-          <el-button type="primary" size="small" @click="confirms">确认</el-button>
-          <el-button type="primary" size="small" @click="cancels">取消</el-button>
-          <el-button type="primary" size="small" @click="audits">审核</el-button>
-          <el-button type="primary" size="small" @click="closeLine">行关闭</el-button>
+          <el-button type="primary" size="mini" @click="editList">编辑</el-button>
+          <el-button type="danger" size="mini" v-if="!lineDisable" @click="cancelEdit">取消编辑</el-button>
+          <el-button type="success" size="mini" v-if="!lineDisable" @click="saveList">保存</el-button>
+          <el-button type="primary" size="mini" @click="confirms">确认</el-button>
+          <el-button type="primary" size="mini" @click="cancels">取消</el-button>
+          <el-button type="primary" size="mini" @click="audits">审核</el-button>
+          <el-button type="primary" size="mini" @click="closeLine">行关闭</el-button>
 
-          <el-dropdown size="small" @command="handleCommand">
-            <el-button size="small" type="primary" style="margin: 0 10px;">
+          <el-dropdown size="mini" @command="handleCommand">
+            <el-button size="mini" type="primary" style="margin: 0 10px;">
               导出<i class="el-icon-arrow-down el-icon--right"></i>
             </el-button>
             <el-dropdown-menu slot="dropdown">
@@ -248,7 +248,7 @@
             </el-dropdown-menu>
           </el-dropdown>
 
-          <!-- <el-button type="primary" size="small">转请购</el-button> -->
+          <!-- <el-button type="primary" size="mini">转请购</el-button> -->
         </div>
         <el-table 
           :data="tableList" 
@@ -306,15 +306,15 @@
           <el-table-column show-overflow-tooltip label="四级品类" align="center" prop="materialClassifyFourName" width="150px"/>
           <el-table-column show-overflow-tooltip label="采购员" align="center" prop="buyerName" width="150px">
             <template slot-scope="scope">
-                <el-input readonly :disabled="scope.row.status !== '1' || lineDisable" size="small" v-model="scope.row.buyerName">
-                  <el-button size="small" :disabled="scope.row.status !== '1' || lineDisable" slot="append" icon="el-icon-more" @click="chooseSon(scope.$index, 'CONTACTS_PARAM', true, '采购员')"></el-button>
+                <el-input readonly :disabled="scope.row.status !== '1' || lineDisable" size="mini" v-model="scope.row.buyerName">
+                  <el-button size="mini" :disabled="scope.row.status !== '1' || lineDisable" slot="append" icon="el-icon-more" @click="chooseSon(scope.$index, 'CONTACTS_PARAM', true, '采购员')"></el-button>
                 </el-input>
             </template>
           </el-table-column>
           <el-table-column show-overflow-tooltip label="默认采购组织" align="center" prop="purchaseOrgName" width="280px">
             <template slot-scope="scope">
-                <el-input readonly :disabled="scope.row.status !== '1' || lineDisable" size="small" v-model="scope.row.purchaseOrgName">
-                  <el-button size="small" :disabled="scope.row.status !== '1' || lineDisable" slot="append" icon="el-icon-more" @click="chooseSon(scope.$index, 'ORG_PARAM', true, '默认采购组织')"></el-button>
+                <el-input readonly :disabled="scope.row.status !== '1' || lineDisable" size="mini" v-model="scope.row.purchaseOrgName">
+                  <el-button size="mini" :disabled="scope.row.status !== '1' || lineDisable" slot="append" icon="el-icon-more" @click="chooseSon(scope.$index, 'ORG_PARAM', true, '默认采购组织')"></el-button>
                 </el-input>
             </template>
           </el-table-column>
@@ -340,7 +340,7 @@
           width="100"
           >
           <template slot-scope="scope">
-            <el-button type="text" size="small" @click="check(scope.row)">查看</el-button>
+            <el-button type="text" size="mini" @click="check(scope.row)">查看</el-button>
           </template>
         </el-table-column>
         </el-table>
@@ -358,7 +358,7 @@
       </el-card>
     </div>
 
-    <Add v-model="isList" v-if="!isList" :pageStu="page" :disable="disable" :row="rowDetail" @refresh="reset"/>
+    <Add v-model="isList" v-if="!isList" :pageStu="page" :disable="disable" :row="rowDetail" :query="queryParams" @refresh="reset"/>
   
     <Refers ref="refer" @doSubmit="selectionsToInput" :single="true"/>
 

+ 21 - 21
src/views/purchase/MaterialClassDivision/add.vue

@@ -4,7 +4,7 @@
       <el-row :gutter="10">
         <el-col :span="1.5">
             <el-form-item label="物料分类编码">
-              <el-input :disabled="disable"  size="small" style="width: 200px" readonly v-model="basicForm.materialClassify">
+              <el-input :disabled="disable"  size="mini" style="width: 200px" readonly v-model="basicForm.materialClassify">
                 <el-button slot="append" icon="el-icon-more" @click="chooseFourClass"></el-button>
               </el-input>
             </el-form-item>
@@ -14,7 +14,7 @@
             <el-form-item label="物料分类名称">
               <el-input
                 v-model="basicForm.materialClassifyName"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -26,7 +26,7 @@
             <el-form-item label="一级分类编码">
               <el-input
                 v-model="basicForm.materialClassifyOne"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -38,7 +38,7 @@
             <el-form-item label="一级分类名称">
               <el-input
                 v-model="basicForm.materialClassifyOneName"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -50,7 +50,7 @@
             <el-form-item label="二级分类名称">
               <el-input
                 v-model="basicForm.materialClassifyTwoName"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -62,7 +62,7 @@
             <el-form-item label="三级分类名称">
               <el-input
                 v-model="basicForm.materialClassifyThreeName"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -74,7 +74,7 @@
             <el-form-item label="四级分类名称">
               <el-input
                 v-model="basicForm.materialClassifyFourName"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -84,10 +84,10 @@
 
           <el-col :span="1.5">
             <el-form-item label="物料编码">
-              <el-input :disabled="disable" style="width: 200px" size="small" readonly v-model="basicForm.materialCode">
+              <el-input :disabled="disable" style="width: 200px" size="mini" readonly v-model="basicForm.materialCode">
                   <el-button slot="append" icon="el-icon-more" @click="test01"></el-button>
               </el-input>
-              <el-input v-show="false" style="width: 200px" size="small" v-model="basicForm.material"></el-input>
+              <el-input v-show="false" style="width: 200px" size="mini" v-model="basicForm.material"></el-input>
             </el-form-item>
           </el-col>
 
@@ -95,7 +95,7 @@
             <el-form-item label="物料名称">
               <el-input
                 v-model="basicForm.materialName"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -107,7 +107,7 @@
             <el-form-item label="生产厂家">
               <el-input
                 v-model="basicForm.manufacturer"
-                size="small"
+                size="mini"
                 :disabled="disable"
                 clearable
                 style="width: 200px"
@@ -120,7 +120,7 @@
               <el-select
                     ref="organizations"
                     v-model="basicForm.org"
-                    size="small"
+                    size="mini"
                     style="width: 200px"
                     :disabled="disable"
                     clearable
@@ -140,7 +140,7 @@
             <el-form-item label="订单员">
               <el-select
                   ref="staffs"
-                  size="small"
+                  size="mini"
                   style="width: 200px"
                   :disabled="disable"
                   v-model="basicForm.orderPersonal"
@@ -161,7 +161,7 @@
             <el-form-item label="订单部门">
               <el-input
                 v-model="basicForm.orderDeptName"
-                size="small"
+                size="mini"
                 disabled
                 style="width: 200px"
               />
@@ -172,7 +172,7 @@
             <el-form-item label="采购员">
               <el-select
                   ref="staffs2"
-                  size="small"
+                  size="mini"
                   style="width: 200px"
                   :disabled="disable"
                   v-model="basicForm.buyer"
@@ -193,7 +193,7 @@
             <el-form-item label="采购部门">
               <el-input
                 v-model="basicForm.puDeptName"
-                size="small"
+                size="mini"
                 disabled
                 style="width: 200px"
               />
@@ -204,7 +204,7 @@
             <el-form-item label="同步状态">
               <el-input
                 v-model="basicForm.sendStatus"
-                size="small"
+                size="mini"
                 disabled
                 style="width: 200px"
               />
@@ -215,7 +215,7 @@
             <el-form-item label="备注">
               <el-input
                 v-model="basicForm.remark"
-                size="small"
+                size="mini"
                 :disabled="disable"
                 clearable
                 style="width: 200px"
@@ -227,13 +227,13 @@
 
     <div class="btn_group">
       <el-col :span="1.5" style="margin: 0 10px;">
-        <el-button type="primary" size="small" plain @click="save" v-if="pageStu == 'add' || pageStu == 'edit'">保存</el-button>
+        <el-button type="primary" size="mini" plain @click="save" v-if="pageStu == 'add' || pageStu == 'edit'">保存</el-button>
       </el-col>
       <!-- <el-col :span="1.5" style="margin: 0 10px;">
-        <el-button type="primary" size="small" plain @click="submit" v-if="pageStu == 'edit'">提交</el-button>
+        <el-button type="primary" size="mini" plain @click="submit" v-if="pageStu == 'edit'">提交</el-button>
       </el-col> -->
       <el-col :span="1.5">
-        <el-button size="small" plain @click="back">返回</el-button>
+        <el-button size="mini" plain @click="back">返回</el-button>
       </el-col>
     </div>
 

+ 25 - 25
src/views/purchase/MaterialClassDivision/index.vue

@@ -8,7 +8,7 @@
               <el-input
                 v-model="queryParams.materialClassifyOne"
                 clearable
-                size="small"
+                size="mini"
                 style="width: 200px"
               />
             </el-form-item>
@@ -18,7 +18,7 @@
               <el-input
                 v-model="queryParams.materialClassifyOneName"
                 clearable
-                size="small"
+                size="mini"
                 style="width: 200px"
               />
             </el-form-item>
@@ -28,7 +28,7 @@
               <el-input
                 v-model="queryParams.materialClassifyTwo"
                 clearable
-                size="small"
+                size="mini"
                 style="width: 200px"
               />
             </el-form-item>
@@ -38,15 +38,15 @@
               <el-input
                 v-model="queryParams.materialClassifyTwoName"
                 clearable
-                size="small"
+                size="mini"
                 style="width: 200px"
               />
             </el-form-item>
           </el-col>
           <el-col :span="1.5">
             <el-form-item label="" label-width="20px">
-              <el-button type="primary" size="small" icon="el-icon-search" plain @click="searchList">搜索</el-button>
-              <el-button size="small" icon="el-icon-refresh" plain @click="resetList">重置</el-button>
+              <el-button type="primary" size="mini" icon="el-icon-search" plain @click="searchList">搜索</el-button>
+              <el-button size="mini" icon="el-icon-refresh" plain @click="resetList">重置</el-button>
             </el-form-item>
           </el-col>
         </el-row>
@@ -59,7 +59,7 @@
               <el-input
                 v-model="queryParams.materialClassifyThree"
                 clearable
-                size="small"
+                size="mini"
                 style="width: 200px"
               />
             </el-form-item>
@@ -69,14 +69,14 @@
               <el-input
                 v-model="queryParams.materialClassifyThreeName"
                 clearable
-                size="small"
+                size="mini"
                 style="width: 200px"
               />
             </el-form-item>
           </el-col>
           <el-col :span="1.5">
             <el-form-item label="物料四级大类编码">
-              <el-input size="small" style="width: 200px" readonly v-model="queryParams.materialClassifyFour">
+              <el-input size="mini" style="width: 200px" readonly v-model="queryParams.materialClassifyFour">
                 <el-button slot="append" icon="el-icon-more" @click="chooseFourClass"></el-button>
               </el-input>
             </el-form-item>
@@ -86,7 +86,7 @@
               <el-input
                 v-model="queryParams.materialClassifyFourName"
                 clearable
-                size="small"
+                size="mini"
                 style="width: 200px"
               />
             </el-form-item>
@@ -96,7 +96,7 @@
         <el-row :gutter="10">
           <el-col :span="1.5">
             <el-form-item label="物料编码">
-              <el-input style="width: 200px" size="small" readonly v-model="queryParams.material">
+              <el-input style="width: 200px" size="mini" readonly v-model="queryParams.material">
                   <el-button slot="append" icon="el-icon-more" @click="test01"></el-button>
               </el-input>
             </el-form-item>
@@ -106,7 +106,7 @@
               <el-input
                 v-model="queryParams.materialName"
                 clearable
-                size="small"
+                size="mini"
                 style="width: 200px"
               />
             </el-form-item>
@@ -115,7 +115,7 @@
             <el-form-item label="订单员">
               <el-select
                   ref="staffs"
-                  size="small"
+                  size="mini"
                   style="width: 200px"
                   v-model="queryParams.orderPersonal"
                   clearable
@@ -134,7 +134,7 @@
             <el-form-item label="采购员">
               <el-select
                   ref="staffs2"
-                  size="small"
+                  size="mini"
                   style="width: 200px"
                   v-model="queryParams.buyer"
                   clearable
@@ -156,7 +156,7 @@
             <el-form-item label="生产厂家">
             <el-input
               v-model="queryParams.manufacturer"
-              size="small"
+              size="mini"
               placeholder=""
               clearable
               style="width: 200px"
@@ -167,7 +167,7 @@
             <el-form-item label="备注">
             <el-input
               v-model="queryParams.remark"
-              size="small"
+              size="mini"
               placeholder=""
               clearable
               style="width: 200px"
@@ -182,10 +182,10 @@
 
       <el-card>
         <div class="btn_grooup">
-          <el-button type="primary" size="small" @click="addDivision">新增</el-button>
+          <el-button type="primary" size="mini" @click="addDivision">新增</el-button>
 
-          <el-dropdown size="small" @command="handleCommand">
-            <el-button size="small" type="primary" style="margin-left: 10px;">
+          <el-dropdown size="mini" @command="handleCommand">
+            <el-button size="mini" type="primary" style="margin-left: 10px;">
               导入<i class="el-icon-arrow-down el-icon--right"></i>
             </el-button>
             <el-dropdown-menu slot="dropdown">
@@ -194,8 +194,8 @@
             </el-dropdown-menu>
           </el-dropdown>
 
-          <el-dropdown size="small" @command="handleCommand">
-            <el-button size="small" type="primary" style="margin: 0 10px;">
+          <el-dropdown size="mini" @command="handleCommand">
+            <el-button size="mini" type="primary" style="margin: 0 10px;">
               导出<i class="el-icon-arrow-down el-icon--right"></i>
             </el-button>
             <el-dropdown-menu slot="dropdown">
@@ -204,7 +204,7 @@
             </el-dropdown-menu>
           </el-dropdown>
 
-          <el-button type="primary" size="small">删除</el-button>
+          <el-button type="primary" size="mini">删除</el-button>
         </div>
         <el-table 
           :data="tableList" 
@@ -238,9 +238,9 @@
           width="150"
           >
           <template slot-scope="scope">
-            <el-button type="text" size="small" @click="check(scope.row)">查看</el-button>
-            <el-button type="text" size="small" @click="edit(scope.row)">编辑</el-button>
-            <el-button type="text" size="small" @click="deleteids(scope.row)">删除</el-button>
+            <el-button type="text" size="mini" @click="check(scope.row)">查看</el-button>
+            <el-button type="text" size="mini" @click="edit(scope.row)">编辑</el-button>
+            <el-button type="text" size="mini" @click="deleteids(scope.row)">删除</el-button>
           </template>
         </el-table-column>
         </el-table>

+ 263 - 55
src/views/purchase/PurchaseDemandList/add.vue

@@ -1,5 +1,6 @@
 <template>
   <div id="addDemandList">
+    <el-card>
     <span>基本信息</span>
     <el-form :model="basicForm" :rules="basicRules" ref="basic" label-width="auto">
       <el-row :gutter="10">
@@ -7,7 +8,7 @@
             <el-form-item label="编码">
               <el-input
                 v-model="basicForm.code"
-                size="small"
+                size="mini"
                 disabled
                 style="width: 200px"
               />
@@ -16,7 +17,7 @@
 
         <el-col :span="1.5">
             <el-form-item label="组织" prop="org" :rules="{ required: true, message: '请选择组织', trigger: 'blur' }">
-              <el-select clearable size="small" v-model="basicForm.org" :disabled="sonDisable" @focus="chooseOrg('ORG_PARAM', true, '选择组织')" style="width: 200px">
+              <el-select clearable size="mini" v-model="basicForm.org" :disabled="sonDisable" @focus="chooseOrg('ORG_PARAM', true, '选择组织')" style="width: 200px">
                 <el-option v-for="item in orgOptions" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
@@ -24,7 +25,7 @@
 
          <el-col :span="1.5">
             <el-form-item label="需求处理方式">
-              <el-select disabled v-model="basicForm.demandBusinessType" size="small" style="width: 200px">
+              <el-select disabled v-model="basicForm.demandBusinessType" size="mini" style="width: 200px">
                 <el-option v-for="dict in dict.type.sys_processing_mode" :key="dict.value" :label="dict.label" :value="dict.value">
                 </el-option>
               </el-select>
@@ -33,7 +34,7 @@
 
          <el-col :span="1.5">
             <el-form-item label="单据状态">
-              <el-select disabled v-model="basicForm.status" size="small" style="width: 200px">
+              <el-select disabled v-model="basicForm.status" size="mini" style="width: 200px">
                 <el-option v-for="dict in dict.type.sys_status" :key="dict.value" :label="dict.label" :value="dict.value">
                 </el-option>
               </el-select>
@@ -42,7 +43,7 @@
 
          <el-col :span="1.5">
             <el-form-item label="需求客户">
-              <el-select clearable size="small" v-model="basicForm.customer" :disabled="sonDisable" @clear="cleanCustomer" @focus="chooseOrg('CUSTOMER_PARAM', true, '选择客户')" style="width: 200px">
+              <el-select clearable size="mini" v-model="basicForm.customer" :disabled="sonDisable" @clear="cleanCustomer" @focus="chooseOrg('CUSTOMER_PARAM', true, '选择客户')" style="width: 200px">
                 <el-option v-for="item in customerOptions" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
@@ -50,13 +51,13 @@
 
          <el-col :span="1.5">
             <el-form-item label="需求客户名称">
-              <el-input disabled v-model="basicForm.customerName" size="small" style="width: 200px"></el-input>
+              <el-input disabled v-model="basicForm.customerName" size="mini" style="width: 200px"></el-input>
             </el-form-item>
           </el-col>
 
          <el-col :span="1.5">
             <el-form-item label="客户负责人">
-              <el-select disabled size="small" v-model="basicForm.customerPrincipal" style="width: 200px">
+              <el-select disabled size="mini" v-model="basicForm.customerPrincipal" style="width: 200px">
                 <el-option v-for="item in manOptions" :key="item.id" :label="item.name" :value="item.code"/>
               </el-select>
             </el-form-item>
@@ -64,7 +65,7 @@
 
          <el-col :span="1.5">
             <el-form-item label="需求人员">
-                <el-select clearable size="small" v-model="basicForm.demandPersonal" :disabled="sonDisable" @focus="chooseOrg('CONTACTS_PARAM', true, '需求人员')" style="width: 200px">
+                <el-select clearable size="mini" v-model="basicForm.demandPersonal" :disabled="sonDisable" @focus="chooseOrg('CONTACTS_PARAM', true, '需求人员')" style="width: 200px">
                   <el-option v-for="item in personOptions" :key="item.id" :label="item.name" :value="item.code" />
                 </el-select>
             </el-form-item>
@@ -72,7 +73,7 @@
 
          <el-col :span="1.5">
             <el-form-item label="需求部门">
-              <el-select clearable v-model="basicForm.demandDept" size="small" :disabled="sonDisable" @focus="chooseOrg('DEPT_PARAM', true, '需求部门')" style="width: 200px">
+              <el-select clearable v-model="basicForm.demandDept" size="mini" :disabled="sonDisable" @focus="chooseOrg('DEPT_PARAM', true, '需求部门')" style="width: 200px">
                 <el-option
                   v-for="item in deptOptions"
                   :key="item.id"
@@ -92,7 +93,7 @@
                 type="date"
                 value-format="yyyy-MM-dd"
                 @change="changeDemandDate"
-                size="small"
+                size="mini"
                 style="width: 200px"
               >
               </el-date-picker>
@@ -101,7 +102,7 @@
 
           <el-col :span="1.5">
             <el-form-item label="单据来源">
-              <el-select v-model="basicForm.source" disabled size="small" style="width: 200px">
+              <el-select v-model="basicForm.source" disabled size="mini" style="width: 200px">
                 <el-option v-for="dict in dict.type.sys_bill_source" :key="dict.value" :label="dict.label" :value="dict.value">
                 </el-option>
               </el-select>
@@ -110,7 +111,7 @@
 
          <el-col :span="1.5">
             <el-form-item label="业务类型">
-              <el-select clearable v-model="basicForm.billType" @change="changeBillType" :disabled="sonDisable" size="small" style="width: 200px">
+              <el-select clearable v-model="basicForm.billType" @change="changeBillType" :disabled="sonDisable" size="mini" style="width: 200px">
                 <el-option v-for=" dict in dict.type.sys_business" :key="dict.value" :label="dict.label" :value="dict.value">
                 </el-option>
               </el-select>
@@ -119,7 +120,7 @@
 
           <el-col :span="1.5">
             <el-form-item label="是否客户指定">
-              <el-select clearable v-model="basicForm.isSpeical" :disabled="sonDisable" size="small" style="width: 200px">
+              <el-select clearable v-model="basicForm.isSpeical" :disabled="sonDisable" size="mini" style="width: 200px">
                 <el-option v-for=" item in options" :key="item.value" :label="item.label" :value="item.value">
                 </el-option>
               </el-select>
@@ -130,7 +131,7 @@
             <el-form-item label="是否处理需求">
               <el-input
                 v-model="basicForm.isProcess"
-                size="small"
+                size="mini"
                 placeholder=""
                 clearable
                 style="width: 200px"
@@ -142,7 +143,7 @@
             <el-form-item label="备注">
               <el-input
                 v-model.trim="basicForm.remark"
-                size="small"
+                size="mini"
                 :disabled="sonDisable"
                 clearable
                 style="width: 200px"
@@ -153,11 +154,10 @@
     
 
     <span>明细信息</span>
-    <el-card>
       <div class="btn_grooup">
-        <el-button type="primary" size="small" @click="addLine" v-if="!sonDisable">增行</el-button>
-        <el-button type="primary" size="small" v-if="!sonDisable">批量调整</el-button>
-        <el-button type="primary" size="small" v-if="sonPageStu == 'check' || sonPageStu == 'edit'" @click="showReserved">货权预留单</el-button>
+        <el-button type="primary" size="mini" @click="addLine" v-if="!sonDisable">增行</el-button>
+        <el-button type="primary" size="mini" v-if="!sonDisable" @click="adjustPl">批量调整</el-button>
+        <el-button type="primary" size="mini" v-if="sonPageStu == 'check' || sonPageStu == 'edit'" @click="showReserved">货权预留单</el-button>
       </div>
 
       <el-table 
@@ -169,35 +169,39 @@
           <el-table-column show-overflow-tooltip type="selection"/>
           <el-table-column show-overflow-tooltip label="序号" type="index" align="center"/>
           <el-table-column show-overflow-tooltip label="行状态" align="center" prop="status" :formatter="hangStatus" width="150px"/>
-          <el-table-column show-overflow-tooltip label="行号" align="center" prop="rowNo" />
+          <el-table-column show-overflow-tooltip label="行号" align="center" prop="rowNo">
+            <template slot-scope="scope">
+              {{scope.$index + 1 + '0'}}
+            </template>
+          </el-table-column>
           <!-- <el-table-column show-overflow-tooltip label="业务部门名称" align="center" width="180px"/> -->
           <!-- <el-table-column show-overflow-tooltip label="业务部门" align="center" width="180px"/> -->
           <el-table-column show-overflow-tooltip label="需求客户" align="center"  prop="demandCustomerName" width="200px"/>
           <el-table-column show-overflow-tooltip label="一级品类" align="center" prop="materialClassifyOneName" width="180px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input readonly size="small" v-model="scope.row.materialClassifyOneName"/>
+                <el-input readonly size="mini" v-model="scope.row.materialClassifyOneName"/>
               </el-form-item>
             </template>
           </el-table-column>
           <el-table-column show-overflow-tooltip label="二级品类" align="center" prop="materialClassifyTwoName" width="180px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input readonly size="small" v-model="scope.row.materialClassifyTwoName"/>
+                <el-input readonly size="mini" v-model="scope.row.materialClassifyTwoName"/>
               </el-form-item>
             </template>
           </el-table-column>
           <el-table-column show-overflow-tooltip label="三级品类" align="center" prop="materialClassifyThreeName" width="180px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input readonly size="small" v-model="scope.row.materialClassifyThreeName"/>
+                <el-input readonly size="mini" v-model="scope.row.materialClassifyThreeName"/>
               </el-form-item>
             </template>
           </el-table-column>
           <el-table-column show-overflow-tooltip label="四级品类" align="center" prop="materialClassifyFourName" width="180px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input readonly size="small" v-model="scope.row.materialClassifyFourName"/>
+                <el-input readonly size="mini" v-model="scope.row.materialClassifyFourName"/>
               </el-form-item>
             </template>
           </el-table-column>
@@ -206,8 +210,8 @@
           <el-table-column show-overflow-tooltip label="物料编码" align="center" prop="materialCode" width="230px">
             <template slot-scope="scope">
               <el-form-item class="hang" :prop="'puDemandItemList.' + scope.$index + '.' + 'materialCode'" :rules="{ required: true, message: '请选择物料编码', trigger: 'blur' }">
-                <el-input clearable :disabled="sonDisable" size="small" v-model="scope.row.materialCode" @focus="chooseMaterial(scope.$index)">
-                  <el-button size="small" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseMaterial(scope.$index)"></el-button>
+                <el-input clearable :disabled="sonDisable" size="mini" v-model="scope.row.materialCode" @focus="chooseMaterial(scope.$index)">
+                  <el-button size="mini" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseMaterial(scope.$index)"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -221,7 +225,7 @@
           <el-table-column show-overflow-tooltip label="采购周期" align="center"  prop="puPeriod" width="150px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :readonly="sonDisable" size="small" v-model="scope.row.puPeriod"/>
+                <el-input clearable :readonly="sonDisable" size="mini" v-model="scope.row.puPeriod"/>
               </el-form-item>
             </template>
           </el-table-column>
@@ -233,14 +237,14 @@
           <el-table-column show-overflow-tooltip label="安全库存" align="center"  prop="safeStock" width="120px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :readonly="sonDisable" size="small" v-model="scope.row.safeStock"/>
+                <el-input clearable :readonly="sonDisable" size="mini" v-model="scope.row.safeStock"/>
               </el-form-item>
             </template>
           </el-table-column>
             <el-table-column show-overflow-tooltip label="预留比例" align="center" prop="reservedProportion" width="150px">
               <template slot-scope="scope">
                 <el-form-item class="hang">
-                  <el-select clearable :disabled="sonDisable" size="small" v-model="scope.row.reservedProportion" @change="getYLSL(scope)">
+                  <el-select clearable :disabled="sonDisable" size="mini" v-model="scope.row.reservedProportion" @change="getYLSL(scope)">
                     <el-option v-for=" dict in dict.type.sys_reserve_ratio" :key="dict.value" :label="dict.label" :value="dict.value">
                     </el-option>
                   </el-select>
@@ -251,14 +255,14 @@
             <el-table-column show-overflow-tooltip label="预留周期" align="center" prop="reservedPeriod" width="150px">
               <template slot-scope="scope">
                 <el-form-item class="hang" :prop="'puDemandItemList.' + scope.$index + '.' + 'reservedPeriod'" :rules="{ required: isYl, message: '请填写预留周期', trigger: 'blur' }">
-                  <el-input clearable :readonly="sonDisable" size="small" v-model="scope.row.reservedPeriod"/>
+                  <el-input clearable :readonly="sonDisable" size="mini" v-model="scope.row.reservedPeriod"/>
                 </el-form-item>
               </template>
             </el-table-column>
             <el-table-column show-overflow-tooltip label="预留数量" align="center"  prop="reservedQty" width="150px">
               <template slot-scope="scope">
                 <el-form-item class="hang">
-                  <el-input readonly size="small" v-model="scope.row.reservedQty"/>
+                  <el-input readonly size="mini" v-model="scope.row.reservedQty"/>
                 </el-form-item>
               </template>
             </el-table-column>
@@ -266,7 +270,7 @@
           <el-table-column show-overflow-tooltip label="实际(业务)需求量" align="center"  prop="qty" width="120px">
             <template slot-scope="scope">
               <el-form-item class="hang" :prop="'puDemandItemList.' + scope.$index + '.' + 'qty'" :rules="{ required: true, message: '请填写实际(业务)需求量', trigger: 'blur' }">
-                <el-input clearable :readonly="sonDisable" size="small" v-model="scope.row.qty" @input="getYLSL(scope)"/>
+                <el-input clearable :readonly="sonDisable" size="mini" v-model="scope.row.qty" @input="getYLSL(scope)"/>
               </el-form-item>
             </template>
           </el-table-column>
@@ -282,7 +286,7 @@
                   :readonly="sonDisable"
                   clearable
                   type="date"
-                  size="small"
+                  size="mini"
                   value-format="yyyy-MM-dd"
                   :picker-options="pickerOptionsEnd"
                   placeholder="选择日期">
@@ -321,7 +325,7 @@
           <el-table-column show-overflow-tooltip label="业务备注" align="center"  prop="remark" width="150px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :readonly="sonDisable" size="small" v-model="scope.row.remark"/>
+                <el-input clearable :readonly="sonDisable" size="mini" v-model="scope.row.remark"/>
               </el-form-item>
             </template>
           </el-table-column> 
@@ -331,7 +335,7 @@
           <el-table-column show-overflow-tooltip label="最终净需求量" align="center"  prop="resDemandQty" width="150px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :readonly="sonDisable" size="small" v-model="scope.row.resDemandQty"/>
+                <el-input clearable :readonly="sonDisable" size="mini" v-model="scope.row.resDemandQty"/>
               </el-form-item>
             </template>
           </el-table-column>
@@ -343,8 +347,8 @@
           <el-table-column show-overflow-tooltip label="收货仓库" align="center"  prop="deliveryWarehouseName" width="200px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :disabled="sonDisable" size="small" v-model="scope.row.deliveryWarehouseName" @clear="clearHang(scope.$index, '选择收货仓库')" @focus="chooseDept(scope.$index, 'WAREHOUSE_PARAM', true, '选择收货仓库')">
-                  <el-button size="small" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseDept(scope.$index, 'WAREHOUSE_PARAM', true, '选择收货仓库')"></el-button>
+                <el-input clearable :disabled="sonDisable" size="mini" v-model="scope.row.deliveryWarehouseName" @clear="clearHang(scope.$index, '选择收货仓库')" @focus="chooseDept(scope.$index, 'WAREHOUSE_PARAM', true, '选择收货仓库')">
+                  <el-button size="mini" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseDept(scope.$index, 'WAREHOUSE_PARAM', true, '选择收货仓库')"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -352,8 +356,8 @@
           <el-table-column show-overflow-tooltip label="收货货位" align="center"  prop="deliveryAllocationName" width="200px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :disabled="sonDisable" size="small" v-model="scope.row.deliveryAllocationName" @clear="clearHang(scope.$index, '选择收货货位')" @focus="choosehuoWei(scope.$index, 'ALLOCATION_PARAM', true, '选择收货货位', scope.row.deliveryWarehouse)">
-                  <el-button size="small" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="choosehuoWei(scope.$index, 'ALLOCATION_PARAM', true, '选择收货货位', scope.row.deliveryWarehouse)"></el-button>
+                <el-input clearable :disabled="sonDisable" size="mini" v-model="scope.row.deliveryAllocationName" @clear="clearHang(scope.$index, '选择收货货位')" @focus="choosehuoWei(scope.$index, 'ALLOCATION_PARAM', true, '选择收货货位', scope.row.deliveryWarehouse)">
+                  <el-button size="mini" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="choosehuoWei(scope.$index, 'ALLOCATION_PARAM', true, '选择收货货位', scope.row.deliveryWarehouse)"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -398,8 +402,8 @@
           <el-table-column show-overflow-tooltip label="补单供应商编码" align="center"  prop="additionalSupplier" width="200px">
             <template slot-scope="scope">
               <el-form-item class="hang" :prop="'puDemandItemList.' + scope.$index + '.' + 'additionalSupplier'" :rules="{ required: isBDXQ, message: '请选择补单供应商', trigger: 'blur' }">
-                <el-input clearable :disabled="sonDisable || BDZT" size="small" v-model="scope.row.additionalSupplier" @clear="clearHang(scope.$index, '选择补单供应商')" @focus="chooseDept(scope.$index, 'SUPPLIER_PARAM', true, '选择补单供应商')">
-                  <el-button size="small" :disabled="sonDisable || BDZT" slot="append" icon="el-icon-more" @click="chooseDept(scope.$index, 'SUPPLIER_PARAM', true, '选择补单供应商')"></el-button>
+                <el-input clearable :disabled="sonDisable || BDZT" size="mini" v-model="scope.row.additionalSupplier" @clear="clearHang(scope.$index, '选择补单供应商')" @focus="chooseDept(scope.$index, 'SUPPLIER_PARAM', true, '选择补单供应商')">
+                  <el-button size="mini" :disabled="sonDisable || BDZT" slot="append" icon="el-icon-more" @click="chooseDept(scope.$index, 'SUPPLIER_PARAM', true, '选择补单供应商')"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -407,14 +411,14 @@
           <el-table-column show-overflow-tooltip label="补单供应商名称" align="center"  prop="additionalSupplierName" width="200px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input readonly size="small" v-model="scope.row.additionalSupplierName"/>
+                <el-input readonly size="mini" v-model="scope.row.additionalSupplierName"/>
               </el-form-item>
             </template>
           </el-table-column>
           <!-- <el-table-column show-overflow-tooltip label="周期单位" align="center"  prop="periodUnit" width="150px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-select clearable :disabled="sonDisable" size="small" v-model="scope.row.periodUnit">
+                <el-select clearable :disabled="sonDisable" size="mini" v-model="scope.row.periodUnit">
                   <el-option v-for=" dict in dict.type.sys_period_unit" :key="dict.value" :label="dict.label" :value="dict.value">
                   </el-option>
                 </el-select>
@@ -427,8 +431,8 @@
           <el-table-column show-overflow-tooltip label="收货地址" align="center"  prop="deliveryAddressName" width="200px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :disabled="sonDisable" size="small" v-model="scope.row.deliveryAddressName" @clear="clearHang(scope.$index, '选择收货地址')" @focus="chooseDept(scope.$index, 'ADDRESS_PARAM', true, '选择收货地址')">
-                  <el-button size="small" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseDept(scope.$index, 'ADDRESS_PARAM', true, '选择收货地址')"></el-button>
+                <el-input clearable :disabled="sonDisable" size="mini" v-model="scope.row.deliveryAddressName" @clear="clearHang(scope.$index, '选择收货地址')" @focus="chooseDept(scope.$index, 'ADDRESS_PARAM', true, '选择收货地址')">
+                  <el-button size="mini" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseDept(scope.$index, 'ADDRESS_PARAM', true, '选择收货地址')"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -440,7 +444,7 @@
           <el-table-column show-overflow-tooltip label="价格类型" align="center"  prop="priceType" width="150px">
             <template slot-scope="scope">
               <el-form-item class="hang" :prop="'puDemandItemList.' + scope.$index + '.' + 'priceType'" :rules="{ required: true, message: '请选择价格类型', trigger: 'blur' }">
-                <el-select clearable :disabled="sonDisable" size="small" v-model="scope.row.priceType">
+                <el-select clearable :disabled="sonDisable" size="mini" v-model="scope.row.priceType">
                   <el-option v-for=" dict in dict.type.sys_price_type" :key="dict.value" :label="dict.label" :value="dict.value">
                   </el-option>
                 </el-select>
@@ -454,25 +458,25 @@
             align="center"
             >
           <template slot-scope="scope">
-            <el-button type="text" size="small" :disabled="sonDisable" @click="delLine(scope.$index, scope.row)">删除</el-button>
+            <el-button type="text" size="mini" :disabled="sonDisable" @click="delLine(scope.$index, scope.row)">删除</el-button>
           </template>
         </el-table-column>
       </el-table>
-    </el-card>
   </el-form>
+  </el-card>
 
     <div class="btn_group">
       <el-col :span="1.5">
-        <el-button type="primary" size="small" plain @click="copy" v-if="sonPageStu == 'check'">复制</el-button>
+        <el-button type="primary" size="mini" plain @click="copy" v-if="sonPageStu == 'check'">复制</el-button>
       </el-col>
       <el-col :span="1.5">
-        <el-button type="primary" size="small" plain @click="save" v-if="sonPageStu == 'add' || sonPageStu == 'edit'">保存</el-button>
+        <el-button type="primary" size="mini" plain @click="save" v-if="sonPageStu == 'add' || sonPageStu == 'edit'">保存</el-button>
       </el-col>
       <el-col :span="1.5" style="margin: 0 10px;">
-        <el-button type="primary" size="small" plain @click="submit" v-if="sonPageStu == 'check' && (row.status == '0' || row.status == '3')">提交</el-button>
+        <el-button type="primary" size="mini" plain @click="submit" v-if="sonPageStu == 'check' && (row.status == '0' || row.status == '3')">提交</el-button>
       </el-col>
       <el-col :span="1.5">
-        <el-button size="small" plain @click="back">返回</el-button>
+        <el-button size="mini" plain @click="back">返回</el-button>
       </el-col>
 
       <Reserved v-if="dialog.config" :isVisible="dialog.config" :info="row" @updateReserved="updateReserved"/>
@@ -482,6 +486,85 @@
       <popDialog ref="materialRefer" @doSubmit="selectMaterial" :single="true" />
 
     </div>
+
+    <!-- 批量调整参数 -->
+    <el-dialog title="批量调整" :visible.sync="adjust.open" @close="closeEvent" width="400px">
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">价格类型</el-col>
+        <el-col :span="14">
+        <el-select clearable size="mini" v-model="adjust.priceType">
+          <el-option v-for=" dict in dict.type.sys_price_type" :key="dict.value" :label="dict.label" :value="dict.value">
+          </el-option>
+        </el-select>
+        </el-col>
+      </el-row>
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">采购员</el-col>
+        <el-col :span="14">
+        <el-select clearable size="mini" v-model="adjust.purchaseMan" @focus="chooseOrg('CONTACTS_PARAM', true, '采购员')">
+          <el-option v-for="item in purchaseManOptions" :key="item.id" :label="item.name" :value="item.code" />
+        </el-select>
+        </el-col>
+      </el-row>
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">收货仓库</el-col>
+        <el-col :span="14">
+        <el-input clearable size="mini" v-model="adjust.warehouseName" @focus="chooseOrg('WAREHOUSE_PARAM', true, '收货仓库')">
+          <el-button size="mini" slot="append" icon="el-icon-more" @click="chooseOrg('WAREHOUSE_PARAM', true, '收货仓库')"></el-button>
+        </el-input>
+        </el-col>
+      </el-row>
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">收货货位</el-col>
+        <el-col :span="14">
+        <el-input clearable size="mini" v-model="adjust.allocationName" @focus="adjustHuoWei('ALLOCATION_PARAM', true, '收货货位', adjust.warehouse)">
+          <el-button size="mini" slot="append" icon="el-icon-more" @click="adjustHuoWei('ALLOCATION_PARAM', true, '收货货位', adjust.warehouse)"></el-button>
+        </el-input>
+        </el-col>
+      </el-row>
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">业务备注</el-col>
+        <el-col :span="14">
+          <el-input clearable size="mini" v-model="adjust.remark"/>
+        </el-col>
+      </el-row>
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">收货地址</el-col>
+        <el-col :span="14">
+          <el-input clearable size="mini" v-model="adjust.deliveryAddressName" @focus="chooseOrg('ADDRESS_PARAM', true, '收货地址')">
+            <el-button size="mini" slot="append" icon="el-icon-more" @click="chooseOrg('ADDRESS_PARAM', true, '收货地址')"></el-button>
+          </el-input>
+        </el-col>
+      </el-row>
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">收货地址编码</el-col>
+        <el-col :span="14">
+          <el-input disabled clearable size="mini" v-model="adjust.deliveryAddress"/>
+        </el-col>
+      </el-row>
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">联系人</el-col>
+        <el-col :span="14">
+          <el-input disabled clearable size="mini" v-model="adjust.contacts"/>
+        </el-col>
+      </el-row>
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">联系人电话</el-col>
+        <el-col :span="14">
+          <el-input disabled clearable size="mini" v-model="adjust.contactsPhone"/>
+        </el-col>
+      </el-row>
+      <el-row style="margin-bottom: 10px;">
+        <el-col :span="6">详细地址</el-col>
+        <el-col :span="14">
+          <el-input disabled clearable size="mini" v-model="adjust.address"/>
+        </el-col>
+      </el-row>
+      <div slot="footer" class="dialog-footer">
+      <el-button size="mini" type="primary" @click="confirmAdjust">确 认</el-button>
+      <el-button size="mini" @click="adjust.open = false">取 消</el-button>
+      </div>
+    </el-dialog>
   </div>
 </template>
 
@@ -556,6 +639,7 @@ export default {
       //   title: '',
       // },
       tableIndex: null,
+      ids: [],
       orgOptions: [],
       manOptions: [],
       personOptions: [],
@@ -573,7 +657,25 @@ export default {
         }
       },
       isBDXQ: false,
-      isYl: false
+      isYl: false,
+      // 批量调整参数
+      adjust: {
+        open: false,
+        priceType: '',
+        purchaseMan: '',
+        purchaseManName: '',
+        warehouse: '',
+        warehouseName: '',
+        allocation: '',
+        allocationName: '',
+        remark:'',
+        deliveryAddress: '',
+        deliveryAddressName: '',
+        contacts: '',
+        contactsPhone: '',
+        address: ''
+      },
+      purchaseManOptions: []
     }
   },
   created() {
@@ -655,6 +757,7 @@ export default {
       this.basicForm.id = ''
       this.basicForm.code = ''
       this.basicForm.createBy = ''
+      this.basicForm.source = '4'
       if (this.basicForm.puDemandItemList.length !== 0) {
         this.basicForm.puDemandItemList.forEach(item => {
           if (item.id) {
@@ -893,7 +996,12 @@ export default {
         }
       })
     },
-    handleSelectionChange() {},
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item =>{
+        return item.id
+      })
+      console.log('选中数组', this.ids)
+    },
     // 点击预留单展示
     showReserved() {
       this.dialog.config = true
@@ -946,10 +1054,32 @@ export default {
           })
         }
       }
-      if(this.referCondition.type == 'CONTACTS_PARAM') {
+      if(this.referCondition.type == 'CONTACTS_PARAM' && this.referCondition.title == '需求人员') {
         this.personOptions = selection
         this.basicForm.demandPersonal = selection[0].code
       }
+      if(this.referCondition.type == 'CONTACTS_PARAM' && this.referCondition.title == '采购员') {
+        this.purchaseManOptions = selection
+        this.adjust.purchaseMan = selection[0].code
+        this.adjust.purchaseManName = selection[0].name
+      }
+      if(this.referCondition.type == 'WAREHOUSE_PARAM' && this.referCondition.title == '收货仓库') {
+        this.adjust.warehouse = selection[0].id
+        this.adjust.warehouseName = selection[0].name
+        this.adjust.allocation = ''
+        this.adjust.allocationName = ''
+      }
+      if(this.referCondition.type == 'ALLOCATION_PARAM' && this.referCondition.title == '收货货位') {
+        this.adjust.allocation = selection[0].id
+        this.adjust.allocationName = selection[0].name
+      }
+      if(this.referCondition.type == 'ADDRESS_PARAM' && this.referCondition.title == '收货地址') {
+        this.adjust.deliveryAddressName = selection[0].name
+        this.adjust.deliveryAddress = selection[0].code
+        this.adjust.contacts = selection[0].contactsName
+        this.adjust.contactsPhone = selection[0].contactsPhone
+        this.adjust.address = selection[0].address
+      }
       if(this.referCondition.type == 'DEPT_PARAM') {
         this.deptOptions = selection
         this.basicForm.demandDept = selection[0].id
@@ -1117,6 +1247,84 @@ export default {
         })
       }
     },
+    // 批量调整
+    adjustPl() {
+      if(this.ids.length == 0) {
+        this.$modal.msgWarning('请至少选择一项数据进行操作!')
+      } else {
+        this.adjust.open = true
+      }
+    },
+    // 批量调整确认
+    confirmAdjust() {
+      console.log('data', this.adjust)
+      this.basicForm.puDemandItemList.forEach(item => {
+        this.ids.some(val => {
+          if(val == item.id) {
+            if(this.adjust.purchaseMan) {
+              item.buyer = this.adjust.purchaseMan
+              item.buyerName = this.adjust.purchaseManName
+            }
+            if(this.adjust.priceType) {
+              item.priceType = this.adjust.priceType
+            }
+            if(this.adjust.warehouseName) {
+              item.deliveryWarehouse = this.adjust.warehouse
+              item.deliveryWarehouseName = this.adjust.warehouseName
+              item.deliveryAllocation = this.adjust.allocation
+              item.deliveryAllocationName = this.adjust.allocationName
+            }
+            // if(this.adjust.allocationName) {
+            //   item.deliveryAllocation = this.adjust.allocation
+            //   item.deliveryAllocationName = this.adjust.allocationName
+            // }
+            if(this.adjust.remark) {
+              item.remark = this.adjust.remark
+            }
+            if(this.adjust.deliveryAddressName) {
+              item.deliveryAddressName = this.adjust.deliveryAddressName
+              item.deliveryAddress = this.adjust.deliveryAddress
+              item.contacts = this.adjust.contacts
+              item.contactsPhone = this.adjust.contactsPhone
+              item.address = this.adjust.address
+            }
+          }
+          this.adjust.open = false
+        })
+      })
+    },
+    // 批量调整选择货位
+    adjustHuoWei(type, isPage, title, stordocId) {
+      this.referCondition.type = type
+      this.referCondition.isPage = isPage
+      this.referCondition.title = title
+      // 选择收货货位前先选择收货仓库
+      if (stordocId) {
+        this.referCondition.stordocId = stordocId
+        this.$refs.refer.init(this.referCondition)
+      } else {
+        this.$modal.msgWarning("请先选择收货仓库");
+      }
+    },
+    // 关闭清空批量调整数据
+    closeEvent() {
+      this.adjust =  {
+        open: false,
+        priceType: '',
+        purchaseMan: '',
+        purchaseManName: '',
+        warehouse: '',
+        warehouseName: '',
+        allocation: '',
+        allocationName: '',
+        remark: '',
+        deliveryAddress: '',
+        deliveryAddressName: '',
+        contacts: '',
+        contactsPhone: '',
+        address: ''
+      }
+    },
   }
 }
 </script>

+ 41 - 31
src/views/purchase/PurchaseDemandList/index.vue

@@ -8,7 +8,7 @@
               <el-form-item label="单据编码">
                 <el-input
                   v-model.trim="queryParams.code"
-                  size="small"
+                  size="mini"
                   clearable
                   style="width: 200px"
                 />
@@ -16,14 +16,14 @@
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="需求客户">
-                <el-select clearable size="small" v-model="queryParams.customer" @focus="chooseOrg('CUSTOMER_PARAM', true, '需求客户')" style="width: 200px">
+                <el-select clearable size="mini" v-model="queryParams.customer" @focus="chooseOrg('CUSTOMER_PARAM', true, '需求客户')" style="width: 200px">
                   <el-option v-for="item in customerOptions" :key="item.id" :label="item.name" :value="item.id" />
                 </el-select>
               </el-form-item>
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="是否客户指定">
-                <el-select clearable v-model="queryParams.isProcess" size="small" style="width: 200px" placeholder="请选择">
+                <el-select clearable v-model="queryParams.isProcess" size="mini" style="width: 200px" placeholder="请选择">
                   <el-option
                     v-for="item in options"
                     :key="item.value"
@@ -35,8 +35,8 @@
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="" label-width="20px">
-                <el-button type="primary" size="small" icon="el-icon-search" plain @click="searchList">搜索</el-button>
-                <el-button size="small" icon="el-icon-refresh" plain @click="resetList">重置</el-button>
+                <el-button type="primary" size="mini" icon="el-icon-search" plain @click="searchList">搜索</el-button>
+                <el-button size="mini" icon="el-icon-refresh" plain @click="resetList">重置</el-button>
               </el-form-item>
             </el-col>
           </el-row>
@@ -45,14 +45,14 @@
           <el-row :gutter="10">
             <el-col :span="1.5">
               <el-form-item label="需求人员">
-                <el-select clearable size="small" v-model="queryParams.demandPersonal" @focus="chooseOrg('CONTACTS_PARAM', true, '需求人员')" style="width: 200px">
+                <el-select clearable size="mini" v-model="queryParams.demandPersonal" @focus="chooseOrg('CONTACTS_PARAM', true, '需求人员')" style="width: 200px">
                   <el-option v-for="item in personOptions" :key="item.id" :label="item.name" :value="item.code" />
                 </el-select>
               </el-form-item>
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="单据来源">
-                <el-select clearable v-model="queryParams.source" size="small" style="width: 200px">
+                <el-select clearable v-model="queryParams.source" size="mini" style="width: 200px">
                   <el-option v-for="dict in dict.type.sys_bill_source" :key="dict.value" :label="dict.label" :value="dict.value">
                   </el-option>
                 </el-select>
@@ -60,7 +60,7 @@
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="业务类型">
-                <el-select clearable v-model="queryParams.billType" size="small" style="width: 200px">
+                <el-select clearable v-model="queryParams.billType" size="mini" style="width: 200px">
                   <el-option v-for=" dict in dict.type.sys_business" :key="dict.value" :label="dict.label" :value="dict.value">
                   </el-option>
                 </el-select>
@@ -71,7 +71,7 @@
           <el-row :gutter="10">
             <el-col :span="1.5">
               <el-form-item label="需求部门">
-                <el-select clearable v-model="queryParams.demandDept" size="small" :disabled="disable" @focus="chooseOrg('DEPT_PARAM', true, '需求部门')" style="width: 200px">
+                <el-select clearable v-model="queryParams.demandDept" size="mini" :disabled="disable" @focus="chooseOrg('DEPT_PARAM', true, '需求部门')" style="width: 200px">
                   <el-option
                     v-for="item in deptOptions"
                     :key="item.id"
@@ -88,7 +88,7 @@
                   type="date"
                   clearable
                   value-format="yyyy-MM-dd"
-                  size="small"
+                  size="mini"
                   style="width: 200px"
                 >
                 </el-date-picker>
@@ -98,7 +98,7 @@
               <el-form-item label="备注">
                 <el-input
                   v-model.trim="queryParams.remark"
-                  size="small"
+                  size="mini"
                   clearable
                   style="width: 200px"
                 />
@@ -107,16 +107,24 @@
           </el-row>
 
           <el-row :gutter="10">
-            <el-col>
+            <el-col :span="1.5">
               <el-form-item label="物料编码">
                 <el-input
                   v-model.trim="queryParams.materialCode"
-                  size="small"
+                  size="mini"
                   clearable
                   style="width: 200px"
                 />
               </el-form-item>
             </el-col>
+            <el-col :span="1.5">
+              <el-form-item label="单据状态">
+                <el-select clearable v-model="queryParams.status" size="mini" style="width: 200px">
+                  <el-option v-for=" dict in dict.type.sys_status" :key="dict.value" :label="dict.label" :value="dict.value">
+                  </el-option>
+                </el-select>
+              </el-form-item>
+            </el-col>
           </el-row>
 
           </div>
@@ -126,10 +134,10 @@
 
         
         <div class="btn_grooup">
-          <el-button type="primary" size="small" @click="addDivision">新增</el-button>
+          <el-button type="primary" size="mini" @click="addDivision">新增</el-button>
 
-          <el-dropdown size="small" @command="handleCommand">
-            <el-button size="small" type="primary" style="margin-left: 10px;">
+          <el-dropdown size="mini" @command="handleCommand">
+            <el-button size="mini" type="primary" style="margin-left: 10px;">
               导入<i class="el-icon-arrow-down el-icon--right"></i>
             </el-button>
             <el-dropdown-menu slot="dropdown">
@@ -138,8 +146,8 @@
             </el-dropdown-menu>
           </el-dropdown>
 
-          <el-dropdown size="small" @command="handleExport">
-            <el-button size="small" type="primary" style="margin: 0 10px;">
+          <el-dropdown size="mini" @command="handleExport">
+            <el-button size="mini" type="primary" style="margin: 0 10px;">
               导出<i class="el-icon-arrow-down el-icon--right"></i>
             </el-button>
             <el-dropdown-menu slot="dropdown">
@@ -148,8 +156,8 @@
             </el-dropdown-menu>
           </el-dropdown>
 
-          <el-button type="primary" size="small" @click="delItems">删除</el-button>
-          <!-- <el-button type="primary" size="small">打印</el-button> -->
+          <el-button type="primary" size="mini" @click="delItems">删除</el-button>
+          <!-- <el-button type="primary" size="mini">打印</el-button> -->
         </div>
         <el-table 
           :data="tableList" 
@@ -180,9 +188,9 @@
           width="150"
           >
           <template slot-scope="scope">
-            <el-button type="text" size="small" @click="check(scope.row)">查看</el-button>
-            <el-button type="text" size="small" v-if="scope.row.status == '0' || scope.row.status == '3'" @click="edit(scope.row)">编辑</el-button>
-            <el-button type="text" size="small" v-if="scope.row.status == '0' || scope.row.status == '3'" @click="deleteids(scope.row)">删除</el-button>
+            <el-button type="text" size="mini" @click="check(scope.row)">查看</el-button>
+            <el-button type="text" size="mini" v-if="scope.row.status == '0' || scope.row.status == '3'" @click="edit(scope.row)">编辑</el-button>
+            <el-button type="text" size="mini" v-if="scope.row.status == '0' || scope.row.status == '3'" @click="deleteids(scope.row)">删除</el-button>
           </template>
         </el-table-column>
         </el-table>
@@ -226,8 +234,8 @@
       <div class="el-upload__tip" style="color:red" slot="tip">提示:仅允许导入“xls”或“xlsx”格式文件!</div>
       </el-upload>
       <div slot="footer" class="dialog-footer">
-      <el-button size="small" type="primary" @click="submitFileForm">确 定</el-button>
-      <el-button size="small" @click="upload.open = false">取 消</el-button>
+      <el-button size="mini" type="primary" @click="submitFileForm">确 定</el-button>
+      <el-button size="mini" @click="upload.open = false">取 消</el-button>
       </div>
     </el-dialog>
 
@@ -235,19 +243,19 @@
     <el-dialog title="需求模板下载" :visible.sync="download.open" width="400px">
       <el-row style="margin-bottom: 20px;">
         <span style="margin-right: 10px;">需求客户</span>
-        <el-select clearable size="small" v-model="download.customer" @clear="download.customer = ''" @focus="chooseOrg('CUSTOMER_PARAM', true, '选择客户')">
+        <el-select clearable size="mini" v-model="download.customer" @clear="download.customer = ''" @focus="chooseOrg('CUSTOMER_PARAM', true, '选择客户')">
           <el-option v-for="item in mBcustomer" :key="item.id" :label="item.name" :value="item.code" />
         </el-select>
       </el-row>
       <el-row style="margin-bottom: 20px;">
         <span style="margin-right: 10px;">供应仓库</span>
-        <el-select clearable size="small" v-model="download.warehouse" @clear="cleanMb" @focus="chooseOrg('WAREHOUSE_PARAM', true, '选择仓库')">
+        <el-select clearable size="mini" v-model="download.warehouse" @clear="cleanMb" @focus="chooseOrg('WAREHOUSE_PARAM', true, '选择仓库')">
           <el-option v-for="item in mBwarehouse" :key="item.id" :label="item.name" :value="item.code" />
         </el-select>
       </el-row>
       <el-row style="margin-bottom: 20px;">
         <span style="margin-right: 10px;">供应货位</span>
-        <el-select clearable size="small" v-model="download.cargoSpace" @clear="download.cargoSpace = ''" @focus="chooseOrg('ALLOCATION_PARAM', true, '选择货位', download.warehouseId)">
+        <el-select clearable size="mini" v-model="download.cargoSpace" @clear="download.cargoSpace = ''" @focus="chooseOrg('ALLOCATION_PARAM', true, '选择货位', download.warehouseId)">
           <el-option v-for="item in mBcargoSpace" :key="item.id" :label="item.name" :value="item.code" />
         </el-select>
       </el-row>
@@ -255,7 +263,7 @@
         <span style="margin-right: 10px;">品类选择</span>
         <el-select
         v-model="download.category"
-        size="small"
+        size="mini"
         clearable
         @focus="chooseTreeRefer('MATERIALCLASSIFY_PARAM', false, '选择品类')"
         >
@@ -263,8 +271,8 @@
         </el-select>
       </el-row>
       <div slot="footer" class="dialog-footer">
-      <el-button size="small" type="primary" @click="mbDownload">模板下载</el-button>
-      <el-button size="small" @click="download.open = false">取 消</el-button>
+      <el-button size="mini" type="primary" @click="mbDownload">模板下载</el-button>
+      <el-button size="mini" @click="download.open = false">取 消</el-button>
       </div>
     </el-dialog>
 
@@ -340,6 +348,7 @@ export default {
         demandDate: '',
         remark: '',
         materialCode: '',
+        status: '',
         pageNum: 1,
         pageSize: 5
       },
@@ -425,6 +434,7 @@ export default {
         demandDate: '',
         remark: '',
         materialCode: '',
+        status: '',
         pageNum: 1,
         pageSize: 5
       }

+ 21 - 3
src/views/purchase/apply/add/column.js

@@ -193,6 +193,7 @@ export const TabColumns = [
         require: true,
       },
       { title: "物料编码", key: "materialCode" },
+      { title: "物料ID", key: "material" },
       {
         title: "生产厂家",
         key: "manufacturerName",
@@ -222,7 +223,11 @@ export const TabColumns = [
         },
       },
       {
-        title: "单位",
+        title: "单位编码",
+        key: "unitCode",
+      },
+      {
+        title: "单位ID",
         key: "unit",
       },
       {
@@ -238,7 +243,11 @@ export const TabColumns = [
         },
       },
       {
-        title: "采购单位",
+        title: "采购单位编码",
+        key: "puUnitCode",
+      },
+      {
+        title: "采购单位ID",
         key: "puUnit",
       },
       {
@@ -291,7 +300,11 @@ export const TabColumns = [
         },
       },
       {
-        title: "币种",
+        title: "币种编码",
+        key: "currencyCode",
+      },
+      {
+        title: "币种ID",
         key: "currency",
       },
       {
@@ -332,6 +345,10 @@ export const TabColumns = [
         key: "customerCode",
       },
       {
+        title: "客户ID",
+        key: "customer",
+      },
+      {
         title: "最近价格",
         key: "recentlyPrice",
       },
@@ -389,6 +406,7 @@ export const TabColumns = [
         },
       },
       { title: "组织编码", key: "orgCode" },
+      { title: "组织ID", key: "org" },
       {
         title: "创建人名称",
         key: "createByName",

+ 2 - 2
src/views/purchase/apply/add/index.vue

@@ -6,7 +6,7 @@ import useWatch from "../hooks/watch";
 import useMethods from "../hooks/function";
 import useTable from "../hooks/table-function";
 import { SAVE } from "@/api/business/purchase/apply";
-const { watchPuOrg } = useWatch();
+const { watchPuOrgName } = useWatch();
 
 export default {
   name: "AddDrawer",
@@ -20,7 +20,7 @@ export default {
   },
   computed: {},
   watch: {
-    "params.puOrg": watchPuOrg(),
+    "params.puOrgName": watchPuOrgName(),
   },
   methods: {
     //

+ 3 - 2
src/views/purchase/apply/edit/index.vue

@@ -6,7 +6,8 @@ import useWatch from "../hooks/watch";
 import useMethods from "../hooks/function";
 import useTable from "../hooks/table-function";
 import { SAVE } from "@/api/business/purchase/apply";
-const { watchPuOrg, watchPriceApplyOrgs, watchPriceApplyItems } = useWatch();
+const { watchPuOrgName, watchPriceApplyOrgs, watchPriceApplyItems } =
+  useWatch();
 
 export default {
   name: "EditDrawer",
@@ -24,7 +25,7 @@ export default {
   },
   computed: {},
   watch: {
-    "params.puOrg": watchPuOrg(),
+    "params.puOrgName": watchPuOrgName(),
     "params.priceApplyOrgs": watchPriceApplyOrgs(),
     "params.priceApplyItems": watchPriceApplyItems(),
   },

+ 10 - 4
src/views/purchase/apply/hooks/watch.js

@@ -1,21 +1,27 @@
 export default function useWatch() {
-  const watchPuOrg = () => ({
+  const watchPuOrgName = () => ({
     handler: function (newProp, oldProp) {
       if (oldProp) {
         this.params.priceApplyOrgs = this.params.priceApplyOrgs.filter(
-          (item) => item.org !== oldProp
+          (item) => item.orgName !== oldProp
         );
       }
       if (newProp) {
-        const { puOrg: org, puOrgName: orgName } = this.params;
+        const {
+          puOrg: org,
+          puOrgCode: orgCode,
+          puOrgName: orgName,
+        } = this.params;
         this.params.priceApplyOrgs.push({
           org,
+          orgCode,
           orgName,
           createByName: undefined,
           updateByName: undefined,
         });
       }
     },
+    deep: true,
   });
   const watchPriceApplyOrgs = () => ({
     handler: function (newValue) {
@@ -33,5 +39,5 @@ export default function useWatch() {
     },
     deep: true,
   });
-  return { watchPuOrg, watchPriceApplyOrgs, watchPriceApplyItems };
+  return { watchPuOrgName, watchPriceApplyOrgs, watchPriceApplyItems };
 }

+ 14 - 14
src/views/purchase/deliveryAddress/add.vue

@@ -6,7 +6,7 @@
             <el-form-item label="收货仓库编码">
               <el-input
                 v-model="basicForm.code"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -18,7 +18,7 @@
             <el-form-item label="收货仓库名称">
               <el-input
                 v-model="basicForm.name"
-                size="small"
+                size="mini"
                 :disabled="disable"
                 clearable
                 style="width: 200px"
@@ -28,7 +28,7 @@
 
         <el-col :span="1.5">
             <el-form-item label="仓库档案名称">
-              <el-select size="small" v-model="basicForm.warehouse" :disabled="disable" @focus="chooseRefer('WAREHOUSE_PARAM', true, '仓库档案名称')" style="width: 200px">
+              <el-select size="mini" v-model="basicForm.warehouse" :disabled="disable" @focus="chooseRefer('WAREHOUSE_PARAM', true, '仓库档案名称')" style="width: 200px">
                 <el-option v-for="item in houseOptions" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
@@ -36,7 +36,7 @@
 
          <el-col :span="1.5">
           <el-form-item label="仓库属性">
-              <el-select :disabled="disable" v-model="basicForm.warehouseProperty" size="small" style="width: 200px">
+              <el-select :disabled="disable" v-model="basicForm.warehouseProperty" size="mini" style="width: 200px">
                 <el-option v-for="dict in dict.type.sys_warehouse_attribute" :key="dict.value" :label="dict.label" :value="dict.value">
                 </el-option>
               </el-select>
@@ -47,7 +47,7 @@
             <el-form-item label="地址信息">
               <el-input
                 v-model="basicForm.address"
-                size="small"
+                size="mini"
                 :disabled="disable"
                 clearable
                 style="width: 200px"
@@ -57,7 +57,7 @@
 
           <el-col :span="1.5">
             <el-form-item label="联系人">
-              <el-select size="small" v-model="basicForm.contacts" :disabled="disable" @focus="chooseRefer('CONTACTS_PARAM', true, '联系人')" style="width: 200px">
+              <el-select size="mini" v-model="basicForm.contacts" :disabled="disable" @focus="chooseRefer('CONTACTS_PARAM', true, '联系人')" style="width: 200px">
                 <el-option v-for="item in contactsOptions" :key="item.id" :label="item.name" :value="item.code" />
               </el-select>
             </el-form-item>
@@ -67,7 +67,7 @@
             <el-form-item label="联系人电话">
               <el-input
                 v-model="basicForm.contactsPhone"
-                size="small"
+                size="mini"
                 :disabled="disable"
                 clearable
                 style="width: 200px"
@@ -79,7 +79,7 @@
             <el-form-item label="物料分类">
               <el-select
                 v-model="basicForm.materialClassify"
-                size="small"
+                size="mini"
                 :disabled="disable"
                 clearable
                 @focus="chooseTreeRefer('MATERIALCLASSIFY_PARAM', false, '物料分类')"
@@ -92,7 +92,7 @@
 
          <el-col :span="1.5">
             <el-form-item label="启用">
-              <el-select v-model="basicForm.status" size="small" style="width: 200px" clearable :disabled="disable">
+              <el-select v-model="basicForm.status" size="mini" style="width: 200px" clearable :disabled="disable">
                 <el-option
                   v-for="item in options"
                   :key="item.value"
@@ -105,7 +105,7 @@
 
          <el-col :span="1.5">
             <el-form-item label="同步状态">
-              <el-select disabled v-model="basicForm.sendStatus" size="small" style="width: 200px">
+              <el-select disabled v-model="basicForm.sendStatus" size="mini" style="width: 200px">
                 <el-option
                   v-for="item in options2"
                   :key="item.value"
@@ -120,7 +120,7 @@
             <el-form-item label="备注">
               <el-input
                 v-model="basicForm.remark"
-                size="small"
+                size="mini"
                 :disabled="disable"
                 clearable
                 style="width: 200px"
@@ -133,13 +133,13 @@
 
     <div class="btn_group">
       <el-col :span="1.5" style="margin: 0 10px;">
-        <el-button type="primary" size="small" plain @click="save" v-if="pageStu == 'add' || pageStu == 'edit'">保存</el-button>
+        <el-button type="primary" size="mini" plain @click="save" v-if="pageStu == 'add' || pageStu == 'edit'">保存</el-button>
       </el-col>
       <!-- <el-col :span="1.5" style="margin: 0 10px;">
-        <el-button type="primary" size="small" plain @click="submit" v-if="pageStu == 'edit'">提交</el-button>
+        <el-button type="primary" size="mini" plain @click="submit" v-if="pageStu == 'edit'">提交</el-button>
       </el-col> -->
       <el-col :span="1.5">
-        <el-button size="small" plain @click="back">返回</el-button>
+        <el-button size="mini" plain @click="back">返回</el-button>
       </el-col>
     </div>
 

+ 25 - 25
src/views/purchase/deliveryAddress/index.vue

@@ -5,7 +5,7 @@
         <el-row :gutter="10">
           <el-col :span="1.5">
             <el-form-item label="仓库属性">
-              <el-select clearable v-model="queryParams.warehouseProperty" size="small" style="width: 200px">
+              <el-select clearable v-model="queryParams.warehouseProperty" size="mini" style="width: 200px">
                 <el-option v-for="dict in dict.type.sys_warehouse_attribute" :key="dict.value" :label="dict.label" :value="dict.value">
                 </el-option>
               </el-select>
@@ -13,7 +13,7 @@
           </el-col>
           <el-col :span="1.5">
             <el-form-item label="仓库档案名称">
-              <el-select clearable size="small" v-model="queryParams.warehouseName" @focus="chooseRefer('WAREHOUSE_PARAM', true, '仓库档案名称')" style="width: 200px">
+              <el-select clearable size="mini" v-model="queryParams.warehouseName" @focus="chooseRefer('WAREHOUSE_PARAM', true, '仓库档案名称')" style="width: 200px">
                 <el-option v-for="item in houseOptions" :key="item.id" :label="item.name" :value="item.name" />
               </el-select>
             </el-form-item>
@@ -22,7 +22,7 @@
             <el-form-item label="收货仓库编码">
               <el-input
               v-model="queryParams.code"
-              size="small"
+              size="mini"
               clearable
               style="width: 200px"
             />
@@ -32,7 +32,7 @@
             <el-form-item label="收货仓库名称">
               <el-input
               v-model="queryParams.name"
-              size="small"
+              size="mini"
               clearable
               style="width: 200px"
             />
@@ -40,8 +40,8 @@
           </el-col>
           <el-col :span="1.5">
             <el-form-item label="" label-width="20px">
-              <el-button type="primary" size="small" icon="el-icon-search" plain @click="searchList">搜索</el-button>
-              <el-button size="small" icon="el-icon-refresh" plain @click="resetList">重置</el-button>
+              <el-button type="primary" size="mini" icon="el-icon-search" plain @click="searchList">搜索</el-button>
+              <el-button size="mini" icon="el-icon-refresh" plain @click="resetList">重置</el-button>
             </el-form-item>
           </el-col>
         </el-row>
@@ -53,7 +53,7 @@
             <el-form-item label="物料分类">
               <el-select
                 v-model="queryParams.materialClassifyName"
-                size="small"
+                size="mini"
                 clearable
                 @focus="chooseTreeRefer('MATERIALCLASSIFY_PARAM', false, '物料分类')"
                 style="width: 200px"
@@ -67,7 +67,7 @@
             <el-form-item label="详细地址">
             <el-input
               v-model="queryParams.address"
-              size="small"
+              size="mini"
               placeholder=""
               clearable
               style="width: 200px"
@@ -77,7 +77,7 @@
 
           <el-col :span="1.5">
             <el-form-item label="联系人">
-            <el-select clearable size="small" v-model="queryParams.contactsName" clearable @focus="chooseRefer('CONTACTS_PARAM', true, '联系人')" style="width: 200px">
+            <el-select clearable size="mini" v-model="queryParams.contactsName" clearable @focus="chooseRefer('CONTACTS_PARAM', true, '联系人')" style="width: 200px">
               <el-option v-for="item in contactsOptions" :key="item.id" :label="item.name" :value="item.name" />
             </el-select>
             </el-form-item>
@@ -87,7 +87,7 @@
             <el-form-item label="联系人电话">
             <el-input
               v-model="queryParams.contactsPhone"
-              size="small"
+              size="mini"
               clearable
               style="width: 200px"
             />
@@ -100,7 +100,7 @@
             <el-form-item label="备注">
             <el-input
               v-model="queryParams.remark"
-              size="small"
+              size="mini"
               clearable
               style="width: 200px"
             />
@@ -109,7 +109,7 @@
 
           <el-col :span="1.5">
             <el-form-item label="同步状态">
-              <el-select v-model="queryParams.sendStatus" size="small" style="width: 200px" clearable>
+              <el-select v-model="queryParams.sendStatus" size="mini" style="width: 200px" clearable>
                 <el-option
                   v-for="item in options2"
                   :key="item.value"
@@ -122,7 +122,7 @@
 
           <el-col :span="1.5">
             <el-form-item label="启用">
-              <el-select v-model="queryParams.status" size="small" style="width: 200px" clearable>
+              <el-select v-model="queryParams.status" size="mini" style="width: 200px" clearable>
                 <el-option
                   v-for="item in options"
                   :key="item.value"
@@ -140,10 +140,10 @@
 
       <el-card>
         <div class="btn_grooup">
-          <el-button type="primary" size="small" @click="addAddress">新增</el-button>
+          <el-button type="primary" size="mini" @click="addAddress">新增</el-button>
 
-          <el-dropdown size="small" @command="handleCommand">
-            <el-button size="small" type="primary" style="margin-left: 10px;">
+          <el-dropdown size="mini" @command="handleCommand">
+            <el-button size="mini" type="primary" style="margin-left: 10px;">
               导入<i class="el-icon-arrow-down el-icon--right"></i>
             </el-button>
             <el-dropdown-menu slot="dropdown">
@@ -152,8 +152,8 @@
             </el-dropdown-menu>
           </el-dropdown>
 
-          <el-dropdown size="small" @command="handleCommand">
-            <el-button size="small" type="primary" style="margin: 0 10px;">
+          <el-dropdown size="mini" @command="handleCommand">
+            <el-button size="mini" type="primary" style="margin: 0 10px;">
               导出<i class="el-icon-arrow-down el-icon--right"></i>
             </el-button>
             <el-dropdown-menu slot="dropdown">
@@ -162,10 +162,10 @@
             </el-dropdown-menu>
           </el-dropdown>
 
-          <el-button type="primary" size="small">启用</el-button>
-          <el-button type="primary" size="small">停用</el-button>
-          <el-button type="primary" size="small">同步NC</el-button>
-          <el-button type="primary" size="small">删除</el-button>
+          <el-button type="primary" size="mini">启用</el-button>
+          <el-button type="primary" size="mini">停用</el-button>
+          <el-button type="primary" size="mini">同步NC</el-button>
+          <el-button type="primary" size="mini">删除</el-button>
         </div>
         <el-table 
           :data="tableList" 
@@ -197,9 +197,9 @@
           width="150"
           >
           <template slot-scope="scope">
-            <el-button type="text" size="small" @click="check(scope.row)">查看</el-button>
-            <el-button type="text" size="small" @click="edit(scope.row)">编辑</el-button>
-            <el-button type="text" size="small" @click="deleteids(scope.row)">删除</el-button>
+            <el-button type="text" size="mini" @click="check(scope.row)">查看</el-button>
+            <el-button type="text" size="mini" @click="edit(scope.row)">编辑</el-button>
+            <el-button type="text" size="mini" @click="deleteids(scope.row)">删除</el-button>
           </template>
         </el-table-column>
         </el-table>

+ 92 - 53
src/views/purchase/transferOrder/add.vue

@@ -4,14 +4,14 @@
       <el-row :gutter="10">
         <el-col :span="1.5">
           <el-form-item label="调出库存组织">
-            <el-select clearable size="small" v-model="basicForm.deliveryInventoryOrg" :disabled="sonDisable" @change="controlCk" @focus="chooseRefer('ORG_PARAM', true, '调出库存组织')" style="width: 200px">
+            <el-select clearable size="mini" v-model="basicForm.deliveryInventoryOrg" :disabled="sonDisable" @change="controlCk" @focus="chooseRefer('ORG_PARAM', true, '调出库存组织')" style="width: 200px">
               <el-option v-for="item in chuOrgOptions" :key="item.id" :label="item.name" :value="item.id" />
             </el-select>
           </el-form-item>
         </el-col>
         <el-col :span="1.5">
             <el-form-item label="订单类型">
-              <el-select v-model="basicForm.billType" :disabled="sonDisable" size="small" style="width: 200px" clearable>
+              <el-select v-model="basicForm.billType" :disabled="sonDisable" size="mini" style="width: 200px" clearable>
                 <el-option v-for="dict in dict.type.sys_allot_billtype" :key="dict.value" :label="dict.label" :value="dict.value">
                 </el-option>
               </el-select>
@@ -21,7 +21,7 @@
             <el-form-item label="单据号">
               <el-input
                 v-model="basicForm.code"
-                size="small"
+                size="mini"
                 :disabled="sonDisable"
                 clearable
                 style="width: 200px"
@@ -32,7 +32,7 @@
             <el-form-item label="单据日期">
               <el-date-picker
                 v-model="basicForm.billDate"
-                size="small"
+                size="mini"
                 :disabled="sonDisable"
                 type="date"
                 clearable
@@ -44,7 +44,7 @@
          </el-col>
         <el-col :span="1.5">
             <el-form-item label="调拨方式">
-              <el-select v-model="basicForm.allotType" disabled size="small" style="width: 200px" clearable>
+              <el-select v-model="basicForm.allotType" disabled size="mini" style="width: 200px" clearable>
                 <el-option v-for="dict in dict.type.sys_to_type" :key="dict.value" :label="dict.label" :value="dict.value">
                 </el-option>
               </el-select>
@@ -54,7 +54,7 @@
             <el-form-item label="调拨出库单号">
               <el-input
                 v-model="basicForm.deliveryCode"
-                size="small"
+                size="mini"
                 :disabled="sonDisable"
                 clearable
                 style="width: 200px"
@@ -65,7 +65,7 @@
             <el-form-item label="调拨入库单号">
               <el-input
                 v-model="basicForm.storageCode"
-                size="small"
+                size="mini"
                 :disabled="sonDisable"
                 clearable
                 style="width: 200px"
@@ -74,28 +74,28 @@
          </el-col>
         <el-col :span="1.5">
             <el-form-item label="调入库存组织">
-              <el-select clearable size="small" v-model="basicForm.storageInventoryOrg" :disabled="sonDisable" @change="controlCk" @focus="chooseRefer('ORG_PARAM', true, '调入库存组织')" style="width: 200px">
+              <el-select clearable size="mini" v-model="basicForm.storageInventoryOrg" :disabled="sonDisable" @change="controlCk" @focus="chooseRefer('ORG_PARAM', true, '调入库存组织')" style="width: 200px">
                 <el-option v-for="item in ruOrgOptions" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
          </el-col>
         <el-col :span="1.5">
             <el-form-item label="调出业务员">
-              <el-select clearable size="small" v-model="basicForm.businessPersonal" :disabled="sonDisable" @focus="chooseRefer('CONTACTS_PARAM', true, '调出业务员')" style="width: 200px">
+              <el-select clearable size="mini" v-model="basicForm.businessPersonal" :disabled="sonDisable" @focus="chooseRefer('CONTACTS_PARAM', true, '调出业务员')" style="width: 200px">
                 <el-option v-for="item in manOptions" :key="item.id" :label="item.name" :value="item.code" />
               </el-select>
             </el-form-item>
          </el-col>
         <el-col :span="1.5">
             <el-form-item label="调出部门">
-              <el-select clearable size="small" v-model="basicForm.deliveryDept" :disabled="sonDisable || isOrg" @focus="chooseRefer('DEPT_PARAM', true, '调出部门', basicForm.deliveryInventoryOrg)" style="width: 200px">
+              <el-select clearable size="mini" v-model="basicForm.deliveryDept" :disabled="sonDisable || isOrg" @focus="chooseRefer('DEPT_PARAM', true, '调出部门', basicForm.deliveryInventoryOrg)" style="width: 200px">
                 <el-option v-for="item in deptOptions" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
          </el-col>
         <el-col :span="1.5">
             <el-form-item label="币种">
-              <el-select clearable size="small" v-model="basicForm.currency" :disabled="sonDisable" @focus="chooseRefer('CURRENCY_PARAM', true, '币种')" style="width: 200px">
+              <el-select clearable size="mini" v-model="basicForm.currency" :disabled="sonDisable" @focus="chooseRefer('CURRENCY_PARAM', true, '币种')" style="width: 200px">
                 <el-option v-for="item in currencyOptions" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
@@ -104,7 +104,7 @@
             <el-form-item label="折本汇率">
               <el-input-number
                 v-model="basicForm.rate"
-                size="small"
+                size="mini"
                 disabled
                 :precision="2" 
                 :step="0.1" 
@@ -117,7 +117,7 @@
             <el-form-item label="在途归属">
               <el-input
                 v-model="basicForm.onRouteAffilliation"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -128,7 +128,7 @@
             <el-form-item label="总数量">
               <el-input
                 v-model="basicForm.qty"
-                size="small"
+                size="mini"
                 :disabled="sonDisable"
                 clearable
                 style="width: 200px"
@@ -139,7 +139,7 @@
             <el-form-item label="结算路径">
               <el-input
                 v-model="basicForm.accountPath"
-                size="small"
+                size="mini"
                 :disabled="sonDisable"
                 clearable
                 style="width: 200px"
@@ -150,7 +150,7 @@
             <el-form-item label="客户">
               <el-input
                 v-model="basicForm.customer"
-                size="small"
+                size="mini"
                 :disabled="sonDisable"
                 clearable
                 style="width: 200px"
@@ -159,21 +159,21 @@
          </el-col>
         <el-col :span="1.5">
             <el-form-item label="调入仓库">
-              <el-select clearable size="small" v-model="basicForm.storageWarehouse" :disabled="sonDisable || isOrg" @change="controlDRHW" @focus="chooseRefer('WAREHOUSE_PARAM', true, '调入仓库', basicForm.storageInventoryOrg, 'N', 'N')" style="width: 200px">
+              <el-select clearable size="mini" v-model="basicForm.storageWarehouse" :disabled="sonDisable || isOrg" @change="controlDRHW" @focus="chooseRefer('WAREHOUSE_PARAM', true, '调入仓库', basicForm.storageInventoryOrg, 'N', 'N')" style="width: 200px">
                 <el-option v-for="item in ruHouseOptions" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
          </el-col>
         <el-col :span="1.5">
             <el-form-item label="调出仓库">
-              <el-select clearable size="small" v-model="basicForm.deliveryWarehouse" :disabled="sonDisable || isOrg" @change="controlDCHW" @focus="chooseRefer('WAREHOUSE_PARAM', true, '调出仓库', basicForm.deliveryInventoryOrg, 'N', 'N')" style="width: 200px">
+              <el-select clearable size="mini" v-model="basicForm.deliveryWarehouse" :disabled="sonDisable || isOrg" @change="controlDCHW" @focus="chooseRefer('WAREHOUSE_PARAM', true, '调出仓库', basicForm.deliveryInventoryOrg, 'N', 'N')" style="width: 200px">
                 <el-option v-for="item in chuHouseOptions" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
          </el-col>
         <el-col :span="1.5">
             <el-form-item label="物流项目组">
-              <el-select v-model="basicForm.materialProject" :disabled="sonDisable" size="small" style="width: 200px" clearable>
+              <el-select v-model="basicForm.materialProject" :disabled="sonDisable" size="mini" style="width: 200px" clearable>
                 <el-option v-for="dict in dict.type.sys_project_group" :key="dict.value" :label="dict.label" :value="dict.value">
                 </el-option>
               </el-select>
@@ -181,14 +181,14 @@
          </el-col>
         <el-col :span="1.5">
             <el-form-item label="利润中心">
-              <el-select clearable size="small" v-model="basicForm.liacenter" :disabled="sonDisable" @focus="chooseTreeRefer('LIACENTER_PARAM', false, '利润中心')" style="width: 200px">
+              <el-select clearable size="mini" v-model="basicForm.liacenter" :disabled="sonDisable" @focus="chooseTreeRefer('LIACENTER_PARAM', false, '利润中心')" style="width: 200px">
                 <el-option v-for="item in liacenterOptions" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
         </el-col>
         <el-col :span="1.5">
           <el-form-item label="单据状态">
-            <el-select disabled v-model="basicForm.status" size="small" style="width: 200px" clearable>
+            <el-select disabled v-model="basicForm.status" size="mini" style="width: 200px" clearable>
               <el-option v-for="dict in dict.type.sys_status" :key="dict.value" :label="dict.label" :value="dict.value">
               </el-option>
             </el-select>
@@ -198,7 +198,7 @@
             <el-form-item label="备注">
               <el-input
                 v-model="basicForm.remark"
-                size="small"
+                size="mini"
                 :disabled="sonDisable"
                 clearable
                 style="width: 200px"
@@ -206,6 +206,19 @@
             </el-form-item>
         </el-col>
       </el-row>
+      
+      <el-row>
+        <el-col :span="1.5">
+          <el-form-item label="NC单据号">
+            <el-input
+              v-model="basicForm.ncCode"
+              size="mini"
+              disabled
+              style="width: 200px"
+            />
+          </el-form-item>
+        </el-col>
+      </el-row>
 
       <el-row>
         <el-col :span="20">
@@ -214,7 +227,7 @@
                 v-model="basicForm.isSendWms"
                 type="textarea"
                 :rows="3"
-                size="small"
+                size="mini"
                 disabled
                 clearable
               />
@@ -225,20 +238,24 @@
       <el-tabs style="margin-top: 10px;" type="border-card">
         <el-tab-pane label="物料信息">
           <div class="btn_grooup">
-            <el-button type="primary" size="small" v-if="!sonDisable" @click="addLine">增行</el-button>
+            <el-button type="primary" size="mini" v-if="!sonDisable" @click="addLine">增行</el-button>
           </div>
           <el-table
           :data="materialInfo" 
           fit
           max-height="480"
           >
-          <el-table-column show-overflow-tooltip label="行号" align="center" prop="rowno"/>
+          <el-table-column show-overflow-tooltip label="行号" align="center" prop="rowno">
+              <template slot-scope="scope">
+                {{ scope.$index + 1 + '0' }}
+              </template>
+          </el-table-column>
           <el-table-column show-overflow-tooltip label="采购需求单单号" align="center" prop="demandCode" width="200px"/>
           <el-table-column show-overflow-tooltip label="物料编码" align="center" prop="materialCode" width="230px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :disabled="sonDisable" size="small" v-model="scope.row.materialCode" @focus="chooseMaterial(scope.$index)">
-                  <el-button size="small" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseMaterial(scope.$index)"></el-button>
+                <el-input clearable :disabled="sonDisable" size="mini" v-model="scope.row.materialCode" @focus="chooseMaterial(scope.$index)">
+                  <el-button size="mini" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseMaterial(scope.$index)"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -255,7 +272,7 @@
           <el-table-column show-overflow-tooltip label="数量" align="center" prop="qty" width="150px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input :readonly="sonDisable" clearable size="small" v-model="scope.row.qty" @input="getSL(scope)"/>
+                <el-input :readonly="sonDisable" clearable size="mini" v-model="scope.row.qty" @input="getSL(scope)"/>
               </el-form-item>
             </template>
           </el-table-column>
@@ -264,7 +281,7 @@
           <el-table-column show-overflow-tooltip label="主数量" align="center" prop="mainQty" width="150px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input :readonly="sonDisable" clearable size="small" v-model="scope.row.mainQty" @input="getZSL(scope)"/>
+                <el-input :readonly="sonDisable" clearable size="mini" v-model="scope.row.mainQty" @input="getZSL(scope)"/>
               </el-form-item>
             </template>
           </el-table-column>
@@ -272,8 +289,8 @@
           <el-table-column show-overflow-tooltip label="调出货位" align="center" prop="deliveryAllocationName" width="230px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :disabled="sonDisable || isDCCk" size="small" v-model="scope.row.deliveryAllocationName" @focus="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '调出货位', basicForm.deliveryWarehouse)">
-                  <el-button size="small" :disabled="sonDisable || isDCCk" slot="append" icon="el-icon-more" @click="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '调出货位', basicForm.deliveryWarehouse)"></el-button>
+                <el-input clearable :disabled="sonDisable || isDCCk" size="mini" v-model="scope.row.deliveryAllocationName" @focus="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '调出货位', basicForm.deliveryWarehouse)">
+                  <el-button size="mini" :disabled="sonDisable || isDCCk" slot="append" icon="el-icon-more" @click="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '调出货位', basicForm.deliveryWarehouse)"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -281,8 +298,8 @@
           <el-table-column show-overflow-tooltip label="调入部门" align="center" prop="storageDeptName" width="230px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :disabled="sonDisable" size="small" v-model="scope.row.storageDeptName" @focus="chooseMxBM(scope.$index, 'DEPT_PARAM', true, '调入部门', basicForm.storageInventoryOrg)">
-                  <el-button size="small" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseMxBM(scope.$index, 'DEPT_PARAM', true, '调入部门', basicForm.storageInventoryOrg)"></el-button>
+                <el-input clearable :disabled="sonDisable" size="mini" v-model="scope.row.storageDeptName" @focus="chooseMxBM(scope.$index, 'DEPT_PARAM', true, '调入部门', basicForm.storageInventoryOrg)">
+                  <el-button size="mini" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseMxBM(scope.$index, 'DEPT_PARAM', true, '调入部门', basicForm.storageInventoryOrg)"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -290,8 +307,8 @@
           <el-table-column show-overflow-tooltip label="调入货位" align="center" prop="storageAllocationName" width="230px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input clearable :disabled="sonDisable || isDRCk" size="small" v-model="scope.row.storageAllocationName" @focus="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '调入货位', basicForm.storageWarehouse)">
-                  <el-button size="small" :disabled="sonDisable || isDRCk" slot="append" icon="el-icon-more" @click="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '调入货位', basicForm.storageWarehouse)"></el-button>
+                <el-input clearable :disabled="sonDisable || isDRCk" size="mini" v-model="scope.row.storageAllocationName" @focus="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '调入货位', basicForm.storageWarehouse)">
+                  <el-button size="mini" :disabled="sonDisable || isDRCk" slot="append" icon="el-icon-more" @click="chooseMxHW(scope.$index, 'ALLOCATION_PARAM', true, '调入货位', basicForm.storageWarehouse)"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -300,8 +317,8 @@
           <el-table-column show-overflow-tooltip label="产品批号" align="center" prop="producBatch" width="230px">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input readonly size="small" v-model="scope.row.producBatch">
-                  <el-button size="small" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseBatch(scope.$index)"></el-button>
+                <el-input readonly size="mini" v-model="scope.row.producBatch">
+                  <el-button size="mini" :disabled="sonDisable" slot="append" icon="el-icon-more" @click="chooseBatch(scope.$index)"></el-button>
                 </el-input>
               </el-form-item>
             </template>
@@ -313,7 +330,7 @@
                   v-model="scope.row.manufactureDate"
                   :readonly="sonDisable"
                   type="date"
-                  size="small"
+                  size="mini"
                   value-format="yyyy-MM-dd">
                 </el-date-picker>
               </el-form-item>
@@ -328,7 +345,7 @@
                   v-model="scope.row.allotDate"
                   :readonly="sonDisable"
                   type="date"
-                  size="small"
+                  size="mini"
                   :picker-options="pickerOptionsEnd"
                   value-format="yyyy-MM-dd">
                 </el-date-picker>
@@ -346,7 +363,7 @@
           <el-table-column show-overflow-tooltip label="pi码" align="center" prop="pi">
             <template slot-scope="scope">
               <el-form-item class="hang">
-                <el-input :readonly="sonDisable" size="small" v-model="scope.row.pi"/>
+                <el-input :readonly="sonDisable" size="mini" v-model="scope.row.pi"/>
               </el-form-item>
             </template>
           </el-table-column>
@@ -361,7 +378,7 @@
             align="center"
             >
             <template slot-scope="scope">
-              <el-button type="text" size="small" :disabled="sonDisable" @click="delLine(scope.$index, scope.row)">删除</el-button>
+              <el-button type="text" size="mini" :disabled="sonDisable" @click="delLine(scope.$index, scope.row)">删除</el-button>
             </template>
           </el-table-column>
           </el-table>
@@ -479,7 +496,7 @@
             <el-form-item label="制单人">
               <el-input
                 v-model="basicForm.createByName"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -490,7 +507,7 @@
             <el-form-item label="制单日期">
               <el-input
                 v-model="basicForm.createTime"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -501,7 +518,7 @@
             <el-form-item label="审批人">
               <el-input
                 v-model="basicForm.code"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -512,7 +529,7 @@
             <el-form-item label="审批日期">
               <el-input
                 v-model="basicForm.code"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -527,7 +544,7 @@
             <el-form-item label="创建人">
               <el-input
                 v-model="basicForm.createByName"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -538,7 +555,7 @@
             <el-form-item label="创建时间">
               <el-input
                 v-model="basicForm.createTime"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -549,7 +566,7 @@
             <el-form-item label="最后修改人">
               <el-input
                 v-model="basicForm.updateByName"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -560,7 +577,7 @@
             <el-form-item label="最后修改时间">
               <el-input
                 v-model="basicForm.updateTime"
-                size="small"
+                size="mini"
                 disabled
                 clearable
                 style="width: 200px"
@@ -572,16 +589,16 @@
 
     <div class="btn_group">
       <!-- <el-col :span="1.5">
-        <el-button type="primary" size="small" plain @click="copy" v-if="sonPageStu == 'check'">复制</el-button>
+        <el-button type="primary" size="mini" plain @click="copy" v-if="sonPageStu == 'check'">复制</el-button>
       </el-col> -->
       <el-col :span="1.5">
-        <el-button type="primary" size="small" plain @click="save" v-if="sonPageStu == 'add' || sonPageStu == 'edit'">保存</el-button>
+        <el-button type="primary" size="mini" plain @click="save" v-if="sonPageStu == 'add' || sonPageStu == 'edit'">保存</el-button>
       </el-col>
       <el-col :span="1.5" style="margin: 0 10px;">
-        <el-button type="primary" size="small" plain @click="submit" v-if="sonPageStu == 'check' && (row.status == '0' || row.status == '3')">提交</el-button>
+        <el-button type="primary" size="mini" plain @click="submit" v-if="sonPageStu == 'check' && (row.status == '0' || row.status == '3')">提交</el-button>
       </el-col>
       <el-col :span="1.5">
-        <el-button size="small" plain @click="back">返回</el-button>
+        <el-button size="mini" plain @click="back">返回</el-button>
       </el-col>
     </div>
 
@@ -656,6 +673,8 @@ export default {
         liacenter: '',
         liacenterName: '',
         sourceIdentification: '',
+        remark:'',
+        ncCode: '',
         isSendWms: '',
         status: '0',
         tenantId: '',
@@ -942,6 +961,12 @@ export default {
         this.basicForm.deliveryInventoryOrg = selection[0].id
         this.basicForm.deliveryInventoryOrgCode = selection[0].code
         this.basicForm.deliveryInventoryOrgName = selection[0].name
+        // 清空调出仓库,部门
+        this.basicForm.deliveryWarehouse = ''
+        this.basicForm.deliveryWarehouseCode = ''
+        this.basicForm.deliveryWarehouseName = ''
+        this.basicForm.deliveryDept = ''
+        this.basicForm.deliveryDeptName = ''
         // 选择调入库存组织时判断调拨方式
         if (this.basicForm.storageInventoryOrg == this.basicForm.deliveryInventoryOrg) {
           this.basicForm.allotType = '4'
@@ -955,6 +980,9 @@ export default {
         this.basicForm.storageInventory = selection[0].code
         this.basicForm.storageInventoryOrgName = selection[0].name
         this.basicForm.onRouteAffilliation = selection[0].name
+        // 选择调入库存组织清空仓库
+        this.basicForm.storageWarehouse = ''
+        this.basicForm.storageWarehouseName = ''
         // 选择调入库存组织时判断调拨方式
         if (this.basicForm.storageInventoryOrg == this.basicForm.deliveryInventoryOrg) {
           this.basicForm.allotType = '4'
@@ -982,6 +1010,11 @@ export default {
         this.basicForm.storageWarehouse = selection[0].id
         this.basicForm.storageWarehouseName = selection[0].name
         console.log('1111', selection[0].csFlag)
+        // 清空调入货位
+        this.materialInfo.forEach(item => {
+          item.storageAllocation = null
+          item.storageAllocationName = null
+        })
         if(selection[0].csFlag == 'N') {
           this.isDRCk = true
         } else {
@@ -994,6 +1027,11 @@ export default {
         this.basicForm.deliveryWarehouseCode = selection[0].code
         this.basicForm.deliveryWarehouseName = selection[0].name
         console.log('2222', selection[0].csFlag)
+        // 清空调出货位
+        this.materialInfo.forEach(item => {
+          item.deliveryAllocation = null
+          item.deliveryAllocationName = null
+        })
         if (selection[0].csFlag == 'N') {
           this.isDCCk = true
         } else {
@@ -1069,6 +1107,7 @@ export default {
       this.referCondition.type = type
       this.referCondition.isPage = isPage
       this.referCondition.title = title
+      this.referCondition.pkOrg = ''
       this.referCondition.stordocId = stordocId
       this.$refs.refer.init(this.referCondition)
     },

+ 13 - 13
src/views/purchase/transferOrder/index.vue

@@ -6,7 +6,7 @@
           <el-row :gutter="10">
             <el-col :span="1.5">
               <el-form-item label="调出库存组织">
-                <el-select clearable size="small" v-model="queryParams.deliveryInventoryOrg" @focus="chooseRefer('ORG_PARAM', true, '调出库存组织')" style="width: 200px">
+                <el-select clearable size="mini" v-model="queryParams.deliveryInventoryOrg" @focus="chooseRefer('ORG_PARAM', true, '调出库存组织')" style="width: 200px">
                   <el-option v-for="item in chuOrgOptions" :key="item.id" :label="item.name" :value="item.id" />
                 </el-select>
               </el-form-item>
@@ -15,7 +15,7 @@
               <el-form-item label="单据日期">
                 <el-date-picker
                 style="width: 200px"
-                size="small"
+                size="mini"
                 clearable
                 value-format="yyyy-MM-dd"
                   v-model="queryParams.billDate"
@@ -25,7 +25,7 @@
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="订单类型">
-                <el-select v-model="queryParams.billType" size="small" style="width: 200px" clearable>
+                <el-select v-model="queryParams.billType" size="mini" style="width: 200px" clearable>
                   <el-option v-for="dict in dict.type.sys_allot_billtype" :key="dict.value" :label="dict.label" :value="dict.value">
                   </el-option>
                 </el-select>
@@ -33,7 +33,7 @@
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="调入库存组织">
-                <el-select clearable size="small" v-model="queryParams.storageInventoryOrg" @focus="chooseRefer('ORG_PARAM', true, '调入库存组织')" style="width: 200px">
+                <el-select clearable size="mini" v-model="queryParams.storageInventoryOrg" @focus="chooseRefer('ORG_PARAM', true, '调入库存组织')" style="width: 200px">
                   <el-option v-for="item in ruOrgOptions" :key="item.id" :label="item.name" :value="item.id" />
                 </el-select>
               </el-form-item>
@@ -42,7 +42,7 @@
               <el-form-item label="单据号">
                 <el-input
                   v-model.trim="queryParams.code"
-                  size="small"
+                  size="mini"
                   clearable
                   style="width: 200px"
                 />
@@ -50,8 +50,8 @@
             </el-col>
             <el-col :span="1.5">
               <el-form-item label="" label-width="20px">
-                <el-button type="primary" size="small" icon="el-icon-search" plain @click="searchList">搜索</el-button>
-                <el-button size="small" icon="el-icon-refresh" plain @click="resetList">重置</el-button>
+                <el-button type="primary" size="mini" icon="el-icon-search" plain @click="searchList">搜索</el-button>
+                <el-button size="mini" icon="el-icon-refresh" plain @click="resetList">重置</el-button>
               </el-form-item>
             </el-col>
           </el-row>
@@ -63,7 +63,7 @@
                 <el-form-item label="物料编码">
                   <el-input
                   v-model="queryParams.code"
-                  size="small"
+                  size="mini"
                   placeholder=""
                   clearable
                   style="width: 200px"
@@ -74,7 +74,7 @@
                 <el-form-item label="调入库存组织">
                   <el-input
                   v-model="queryParams.storageInventoryOrg"
-                  size="small"
+                  size="mini"
                   placeholder=""
                   clearable
                   style="width: 200px"
@@ -89,7 +89,7 @@
 
       
         <div class="btn_grooup">
-          <el-button type="primary" size="small" @click="addOrder">新增</el-button>
+          <el-button type="primary" size="mini" @click="addOrder">新增</el-button>
         </div>
 
         <el-table 
@@ -141,9 +141,9 @@
           width="150"
           >
           <template slot-scope="scope">
-            <el-button type="text" size="small" @click="check(scope.row)">查看</el-button>
-            <el-button type="text" size="small" v-if="scope.row.status == '0' || scope.row.status == '3'" @click="edit(scope.row)">编辑</el-button>
-            <el-button type="text" size="small" v-if="scope.row.status == '0' || scope.row.status == '3'" @click="deleteids(scope.row)">删除</el-button>
+            <el-button type="text" size="mini" @click="check(scope.row)">查看</el-button>
+            <el-button type="text" size="mini" v-if="scope.row.status == '0' || scope.row.status == '3'" @click="edit(scope.row)">编辑</el-button>
+            <el-button type="text" size="mini" v-if="scope.row.status == '0' || scope.row.status == '3'" @click="deleteids(scope.row)">删除</el-button>
           </template>
         </el-table-column>
         </el-table>