mirror of
https://gitee.com/dapppp/ruoyi-plus-vben5.git
synced 2026-04-12 00:13:16 +08:00
refactor(components): 重命名 GhostButton 为 ActionButton 以更准确描述用途
This commit is contained in:
@@ -6,8 +6,8 @@ import { omit } from 'lodash-es';
|
|||||||
/**
|
/**
|
||||||
* 表格操作列按钮专用
|
* 表格操作列按钮专用
|
||||||
*/
|
*/
|
||||||
export const GhostButton = defineComponent({
|
export const ActionButton = defineComponent({
|
||||||
name: 'GhostButton',
|
name: 'ActionButton',
|
||||||
props: omit({}, ['type', 'ghost', 'size']),
|
props: omit({}, ['type', 'ghost', 'size']),
|
||||||
setup(props, { attrs, slots }) {
|
setup(props, { attrs, slots }) {
|
||||||
return () =>
|
return () =>
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import type { App } from 'vue';
|
|||||||
|
|
||||||
import { Button as AButton } from 'antdv-next';
|
import { Button as AButton } from 'antdv-next';
|
||||||
|
|
||||||
import { GhostButton } from './button';
|
import { ActionButton } from './button';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 全局组件注册
|
* 全局组件注册
|
||||||
@@ -10,7 +10,7 @@ import { GhostButton } from './button';
|
|||||||
export function setupGlobalComponent(app: App) {
|
export function setupGlobalComponent(app: App) {
|
||||||
app.component('AButton', AButton);
|
app.component('AButton', AButton);
|
||||||
// 表格操作列专用按钮
|
// 表格操作列专用按钮
|
||||||
app.component('GhostButton', GhostButton);
|
app.component('ActionButton', ActionButton);
|
||||||
}
|
}
|
||||||
|
|
||||||
export { default as ApiSwitch } from './api-switch.vue';
|
export { default as ApiSwitch } from './api-switch.vue';
|
||||||
|
|||||||
@@ -137,25 +137,25 @@ function handleMultiDelete() {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:demo:edit']"
|
v-access:code="['system:demo:edit']"
|
||||||
@click.stop="handleEdit(row)"
|
@click.stop="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
:get-popup-container="getPopupContainer"
|
:get-popup-container="getPopupContainer"
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:demo:remove']"
|
v-access:code="['system:demo:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -118,25 +118,25 @@ function collapseAll() {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:tree:edit']"
|
v-access:code="['system:tree:edit']"
|
||||||
@click.stop="handleEdit(row)"
|
@click.stop="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
:get-popup-container="getPopupContainer"
|
:get-popup-container="getPopupContainer"
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:tree:remove']"
|
v-access:code="['system:tree:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -184,21 +184,21 @@ function handleDownloadExcel() {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button @click.stop="handlePreview(row)">
|
<action-button @click.stop="handlePreview(row)">
|
||||||
{{ $t('pages.common.info') }}
|
{{ $t('pages.common.info') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="() => handleDelete(row)"
|
@confirm="() => handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['monitor:logininfor:remove']"
|
v-access:code="['monitor:logininfor:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -92,7 +92,7 @@ async function handleForceOffline(row: OnlineUser) {
|
|||||||
placement="left"
|
placement="left"
|
||||||
@confirm="handleForceOffline(row)"
|
@confirm="handleForceOffline(row)"
|
||||||
>
|
>
|
||||||
<ghost-button danger>强制下线</ghost-button>
|
<action-button danger>强制下线</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</template>
|
</template>
|
||||||
</BasicTable>
|
</BasicTable>
|
||||||
|
|||||||
@@ -171,12 +171,12 @@ function handleDownloadExcel() {
|
|||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['monitor:operlog:list']"
|
v-access:code="['monitor:operlog:list']"
|
||||||
@click.stop="handlePreview(row)"
|
@click.stop="handlePreview(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.preview') }}
|
{{ $t('pages.common.preview') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</template>
|
</template>
|
||||||
</BasicTable>
|
</BasicTable>
|
||||||
<OperationPreviewDrawer />
|
<OperationPreviewDrawer />
|
||||||
|
|||||||
@@ -161,26 +161,26 @@ async function handleChangeStatus(checked: boolean, row: Client) {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:client:edit']"
|
v-access:code="['system:client:edit']"
|
||||||
@click.stop="handleEdit(row)"
|
@click.stop="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
:disabled="row.id === 1"
|
:disabled="row.id === 1"
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
:disabled="row.id === 1"
|
:disabled="row.id === 1"
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:client:remove']"
|
v-access:code="['system:client:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -148,24 +148,24 @@ async function handleRefreshCache() {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:config:edit']"
|
v-access:code="['system:config:edit']"
|
||||||
@click.stop="handleEdit(row)"
|
@click.stop="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:config:remove']"
|
v-access:code="['system:config:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -148,32 +148,32 @@ function setExpandOrCollapse(expand: boolean) {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:dept:edit']"
|
v-access:code="['system:dept:edit']"
|
||||||
@click="handleEdit(row)"
|
@click="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<ghost-button
|
<action-button
|
||||||
variant="link"
|
variant="link"
|
||||||
color="green"
|
color="green"
|
||||||
v-access:code="['system:dept:add']"
|
v-access:code="['system:dept:add']"
|
||||||
@click="handleSubAdd(row)"
|
@click="handleSubAdd(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.add') }}
|
{{ $t('pages.common.add') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:dept:remove']"
|
v-access:code="['system:dept:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -154,24 +154,24 @@ emitter.on('rowClick', async (value) => {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:dict:edit']"
|
v-access:code="['system:dict:edit']"
|
||||||
@click="handleEdit(row)"
|
@click="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:dict:remove']"
|
v-access:code="['system:dict:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -167,24 +167,24 @@ function handleDownloadExcel() {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:dict:edit']"
|
v-access:code="['system:dict:edit']"
|
||||||
@click.stop="handleEdit(row)"
|
@click.stop="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:dict:remove']"
|
v-access:code="['system:dict:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -221,15 +221,15 @@ const isAdmin = computed(() => {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:menu:edit']"
|
v-access:code="['system:menu:edit']"
|
||||||
v-access:role="['superadmin']"
|
v-access:role="['superadmin']"
|
||||||
@click="handleEdit(row)"
|
@click="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<!-- '按钮类型'无法再添加子菜单 -->
|
<!-- '按钮类型'无法再添加子菜单 -->
|
||||||
<ghost-button
|
<action-button
|
||||||
v-if="row.menuType !== 'F'"
|
v-if="row.menuType !== 'F'"
|
||||||
variant="link"
|
variant="link"
|
||||||
color="green"
|
color="green"
|
||||||
@@ -238,20 +238,20 @@ const isAdmin = computed(() => {
|
|||||||
@click="handleSubAdd(row)"
|
@click="handleSubAdd(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.add') }}
|
{{ $t('pages.common.add') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
:title="removeConfirmTitle(row)"
|
:title="removeConfirmTitle(row)"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:menu:remove']"
|
v-access:code="['system:menu:remove']"
|
||||||
v-access:role="['superadmin']"
|
v-access:role="['superadmin']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -119,24 +119,24 @@ function handleMultiDelete() {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:notice:edit']"
|
v-access:code="['system:notice:edit']"
|
||||||
@click="handleEdit(row)"
|
@click="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:notice:remove']"
|
v-access:code="['system:notice:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -145,24 +145,24 @@ async function handleChangeStatus(checked: boolean, row: OssConfig) {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:ossConfig:edit']"
|
v-access:code="['system:ossConfig:edit']"
|
||||||
@click="handleEdit(row)"
|
@click="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:ossConfig:remove']"
|
v-access:code="['system:ossConfig:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -289,24 +289,24 @@ const [UploadTestModal, uploadTestApi] = useVbenModal({
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:oss:download']"
|
v-access:code="['system:oss:download']"
|
||||||
@click="handleDownload(row)"
|
@click="handleDownload(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.download') }}
|
{{ $t('pages.common.download') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:oss:remove']"
|
v-access:code="['system:oss:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -161,24 +161,24 @@ function handleDownloadExcel() {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<GhostButton
|
<action-button
|
||||||
v-access:code="['system:post:edit']"
|
v-access:code="['system:post:edit']"
|
||||||
@click="handleEdit(row)"
|
@click="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</GhostButton>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<GhostButton
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:post:remove']"
|
v-access:code="['system:post:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</GhostButton>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -135,13 +135,13 @@ function handleMultipleAuthCancel() {
|
|||||||
placement="left"
|
placement="left"
|
||||||
@confirm="handleAuthCancel(row)"
|
@confirm="handleAuthCancel(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:role:remove']"
|
v-access:code="['system:role:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
取消授权
|
取消授权
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</template>
|
</template>
|
||||||
</BasicTable>
|
</BasicTable>
|
||||||
|
|||||||
@@ -201,36 +201,36 @@ async function handleChangeStatus(checked: boolean, row: Role) {
|
|||||||
"
|
"
|
||||||
>
|
>
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:role:edit']"
|
v-access:code="['system:role:edit']"
|
||||||
@click.stop="handleEdit(row)"
|
@click.stop="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:role:edit']"
|
v-access:code="['system:role:edit']"
|
||||||
@click.stop="handleAuthEdit(row)"
|
@click.stop="handleAuthEdit(row)"
|
||||||
>
|
>
|
||||||
权限
|
权限
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:role:edit']"
|
v-access:code="['system:role:edit']"
|
||||||
@click.stop="handleAssignRole(row)"
|
@click.stop="handleAssignRole(row)"
|
||||||
>
|
>
|
||||||
分配
|
分配
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:role:remove']"
|
v-access:code="['system:role:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -217,37 +217,37 @@ async function handleChangeStatus(checked: boolean, row: Tenant) {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space v-if="row.id !== 1">
|
<Space v-if="row.id !== 1">
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:tenant:edit']"
|
v-access:code="['system:tenant:edit']"
|
||||||
@click="handleEdit(row)"
|
@click="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
:title="`确认同步[${row.companyName}]的套餐吗?`"
|
:title="`确认同步[${row.companyName}]的套餐吗?`"
|
||||||
placement="left"
|
placement="left"
|
||||||
@confirm="handleSync(row)"
|
@confirm="handleSync(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
variant="link"
|
variant="link"
|
||||||
color="green"
|
color="green"
|
||||||
v-access:code="['system:tenant:edit']"
|
v-access:code="['system:tenant:edit']"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.sync') }}
|
{{ $t('pages.common.sync') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:tenant:remove']"
|
v-access:code="['system:tenant:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -169,24 +169,24 @@ async function handleChangeStatus(checked: boolean, row: TenantPackage) {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:tenantPackage:edit']"
|
v-access:code="['system:tenantPackage:edit']"
|
||||||
@click="handleEdit(row)"
|
@click="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:tenantPackage:remove']"
|
v-access:code="['system:tenantPackage:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -271,24 +271,24 @@ async function handleChangeStatus(checked: boolean, row: User) {
|
|||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<template v-if="row.userId !== SUPERADMIN_USER_ID">
|
<template v-if="row.userId !== SUPERADMIN_USER_ID">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:user:edit']"
|
v-access:code="['system:user:edit']"
|
||||||
@click.stop="handleEdit(row)"
|
@click.stop="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:user:remove']"
|
v-access:code="['system:user:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
<Dropdown
|
<Dropdown
|
||||||
|
|||||||
@@ -120,32 +120,32 @@ function collapseAll() {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['workflow:category:edit']"
|
v-access:code="['workflow:category:edit']"
|
||||||
@click.stop="handleEdit(row)"
|
@click.stop="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<ghost-button
|
<action-button
|
||||||
variant="link"
|
variant="link"
|
||||||
color="green"
|
color="green"
|
||||||
v-access:code="['workflow:category:edit']"
|
v-access:code="['workflow:category:edit']"
|
||||||
@click.stop="handleAdd(row)"
|
@click.stop="handleAdd(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.add') }}
|
{{ $t('pages.common.add') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['workflow:category:remove']"
|
v-access:code="['workflow:category:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -117,24 +117,24 @@ function handleMultiDelete() {
|
|||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<action-button
|
||||||
v-access:code="['system:config:edit']"
|
v-access:code="['system:config:edit']"
|
||||||
@click.stop="handleEdit(row)"
|
@click.stop="handleEdit(row)"
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.edit') }}
|
{{ $t('pages.common.edit') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
placement="left"
|
placement="left"
|
||||||
title="确认删除?"
|
title="确认删除?"
|
||||||
@confirm="handleDelete(row)"
|
@confirm="handleDelete(row)"
|
||||||
>
|
>
|
||||||
<ghost-button
|
<action-button
|
||||||
danger
|
danger
|
||||||
v-access:code="['system:config:remove']"
|
v-access:code="['system:config:remove']"
|
||||||
@click.stop=""
|
@click.stop=""
|
||||||
>
|
>
|
||||||
{{ $t('pages.common.delete') }}
|
{{ $t('pages.common.delete') }}
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -93,9 +93,9 @@ function handleSendSingle(userId: string) {
|
|||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<ghost-button @click="handleSendSingle(row.userId)">
|
<action-button @click="handleSendSingle(row.userId)">
|
||||||
发送消息
|
发送消息
|
||||||
</ghost-button>
|
</action-button>
|
||||||
</template>
|
</template>
|
||||||
</BasicTable>
|
</BasicTable>
|
||||||
<SendMsgModal />
|
<SendMsgModal />
|
||||||
|
|||||||
2
apps/web-antd/types/global-components.d.ts
vendored
2
apps/web-antd/types/global-components.d.ts
vendored
@@ -5,7 +5,7 @@ import { Button } from 'antdv-next/dist/button/Button';
|
|||||||
declare module 'vue' {
|
declare module 'vue' {
|
||||||
export interface GlobalComponents {
|
export interface GlobalComponents {
|
||||||
AButton: typeof Button;
|
AButton: typeof Button;
|
||||||
GhostButton: typeof Button;
|
ActionButton: typeof Button;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user