refactor(servers): 行操作移除删除按钮
Nexus CI/CD / test (push) Waiting to run
Nexus CI/CD / e2e (push) Blocked by required conditions
Nexus CI/CD / deploy (push) Blocked by required conditions
Nexus Pre-commit Checks / quick-check (push) Waiting to run

删除改由批量栏「批量删除」执行,降低误删风险。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
r
2026-06-21 11:35:47 +08:00
parent 2cb0b57281
commit c8efbc2a90
5 changed files with 2 additions and 20 deletions
@@ -40,3 +40,4 @@
- 行按钮改 `small` + `tonal` + 字重 600,恢复「一键登录」全文 - 行按钮改 `small` + `tonal` + 字重 600,恢复「一键登录」全文
- 批量栏改 `flat` 实色按钮、分组标题加深,底卡用 surface 实底 - 批量栏改 `flat` 实色按钮、分组标题加深,底卡用 surface 实底
- 行操作移除「删除」;删除请用批量栏「批量删除」
@@ -48,16 +48,6 @@
> >
编辑 编辑
</v-btn> </v-btn>
<v-btn
size="small"
variant="tonal"
color="error"
density="comfortable"
class="server-row-actions__btn server-row-actions__btn--icon"
icon="mdi-delete-outline"
title="删除服务器"
@click.stop="$emit('delete')"
/>
</div> </div>
</template> </template>
@@ -71,7 +61,6 @@ defineEmits<{
'bt-login': [] 'bt-login': []
files: [] files: []
edit: [] edit: []
delete: []
}>() }>()
</script> </script>
@@ -82,8 +71,4 @@ defineEmits<{
letter-spacing: 0.01em; letter-spacing: 0.01em;
text-transform: none; text-transform: none;
} }
.server-row-actions__btn--icon {
min-width: 36px;
}
</style> </style>
@@ -174,7 +174,6 @@
@bt-login="$emit('bt-login', item)" @bt-login="$emit('bt-login', item)"
@files="$emit('files', item)" @files="$emit('files', item)"
@edit="$emit('edit', item)" @edit="$emit('edit', item)"
@delete="$emit('delete', item)"
/> />
</template> </template>
@@ -241,7 +240,6 @@ const emit = defineEmits<{
'bt-login': [item: ServerApiItem] 'bt-login': [item: ServerApiItem]
files: [item: ServerApiItem] files: [item: ServerApiItem]
edit: [item: ServerApiItem] edit: [item: ServerApiItem]
delete: [item: ServerApiItem]
'edit-path': [item: ServerApiItem] 'edit-path': [item: ServerApiItem]
'save-path': [serverId: number] 'save-path': [serverId: number]
'cancel-edit-path': [] 'cancel-edit-path': []
+1 -1
View File
@@ -7,5 +7,5 @@ export const SERVER_DATA_TABLE_HEADERS = [
{ title: '目标路径', key: 'target_path', width: 200 }, { title: '目标路径', key: 'target_path', width: 200 },
{ title: 'Agent', key: 'agent_version', width: 100 }, { title: 'Agent', key: 'agent_version', width: 100 },
{ title: '心跳', key: 'last_heartbeat', width: 120 }, { title: '心跳', key: 'last_heartbeat', width: 120 },
{ title: '操作', key: 'actions', width: 360, align: 'end' as const, sortable: false }, { title: '操作', key: 'actions', width: 330, align: 'end' as const, sortable: false },
] ]
-2
View File
@@ -62,7 +62,6 @@
@bt-login="openBtLogin($event.id)" @bt-login="openBtLogin($event.id)"
@files="openFiles" @files="openFiles"
@edit="editServer" @edit="editServer"
@delete="confirmDelete"
@edit-path="startEditPath" @edit-path="startEditPath"
@save-path="saveTargetPath" @save-path="saveTargetPath"
@cancel-edit-path="cancelEditPath" @cancel-edit-path="cancelEditPath"
@@ -330,7 +329,6 @@
@bt-login="openBtLogin(item.id)" @bt-login="openBtLogin(item.id)"
@files="openFiles(item)" @files="openFiles(item)"
@edit="editServer(item)" @edit="editServer(item)"
@delete="confirmDelete(item)"
/> />
</template> </template>