Browse Source

fix(forecast): 修复菜单固定问题并添加禁用编辑按钮

yz 1 month ago
parent
commit
4643868d2c
2 changed files with 7 additions and 1 deletions
  1. 2 1
      src/views/forecast/forecastIndex.js
  2. 5 0
      src/views/forecast/index.vue

+ 2 - 1
src/views/forecast/forecastIndex.js

@@ -104,7 +104,8 @@ export default {
         editBtnText: '编辑',
         menu: true,
         menuWidth: 200,
-        menuFixed: true,
+        menuFixed: false,
+        // menuFixed: 'right',
         expand: true,
         expandRowKeys: [],
         defaultExpandAll: false,

+ 5 - 0
src/views/forecast/index.vue

@@ -43,6 +43,11 @@
           </el-button>
         </template>
 
+        <!-- 新增:操作列(禁用“不可编辑”按钮) -->
+        <template slot="menu" slot-scope="{ row, index }">
+          <el-button type="text" size="small" disabled>不可编辑</el-button>
+        </template>
+
         <!-- 自定义审批状态显示 -->
         <template slot-scope="{row}" slot="approvalStatus">
           <el-tag