فهرست منبع

Merge branch 'dev' of http://110.41.163.243:9980/kd-aiot/kd-aiot-frontend-eom into dev

yusheng 10 ماه پیش
والد
کامیت
4dd01c114d
1فایلهای تغییر یافته به همراه37 افزوده شده و 17 حذف شده
  1. 37 17
      src/views/salesServiceManagement/cost/index.vue

+ 37 - 17
src/views/salesServiceManagement/cost/index.vue

@@ -38,20 +38,30 @@
         <template v-slot:action="{ row }">
           <el-link
             type="primary"
-            v-if="row.approvalStatus == 0 && $hasPermission('eom:aftersalesrealcost:submit')"
+            v-if="
+              row.approvalStatus == 0 &&
+              $hasPermission('eom:aftersalesrealcost:submit')
+            "
             :underline="false"
             @click="openProcess(row)"
             >提交</el-link
           >
           <el-link
-            v-if="row.approvalStatus == 0 && $hasPermission('eom:aftersalesrealcost:update')"
+            v-if="
+              row.approvalStatus == 0 &&
+              $hasPermission('eom:aftersalesrealcost:update')
+            "
             type="primary"
             :underline="false"
             @click="openEdit(row, 'edit')"
             >修改</el-link
           >
           <el-popconfirm
-            v-if="(row.approvalStatus == 0 && row.source != 1) && $hasPermission('eom:aftersalesrealcost:delete')"
+            v-if="
+              row.approvalStatus == 0 &&
+              row.source != 1 &&
+              $hasPermission('eom:aftersalesrealcost:delete')
+            "
             class="ele-action"
             title="确定要删除当前费用清单数据吗?"
             @confirm="deleteCost(row)"
@@ -84,6 +94,8 @@
     costDelete,
     aftersalesrealcost
   } from '@/api/salesServiceManagement/index';
+
+  import { salesrealcostinfo } from '@/api/salesServiceManagement/index';
   export default {
     components: {
       search,
@@ -111,19 +123,19 @@
           {
             label: '审核不通过',
             value: 3
-          },
-        //   {
-        //     label: '终止审核中',
-        //     value: 4
-        //   },
-        //   {
-        //     label: '终止审核通过',
-        //     value: 5
-        //   },
-        //   {
-        //     label: '流程废止',
-        //     value: 7
-        //   }
+          }
+          //   {
+          //     label: '终止审核中',
+          //     value: 4
+          //   },
+          //   {
+          //     label: '终止审核通过',
+          //     value: 5
+          //   },
+          //   {
+          //     label: '流程废止',
+          //     value: 7
+          //   }
         ]
       };
     },
@@ -219,7 +231,15 @@
       },
 
       // 提交
-      openProcess(data) {
+      async openProcess(data) {
+        const res = await salesrealcostinfo(data.id);
+
+        if (res.detailLst.length == 0) {
+          this.$message.warning('请至少添加一条费用清单');
+          return;
+        }
+
+
         this.processSubmitDialogFlag = true;
         this.$nextTick(() => {
           let params = {