Merge branch 'feature/BRT-23-classify' of http://git.yilibili.com/1-bright/admin into feature/24-article

This commit is contained in:
chen committed 2024-11-21 23:19:47 +08:00
commit 2e38fdff5f
3 files changed
+6 -16

No files matched your search

+3 -10
View File
@@ -51,8 +51,8 @@ const handleCategoryDialogClosed = () => {
isEdit.value = false
currentTableData.value = {}
}
const deleteCategoryClick = async (category: Category) => {
await deleteCategoryRequest({ id: category.id })
const deleteCategoryClick = async (id: string) => {
await deleteCategoryRequest(id)
fetchData()
MessagePlugin.success('删除分类成功')
}
@@ -80,13 +80,6 @@ const deleteCategoryClick = async (category: Category) => {
onChange: onPageChange
}"
>
<template #roles="{ row }">
<TSpace>
<TTag v-for="role in row.roles" :key="role.id" theme="success" variant="light">{{
role.label
}}</TTag>
</TSpace>
</template>
<template #operation="{ row }">
<TSpace :size="1">
<TButton variant="text" size="small" theme="primary" @click="editClick(row)"
@@ -95,7 +88,7 @@ const deleteCategoryClick = async (category: Category) => {
<t-popconfirm
theme="default"
content="确认删除此项分类吗"
@confirm="deleteCategoryClick(row)"
@confirm="deleteCategoryClick(row.id)"
>
<TButton variant="text" size="small" theme="danger">删除</TButton>
</t-popconfirm>