瀏覽代碼

项目成本合计不可点击

yuhan 1 年之前
父節點
當前提交
754e4f2f05
共有 1 個文件被更改,包括 9 次插入2 次删除
  1. 9 2
      src/views/module_kzks/projectCostList/ProjectCostList.vue

+ 9 - 2
src/views/module_kzks/projectCostList/ProjectCostList.vue

@@ -163,7 +163,14 @@
         class="j-table-force-nowrap"
         :expandedRowKeys="expandedRowKeys"
         @expand="onExpand"
-        :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
+        :rowSelection="{
+          selectedRowKeys: selectedRowKeys,
+          onChange: onSelectChange,
+          getCheckboxProps: (record) => ({
+            props: {
+              disabled: record.id == 'amount', // 禁选的条件为:合计行不可选
+            },
+          }),}"
         @change="handleTableChange"
         :indentSize="12">
 
@@ -717,7 +724,7 @@ import ProjectImportListModal from '../projectImportList/modules/ProjectImportLi
         columnsEdit({checkedValues: checkedValues})
       },
       getClickColumn(record, index){
-        if(record.children){
+        if(record.children || record.id === 'amount'){
           return false
         }
         return {