refactor(shop-list): 操作按钮'查看详情'改为'查看概览'

This commit is contained in:
小蟑螂
2026-04-30 03:02:49 +08:00
parent c37f8a9bb6
commit 00377bdc63
@@ -193,20 +193,6 @@ const [Grid, gridApi] = useVbenVxeGrid({
});
gridReloadRef.value = () => gridApi.reload();
// 加载平台选项
async function fetchPlatformOptions() {
try {
const data = await getActivePlatformsApi();
platformOptions.value = data.map((p: any) => ({
label: p.platformName,
value: p.id,
}));
} catch (error) {
console.error('获取平台列表失败:', error);
}
}
// 刷新表格数据
function refreshTable() {
if (gridApi) {
@@ -241,8 +227,8 @@ function handleModalSuccess() {
refreshTable();
}
// 处理查看详情
function handleViewDetails(record: ShopVO.Info) {
// 处理查看概览
function handleViewOverview(record: ShopVO.Info) {
router.push(`/ecom/shop/overview/${record.id}`);
}
</script>
@@ -290,7 +276,7 @@ function handleViewDetails(record: ShopVO.Info) {
<template #name="{ row }: { row: ShopVO.Info }">
<a
class="text-primary cursor-pointer hover:underline"
@click="handleViewDetails(row)"
@click="handleViewOverview(row)"
>
{{ row.name }}
</a>
@@ -299,8 +285,8 @@ function handleViewDetails(record: ShopVO.Info) {
<!-- 操作列 -->
<template #action="{ row }: { row: any }">
<Space>
<Button size="small" type="primary" @click="handleViewDetails(row)">
查看详情
<Button size="small" type="primary" @click="handleViewOverview(row)">
查看概览
</Button>
<Button size="small" @click="handleEdit(row)"> 编辑 </Button>
<Popconfirm