Răsfoiți Sursa

fix(销售订单): 修复挂起订单相关逻辑和界面问题

liujt 6 luni în urmă
părinte
comite
f1a17b67d9

+ 1 - 1
src/api/saleManage/saleordersendrecord.js

@@ -124,7 +124,7 @@ export async function getBySendOrderNo(orderNo) {
  * 提交
  */
 export async function suspendProductBatchNoChange(data) {
-  const res = await request.patch(`/eom/saleordersendrecord/suspendProductBatchNoChange/${data.id}?batchNo=${data.batchNo}&orderId=${data.orderId}`, {});
+  const res = await request.patch(`/eom/saleordersendrecord/suspendProductBatchNoChange/${data.id}?batchNo=${data.batchNo}&orderId=${data.orderId}&batchStockId=${data.batchStockId}&warehouseId=${data.warehouseId}&warehouseName=${data.warehouseName}`, {});
   if (res.data.code == 0) {
     return res.data.data;
   }

+ 3 - 0
src/views/saleManage/saleOrder/invoice/components/addInvoiceDialog.vue

@@ -987,6 +987,9 @@ import {
             ) {
               item['isReplace'] = 1;
             }
+            if(this.form.isSuspend == 1) {
+              item['isSuspend'] = 1;
+            }
           });
 
           let commitData = Object.assign({}, this.form, {

+ 42 - 41
src/views/saleManage/saleOrder/invoice/index.vue

@@ -126,30 +126,48 @@
           </template>
           <!-- 操作列 -->
           <template v-slot:action="{ row }">
-            <el-link
-              type="primary"
-              :underline="false"
-              icon="el-icon-edit"
-              @click="openEdit('edit', row)"
-              v-if="
-                ([0, 3].includes(row.reviewStatus) &&
-                  isNeed_process_is_close) ||
-                !isNeed_process_is_close
-              "
-            >
-              修改
-            </el-link>
-            <el-link
-              type="primary"
-              :underline="false"
-              icon="el-icon-plus"
-              @click="sendSubmit(row)"
-              v-if="
-                isNeed_process_is_close && [0, 3].includes(row.reviewStatus)
-              "
-            >
-              提交
-            </el-link>
+            <template v-if="row.suspendReviewStatus == 0 || row.suspendReviewStatus == 3 || row.isSuspend != 1">
+              <el-link
+                type="primary"
+                :underline="false"
+                icon="el-icon-edit"
+                @click="openEdit('edit', row)"
+                v-if="
+                  ([0, 3].includes(row.reviewStatus) &&
+                    isNeed_process_is_close) ||
+                  !isNeed_process_is_close
+                "
+              >
+                修改
+              </el-link>
+              <el-link
+                type="primary"
+                :underline="false"
+                icon="el-icon-plus"
+                @click="sendSubmit(row)"
+                v-if="
+                  isNeed_process_is_close && [0, 3].includes(row.reviewStatus)
+                "
+              >
+                提交
+              </el-link>
+              <el-popconfirm
+                class="ele-action"
+                title="确定要删除此信息吗?"
+                @confirm="remove([row.id])"
+                v-if="
+                  (isNeed_process_is_close &&
+                    [0, 3].includes(row.reviewStatus)) ||
+                  !isNeed_process_is_close
+                "
+              >
+                <template v-slot:reference>
+                  <el-link type="danger" :underline="false" icon="el-icon-delete">
+                    删除
+                  </el-link>
+                </template>
+              </el-popconfirm>
+            </template>
             <el-link
               type="primary"
               :underline="false"
@@ -159,23 +177,6 @@
             >
               导出
             </el-link>
-
-            <el-popconfirm
-              class="ele-action"
-              title="确定要删除此信息吗?"
-              @confirm="remove([row.id])"
-              v-if="
-                (isNeed_process_is_close &&
-                  [0, 3].includes(row.reviewStatus)) ||
-                !isNeed_process_is_close
-              "
-            >
-              <template v-slot:reference>
-                <el-link type="danger" :underline="false" icon="el-icon-delete">
-                  删除
-                </el-link>
-              </template>
-            </el-popconfirm>
             <el-link
               type="primary"
               :underline="false"

+ 6 - 5
src/views/saleManage/saleOrder/suspend/components/offsettingDialig.vue

@@ -24,7 +24,6 @@
       :model="form"
       :rules="rules"
       class="el-form-box"
-      label-width="160px"
     >
       <!-- <headerTitle title="基本信息"></headerTitle> -->
       <!-- <el-row :gutter="20">
@@ -141,8 +140,7 @@
                 <el-form-item :prop="'datasource.' + scope.$index + '.batchStockId'">
                 <!-- <el-input v-model="scope.row.batchNo" v-no-chinese></el-input> -->
                 <el-select
-                    v-model="scope.row.batchStockId"
-                    clearable 
+                    v-model="scope.row.batchStockId" 
                     placeholder="请选择"
                     @change="batchNoChange(scope.$index, scope.row)"
                 >
@@ -863,8 +861,11 @@
             }
             suspendProductBatchNoChange({
                 id: row.id,
-                batchNo:row.batchNo,
+                batchNo: row.batchNo,
                 orderId:this.currentItem.id,
+                batchStockId: row.batchStockId,
+                warehouseId: row.warehouseId,
+                warehouseName: row.warehouseName,
             }).then(res => {
                 console.log('res~~~~', res);
                 this.$set(this.form.datasource[index], 'isSuspend', 0);
@@ -1450,6 +1451,6 @@
   }
 
   ::v-deep .el-form-item__content {
-    margin-left: 0!important;
+    margin-left: 0;
   }
 </style>

+ 1 - 2
src/views/saleManage/saleOrder/suspend/index.vue

@@ -192,7 +192,7 @@
               :underline="false"
               icon="el-icon-plus"
               @click="handleCommand('suspend', row)"
-           
+              v-if="row.shipmentReviewStatus == 2"
             >
             <!-- v-if="row.shipmentReviewStatus == 2" -->
             <!-- v-if="
@@ -248,7 +248,6 @@
     <add-invoice-dialog
       ref="invoiceDialogRef"
       @done="reload"
-      :contactData="contactData"
     ></add-invoice-dialog>
     <!-- <add-return-goods-dialog
       ref="addReturnGoodsRef"