فهرست منبع

fix:/costVerifyTemplate/v1/listEnabled 添加请求传参catalogId

luzhixia 1 هفته پیش
والد
کامیت
87a3619af8
2فایلهای تغییر یافته به همراه14 افزوده شده و 6 حذف شده
  1. 2 1
      src/api/costFormManage.js
  2. 12 5
      src/views/costAudit/baseInfo/costVerifyManage/index.vue

+ 2 - 1
src/api/costFormManage.js

@@ -128,10 +128,11 @@ export function batchDeleteCostVerifyForm(data) {
 }
 
 // 获取所有状态为启用的成本核定表模板数据
-export function getActiveCostVerifyFormList() {
+export function getActiveCostVerifyFormList(params) {
   return request({
     url: `${url}/costVerifyTemplate/v1/listEnabled`,
     method: 'get',
+    params,
   })
 }
 

+ 12 - 5
src/views/costAudit/baseInfo/costVerifyManage/index.vue

@@ -267,6 +267,7 @@
                 :options="catalogListOptions"
                 v-bind="props"
                 style="width: 100%"
+                @change="handleCatalogChange"
               ></el-cascader>
             </el-form-item>
           </el-col>
@@ -341,7 +342,8 @@
                 :disabled="
                   dialogTitle == '查看成本核定模板' ||
                   dialogTitle == '修改成本核定模板' ||
-                  contentEditForm.surveyTemplateId != ''
+                  contentEditForm.surveyTemplateId != '' ||
+                  contentEditForm.catalogId == ''
                 "
               >
                 <el-option
@@ -1335,7 +1337,9 @@
       },
       // 获取所有状态为启用的成本核定表模板数据
       getActiveCostVerifyFormList() {
-        getActiveCostVerifyFormList().then((res) => {
+        getActiveCostVerifyFormList({
+          catalogId: this.contentEditForm.catalogId,
+        }).then((res) => {
           if (res.code === 200) {
             this.contentEditFormList = res.value
           }
@@ -1449,8 +1453,7 @@
             fixedTablesTitle: [],
           },
         }
-        // 成本核定表模板列表
-        this.getActiveCostVerifyFormList()
+
         // 成本调查表模板列表
         this.getActiveCostVerifyFormListByType()
         this.dialogVisible = true
@@ -1460,7 +1463,11 @@
             this.$refs.contentEditForm.clearValidate()
           }
         })
-        console.log('this.contentEditForm', this.contentEditForm)
+      },
+      // 级联选择器改变时触发
+      handleCatalogChange(val) {
+        // 成本核定表模板列表
+        this.getActiveCostVerifyFormList()
       },
 
       // 修改