Browse Source

对比优化

wyh 1 year ago
parent
commit
38e61ce4ea
1 changed files with 13 additions and 3 deletions
  1. 13 3
      src/views/module_kzks/projectCostList/ProjectCostList.vue

+ 13 - 3
src/views/module_kzks/projectCostList/ProjectCostList.vue

@@ -170,7 +170,9 @@
           getCheckboxProps: (record) => ({
             props: {
               //disabled: record.id == 'amount', // 禁选的条件为:合计行不可选
-              disabled: record.id == 'amount' || (record.ji && chooseRowType == 'huiji')
+              disabled: record.id == 'amount' ||
+              (record.ji== '1' && chooseRowType == 'huiji') ||
+              (record.ji== '2' && chooseRowType == 'chengben')
             },
           }),}"
         @change="handleTableChange"
@@ -566,6 +568,12 @@ import ProjectImportListModal from '../projectImportList/modules/ProjectImportLi
             align:"center",
             dataIndex: 'scgs'
           },
+          // {
+          //   title:'级别',
+          //   align:"center",
+          //   dataIndex: 'ji',
+          //   customCell: this.getClickColumn,
+          // },
           {
             title: '操作',
             dataIndex: 'action',
@@ -837,11 +845,13 @@ import ProjectImportListModal from '../projectImportList/modules/ProjectImportLi
       // 对比禁选判断
       onSelect(record, selected, selectedRows, nativeEvent){
         console.log(record, selected, selectedRows, nativeEvent)
-        console.log(record.children)
-        if (record.children == undefined) {
+        console.log(record.ji)
+        if (record.ji == '2') {
           // 选中二级,一级禁选
+          this.chooseRowType == 'chengben'
         } else {
           // 选中一级,二级禁选
+          this.chooseRowType == 'huiji'
         }
       }