Browse Source

bug修改

黄梓星 2 years ago
parent
commit
8e8b4cd84a

+ 3 - 1
src/components/PopDialog/index.vue

@@ -56,6 +56,7 @@ export default {
       searchForm: {
         code: '',
         name: '',
+        isSync: '',
         pageNo: 1,
         pageSize: 10,
       },
@@ -82,8 +83,9 @@ export default {
     }
   },
   methods: {
-    init() {
+    init(val) {
       this.visible = true;
+      this.searchForm.isSync = val
       this.$nextTick(() => {
         this.dataListAllSelections = JSON.parse(JSON.stringify(this.selectData));
         this.resetSearch();

+ 2 - 2
src/components/Refers/batchRefer.vue

@@ -112,8 +112,8 @@ export default {
     },
     // 排序
     resetSearch() {
-      this.$refs['searchForm'].resetFields();
-      this.searchForm.pageNo = 1;
+      this.searchForm.pageNo = 1
+      this.searchForm.search = ''
       this.refreshList();
     },
     // 表格选中数据

+ 2 - 2
src/components/Refers/refers.vue

@@ -112,8 +112,8 @@ export default {
     },
     // 排序
     resetSearch() {
-      this.$refs['searchForm'].resetFields();
-      this.searchForm.pageNo = 1;
+      this.searchForm.pageNo = 1
+      this.searchForm.search = ''
       this.refreshList();
     },
     // 表格选中数据

+ 1 - 1
src/views/purchase/DemandSummary/add.vue

@@ -1,7 +1,7 @@
 <template>
   <div id="checkDemandSummary">
     <el-card>
-      <span>采购需求汇总详情</span>
+      <span>采购需求处理详情</span>
       <div class="btn_grooup">
         <el-button type="primary" size="small" @click="editLine">编辑</el-button>
         <el-button type="success" size="small" v-if="!lineDisable" @click="saveLine">保存</el-button>

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

@@ -468,9 +468,9 @@ export default {
       lastAllocationOptions: [],
       orgOptions: [],
       options: [{
-        value: '0', label: '是',
+        value: 'Y', label: '是',
       }, {
-        value: '2', label: '否'
+        value: 'N', label: '否'
       }],
       referCondition: {
         type: '',

+ 5 - 3
src/views/purchase/MaterialClassDivision/add.vue

@@ -160,7 +160,7 @@
          <el-col :span="1.5">
             <el-form-item label="订单部门">
               <el-input
-                v-model="basicForm.orderDept"
+                v-model="basicForm.orderDeptName"
                 size="small"
                 disabled
                 style="width: 200px"
@@ -192,7 +192,7 @@
           <el-col :span="1.5">
             <el-form-item label="采购部门">
               <el-input
-                v-model="basicForm.puDept"
+                v-model="basicForm.puDeptName"
                 size="small"
                 disabled
                 style="width: 200px"
@@ -307,7 +307,9 @@ export default {
         remark: ''
       },
       options: [{
-        value: 0, label: '仓库1'
+        value: 'Y', label: '是',
+      }, {
+        value: 'N', label: '否'
       }],
       referCondition: {
         type: '',

+ 3 - 1
src/views/purchase/MaterialClassDivision/index.vue

@@ -319,7 +319,9 @@ export default {
         pageSize: 5
       },
       options: [{
-        value: 0, label: '仓库1'
+        value: 'Y', label: '是',
+      }, {
+        value: 'N', label: '否'
       }],
       staffOptions: [],
       staff2Options: [],

+ 7 - 53
src/views/purchase/PurchaseDemandList/add.vue

@@ -85,7 +85,7 @@
             <el-form-item label="需求日期">
               <el-date-picker
                 v-model="basicForm.demandDate"
-                disabled
+                :disabled="sonDisable"
                 type="date"
                 value-format="yyyy-MM-dd"
                 size="small"
@@ -104,22 +104,6 @@
             </el-form-item>
          </el-col>
 
-          <el-col :span="1.5">
-            <el-form-item label="供应仓库">
-              <el-select size="small" v-model="basicForm.warehouse" :disabled="sonDisable" @focus="chooseOrg('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>
-         </el-col>
-
-         <el-col :span="1.5">
-            <el-form-item label="供应货位">
-              <el-select size="small" v-model="basicForm.goodsAllocation" :disabled="sonDisable" @focus="chooseOrg('ALLOCATION_PARAM', true, '供应货位')" style="width: 200px">
-                <el-option v-for="item in goodsOptions" :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">
@@ -151,20 +135,9 @@
          </el-col> -->
 
           <el-col :span="1.5">
-            <el-form-item label="是否月销量计算">
-              <el-input
-                v-model="basicForm.isMonthleyCalculate"
-                size="small"
-                disabled
-                style="width: 200px"
-              />
-            </el-form-item>
-         </el-col>
-
-          <el-col :span="1.5">
             <el-form-item label="备注">
               <el-input
-                v-model="basicForm.remark"
+                v-model.trim="basicForm.remark"
                 size="small"
                 :disabled="sonDisable"
                 clearable
@@ -584,9 +557,7 @@ export default {
         demandPersonal: '',
         demandDept: '',
         demandDate: '',
-        source: '1',
-        warehouse: '',
-        goodsAllocation: '',
+        source: '4',
         billType: '',
         isSpeical: '',
         isProcess: '',
@@ -595,9 +566,9 @@ export default {
         puDemandItemList: []
       },
       options: [{
-        value: '0', label: '是',
+        value: 'Y', label: '是',
       }, {
-        value: '2', label: '否'
+        value: 'N', label: '否'
       }],
       basicRules: {},
       tableList: [],
@@ -617,8 +588,6 @@ export default {
       personOptions: [],
       deptOptions: [],
       customerOptions: [],
-      houseOptions: [],
-      goodsOptions: []
     }
   },
   created() {
@@ -834,8 +803,6 @@ export default {
               if(this.basicForm.customer) { this.reBackRefer('CUSTOMER_PARAM', this.basicForm.customer) }
               if(this.basicForm.demandPersonal) { this.reBackRefer('CONTACTS_PARAM', this.basicForm.demandPersonal) }
               if(this.basicForm.demandDept) { this.reBackRefer('DEPT_PARAM', this.basicForm.demandDept) }
-              if(this.basicForm.warehouse) { this.reBackRefer('WAREHOUSE_PARAM', this.basicForm.warehouse) }
-              if(this.basicForm.goodsAllocation) { this.reBackRefer('ALLOCATION_PARAM', this.basicForm.goodsAllocation) }
             }
             console.log('111')
           })
@@ -866,12 +833,6 @@ export default {
         if (type == 'DEPT_PARAM') {
           this.deptOptions = res.rows
         }
-        if (type == 'WAREHOUSE_PARAM') {
-          this.houseOptions = res.rows
-        }
-        if (type == 'ALLOCATION_PARAM') {
-          this.goodsOptions = res.rows
-        }
       })
     },
     chooseOrg(type, isPage, title) {
@@ -902,14 +863,6 @@ export default {
         this.deptOptions = selection
         this.basicForm.demandDept = selection[0].id
       }
-      if(this.referCondition.type == 'WAREHOUSE_PARAM') {
-        this.houseOptions = selection
-        this.basicForm.warehouse = selection[0].id
-      }
-      if(this.referCondition.type == 'ALLOCATION_PARAM') {
-        this.goodsOptions = selection
-        this.basicForm.goodsAllocation = selection[0].id
-      }
       // if(this.referConditionMx.type == 'DEPT_PARAM') {
       //   this.basicForm.puDemandItemList[this.tableIndex].businessDept = selection[0].code
       //   this.basicForm.puDemandItemList[this.tableIndex].businessDeptName = selection[0].name
@@ -943,7 +896,8 @@ export default {
     chooseMaterial(index) {
       console.log("🚀 ~ file: add.vue:790 ~ chooseMaterial ~ index:", index)
       this.tableIndex = index
-      this.$refs.materialRefer.init()
+      // 传0只展示同步NC了的物料
+      this.$refs.materialRefer.init(0)
     },
     selectMaterial(selection) {
       console.log('选中的物料', selection)

+ 12 - 38
src/views/purchase/PurchaseDemandList/index.vue

@@ -6,29 +6,23 @@
           <el-col :span="1.5">
             <el-form-item label="单据编码">
               <el-input
-                v-model="queryParams.code"
+                v-model.trim="queryParams.code"
                 size="small"
+                clearable
                 style="width: 200px"
               />
             </el-form-item>
           </el-col>
           <el-col :span="1.5">
-            <el-form-item label="供应仓库">
-              <el-select size="small" v-model="queryParams.warehouse" @focus="chooseOrg('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>
-          </el-col>
-          <el-col :span="1.5">
             <el-form-item label="需求客户">
-              <el-select size="small" v-model="queryParams.customer" @focus="chooseOrg('CUSTOMER_PARAM', true, '选择客户')" style="width: 200px">
+              <el-select clearable size="small" 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 v-model="queryParams.isProcess" size="small" style="width: 200px" clearable placeholder="请选择">
+              <el-select clearable v-model="queryParams.isProcess" size="small" style="width: 200px" clearable placeholder="请选择">
                 <el-option
                   v-for="item in options"
                   :key="item.value"
@@ -50,21 +44,14 @@
         <el-row :gutter="10">
           <el-col :span="1.5">
             <el-form-item label="需求人员">
-              <el-select size="small" v-model="queryParams.demandPersonal" @focus="chooseOrg('CONTACTS_PARAM', true, '需求人员')" style="width: 200px">
+              <el-select clearable size="small" 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.id" />
               </el-select>
             </el-form-item>
           </el-col>
           <el-col :span="1.5">
-            <el-form-item label="供应货位">
-              <el-select size="small" v-model="queryParams.goodsAllocation" @focus="chooseOrg('ALLOCATION_PARAM', true, '供应货位')" style="width: 200px">
-                <el-option v-for="item in goodsOptions" :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.source" size="small" style="width: 200px">
+              <el-select clearable v-model="queryParams.source" size="small" 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>
@@ -75,7 +62,7 @@
         <el-row :gutter="10">
           <el-col :span="1.5">
             <el-form-item label="业务类型">
-              <el-select v-model="queryParams.billType" size="small" style="width: 200px">
+              <el-select clearable v-model="queryParams.billType" size="small" 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>
@@ -83,7 +70,7 @@
           </el-col>
           <el-col :span="1.5">
             <el-form-item label="需求部门">
-              <el-select v-model="queryParams.demandDept" size="small" :disabled="disable" @focus="chooseOrg('DEPT_PARAM', true, '需求部门')" style="width: 200px">
+              <el-select clearable v-model="queryParams.demandDept" size="small" :disabled="disable" @focus="chooseOrg('DEPT_PARAM', true, '需求部门')" style="width: 200px">
                 <el-option
                   v-for="item in deptOptions"
                   :key="item.id"
@@ -98,6 +85,7 @@
               <el-date-picker
                 v-model="queryParams.demandDate"
                 type="date"
+                clearable
                 value-format="yyyy-MM-dd"
                 size="small"
                 style="width: 200px"
@@ -108,7 +96,7 @@
           <el-col :span="1.5">
             <el-form-item label="备注">
             <el-input
-              v-model="queryParams.remark"
+              v-model.trim="queryParams.remark"
               size="small"
               clearable
               style="width: 200px"
@@ -271,11 +259,9 @@ export default {
       page: '',
       queryParams: {
         code: '',
-        warehouse: '',
         customer: '',
         isProcess: '',
         demandPersonal: '',
-        goodsAllocation: '',
         source: '',
         billType: '',
         demandDept: '',
@@ -290,14 +276,12 @@ export default {
         title: ''
       },
       options: [{
-        value: '0', label: '是',
+        value: 'Y', label: '是',
       }, {
-        value: '2', label: '否'
+        value: 'N', label: '否'
       }],
-      houseOptions: [],
       customerOptions: [],
       personOptions: [],
-      goodsOptions: [],
       deptOptions: [],
       tableList: [],
       total: 0,
@@ -359,11 +343,9 @@ export default {
     resetList() {
       this.queryParams = {
         code: '',
-        warehouse: '',
         customer: '',
         isProcess: '',
         demandPersonal: '',
-        goodsAllocation: '',
         source: '',
         billType: '',
         demandDept: '',
@@ -538,10 +520,6 @@ export default {
       this.$refs.refer.init(this.referCondition)
     },
     selectionsToInput(selection) {
-      if (this.referCondition.type == 'WAREHOUSE_PARAM') {
-        this.houseOptions = selection
-        this.queryParams.warehouse = selection[0].id
-      }
       if (this.referCondition.type == 'CUSTOMER_PARAM') {
         this.customerOptions = selection
         this.queryParams.customer = selection[0].id
@@ -550,10 +528,6 @@ export default {
         this.personOptions = selection
         this.queryParams.demandPersonal = selection[0].id
       }
-      if (this.referCondition.type == 'ALLOCATION_PARAM') {
-        this.goodsOptions = selection
-        this.queryParams.goodsAllocation = selection[0].id
-      }
       if (this.referCondition.type == 'DEPT_PARAM') {
         this.deptOptions = selection
         this.queryParams.demandDept = selection[0].id

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

@@ -191,14 +191,14 @@ export default {
         title: ''
       },
       options: [{
-        value: '0', label: '启用',
+        value: 'Y', label: '启用',
       }, {
-        value: '2', label: '停用'
+        value: 'N', label: '停用'
       }],
       options2: [{
-        value: '0', label: '已同步',
+        value: 'Y', label: '已同步',
       }, {
-        value: '2', label: '未同步'
+        value: 'N', label: '未同步'
       }],
       houseOptions: [],
       contactsOptions: [],

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

@@ -266,14 +266,14 @@ export default {
         pageSize: 5
       },
       options: [{
-        value: '0', label: '启用',
+        value: 'Y', label: '是',
       }, {
-        value: '2', label: '停用'
+        value: 'N', label: '否'
       }],
       options2: [{
-        value: '0', label: '已同步',
+        value: 'Y', label: '已同步',
       }, {
-        value: '2', label: '未同步'
+        value: 'N', label: '未同步'
       }],
       referCondition: {
         type: '',

+ 2 - 2
src/views/purchase/transferOrder/add.vue

@@ -619,9 +619,9 @@ export default {
         warehouseCode: ''
       },
       options: [{
-        value: '0', label: '是',
+        value: 'Y', label: '是',
       }, {
-        value: '2', label: '否'
+        value: 'N', label: '否'
       }],
       tableIndex: null,
       chuOrgOptions: [],