Procházet zdrojové kódy

XZT-513,301bug修改

黄梓星 před 2 roky
rodič
revize
2e2ec10564

+ 1 - 1
src/utils/request.js

@@ -28,7 +28,7 @@ service.interceptors.request.use(
     // 是否需要防止数据重复提交
     const isRepeatSubmit = (config.headers || {}).repeatSubmit === false;
     // 是否存在列表查询
-    const isQueryList = config.url.includes("/list");
+    const isQueryList = config.url.includes("/list") || config.url.includes("/query");
     if (getToken() && !isToken) {
       config.headers["Authorization"] = "Bearer " + getToken(); // 让每个请求携带自定义token 请根据实际情况自行修改
     }

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

@@ -21,7 +21,7 @@
           <el-col :span="1.5">
             <el-form-item label="品类">
               <el-select
-              v-model="queryParams.materialName"
+              v-model="queryParams.materialClassifyFourName"
               size="small"
               clearable
               @focus="chooseTreeRefer('MATERIALCLASSIFY_PARAM', false, '选择品类')"
@@ -56,7 +56,7 @@
               <el-form-item label="预测分类">
                 <el-select v-model="queryParams.forecastClassification" size="small" style="width: 200px" clearable>
                   <el-option
-                    v-for="dict in dict.type.predictive_classify" :key="dict.value" :label="dict.label" :value="dict.value">
+                    v-for="dict in dict.type.predictive_classify" :key="dict.value" :label="dict.label" :value="dict.label">
                   </el-option>
                 </el-select>
               </el-form-item>
@@ -467,7 +467,7 @@ export default {
         rowStatus: [],
         buyer: '',
         buyerName: '',
-        materialName: '',
+        materialClassifyFourName: '',
         manufacturer: '',
         forecastClassification: '',
         periodUnit: '',
@@ -563,7 +563,7 @@ export default {
         rowStatus: [],
         buyer: '',
         buyerName: '',
-        materialName: '',
+        materialClassifyFourName: '',
         manufacturer: '',
         forecastClassification: '',
         periodUnit: '',
@@ -743,14 +743,14 @@ export default {
     },
     selectionsToInput2(selection) {
       this.classOptions.push(selection)
-      this.queryParams.materialName = selection.name
+      this.queryParams.materialClassifyFourName = selection.name
     },
     // 搜索区物料编码
     chooseMaterial() {
       this.$refs.materialRefer.init()
     },
     selectMaterial(selection) {
-      this.queryParams.materialCode = selection[0].id
+      this.queryParams.materialCode = selection[0].code
       this.queryParams.names = selection[0].name
     },
         // 明细行选择业务部门参照带出业务部门数据

+ 6 - 4
src/views/purchase/PurchaseDemandList/add.vue

@@ -370,7 +370,7 @@
           <!-- <el-table-column show-overflow-tooltip label="末级供应调拨待入量" align="center"  prop="lastStockQty" width="150px"/> -->
           <!-- <el-table-column show-overflow-tooltip label="上级供应中心现存量" align="center"  prop="superiorCenterQty" width="200px"/> -->
           <!-- <el-table-column show-overflow-tooltip label="上级库存被调拨占用量" align="center"  prop="superiorAllotQty" width="200px"/> -->
-          <!-- <el-table-column show-overflow-tooltip label="可用量" align="center"  prop="availableQty"/> -->
+          <el-table-column show-overflow-tooltip label="可用量" align="center"  prop="availableQty"/>
           <el-table-column show-overflow-tooltip label="调拨状态" align="center"  prop="statusAllot" width="100px">
             <template slot-scope="scope">
               <el-form-item class="hang">
@@ -429,7 +429,7 @@
           <el-table-column show-overflow-tooltip label="详细地址" align="center"  prop="address" width="200px"/>
           <el-table-column show-overflow-tooltip label="价格类型" align="center"  prop="priceType" width="150px">
             <template slot-scope="scope">
-              <el-form-item class="hang">
+              <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-option v-for=" dict in dict.type.sys_price_type" :key="dict.value" :label="dict.label" :value="dict.value">
                   </el-option>
@@ -605,12 +605,14 @@ export default {
       this.getDetails(this.row)
       this.basicForm.id = ''
       this.basicForm.code = ''
+      this.basicForm.createBy = ''
     },
     handleData() {
       console.log('222')
-      // 复制新增把id,编码置为空,子表去掉id
+      // 复制新增把id,编码,创建人置为空,子表去掉id
       this.basicForm.id = ''
       this.basicForm.code = ''
+      this.basicForm.createBy = ''
       if (this.basicForm.puDemandItemList.length !== 0) {
         this.basicForm.puDemandItemList.forEach(item => {
           if (item.id) {
@@ -746,7 +748,7 @@ export default {
         contactsPhone: null,
         address: null,
         source: null,
-        priceType: null,
+        priceType: 'order',
         puManagerApprover: null,
         puManagerApproverName: null,
         processTime: null,

+ 1 - 1
src/views/purchase/PurchaseDemandList/index.vue

@@ -22,7 +22,7 @@
           </el-col>
           <el-col :span="1.5">
             <el-form-item label="是否客户指定">
-              <el-select clearable v-model="queryParams.isProcess" size="small" style="width: 200px" clearable placeholder="请选择">
+              <el-select clearable v-model="queryParams.isProcess" size="small" style="width: 200px" placeholder="请选择">
                 <el-option
                   v-for="item in options"
                   :key="item.value"

+ 8 - 4
src/views/purchase/transferOrder/add.vue

@@ -232,10 +232,11 @@
           max-height="480"
           >
           <el-table-column show-overflow-tooltip label="行号" align="center" prop="rowno"/>
-          <el-table-column show-overflow-tooltip label="物料编码" align="center" prop="material" width="230px">
+          <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.material" @focus="chooseMaterial(scope.$index)">
+                <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>
               </el-form-item>
@@ -818,7 +819,9 @@ export default {
     addLine() {
       const newLine = {
         rowno: null,
+        demandCode: null,
         material: null,
+        materialCode: null,
         materialName: null,
         deliveryCode: null,
         storageCode: null,
@@ -955,7 +958,8 @@ export default {
     },
     selectMaterial(selection) {
       console.log('选中的物料', selection)
-      this.materialInfo[this.tableIndex].material = selection[0].code
+      this.materialInfo[this.tableIndex].material = selection[0].id
+      this.materialInfo[this.tableIndex].materialCode = selection[0].code
       this.materialInfo[this.tableIndex].materialName = selection[0].name
       this.materialInfo[this.tableIndex].specification = selection[0].specification
       this.materialInfo[this.tableIndex].model = selection[0].model
@@ -975,7 +979,7 @@ export default {
     chooseBatch(index) {
       this.tableIndex = index
       this.referConditionMx.orgCode = this.basicForm.deliveryInventoryOrgCode
-      this.referConditionMx.materialCode = this.materialInfo[this.tableIndex].material
+      this.referConditionMx.materialCode = this.materialInfo[this.tableIndex].materialCode
       this.referConditionMx.unitCode = this.materialInfo[this.tableIndex].unitCode
       this.referConditionMx.warehouseCode = this.basicForm.deliveryWarehouseCode
       this.$refs.batchRefer.init(this.referConditionMx)

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

@@ -164,7 +164,7 @@
             max-height="380"
             >
             <el-table-column show-overflow-tooltip label="行号" align="center" prop="rowno"/>
-            <el-table-column show-overflow-tooltip label="物料编码" align="center" prop="material" width="150px"/>
+            <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="150px"/>
             <el-table-column show-overflow-tooltip label="调拨出库单号" align="center" prop="deliveryCode" width="150px"/>
             <el-table-column show-overflow-tooltip label="调拨入库单号" align="center" prop="storageCode" width="150px"/>