huangxz
2026-08-17 a8a671b41187d8c63b52ec24f695f2baca8fa4c4
fix(tpd): 测试中/已暂停计划操作列出现两个复制按钮

状态 2/3 分支各把「复制」push 了两次(详情前后各一次),
为补齐复制入口的提交与既有代码叠加所致。删除重复项,
保留分支首位的复制入口,与其他状态分支对齐。
1个文件已修改
2 ■■■■■ 已修改文件
src/views/testDemo/testPlanManagement/index.vue 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/testDemo/testPlanManagement/index.vue
@@ -374,14 +374,12 @@
      if (row.status === 2) { // 测试中
        actions.push(<NButton text type="primary" onClick={() => handleCopy(row)}>复制</NButton>)
        actions.push(<NButton text type="primary" onClick={() => handleDetail(row)} v-permission="2026061523">详情</NButton>)
        actions.push(<NButton text type="primary" onClick={() => handleCopy(row)}>复制</NButton>)
        actions.push(<NButton text type="primary" onClick={() => handleInterrupt(row)} v-permission="2026061525">中断测试</NButton>)
        actions.push(<NButton text type="primary" onClick={() => handleCruise(row)} v-permission="2026061525">{row.cruiseStatus === 1 ? '停止巡游' : '巡游策略'}</NButton>)
      }
      if (row.status === 3) { // 已暂停
        actions.push(<NButton text type="primary" onClick={() => handleCopy(row)}>复制</NButton>)
        actions.push(<NButton text type="primary" onClick={() => handleDetail(row)} v-permission="2026061523">详情</NButton>)
        actions.push(<NButton text type="primary" onClick={() => handleCopy(row)}>复制</NButton>)
        actions.push(<NButton text type="primary" onClick={() => handleClose(row)} v-permission="2026061526">关闭测试</NButton>)
        actions.push(<NButton text type="primary" onClick={() => handleContinue(row)} v-permission="2026061527">继续测试</NButton>)
      }