日志管理+任务管理
This commit is contained in:
@@ -6,6 +6,8 @@ import { $t } from '@/locales';
|
||||
import { enableStatusRecord } from '@/constants/business';
|
||||
import RoleOperateDrawer from './modules/role-operate-drawer.vue';
|
||||
import RoleSearch from './modules/role-search.vue';
|
||||
import {useI18n} from "vue-i18n";
|
||||
const { t } = useI18n();
|
||||
|
||||
const wrapperEl = shallowRef<HTMLElement | null>(null);
|
||||
const { height: wrapperElHeight } = useElementSize(wrapperEl);
|
||||
@@ -45,17 +47,17 @@ const { columns, columnChecks, data, loading, getData, mobilePagination, searchP
|
||||
dataIndex: 'status',
|
||||
title: $t('page.manage.role.roleStatus'),
|
||||
align: 'center',
|
||||
customRender: ({ record }) => {
|
||||
customRender: ({ record }:any) => {
|
||||
if (record.status === null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
const tagMap: Record<Api.Common.EnableStatus, string> = {
|
||||
const tagMap: any = {
|
||||
'0': 'success',
|
||||
'1': 'warning'
|
||||
};
|
||||
|
||||
const label = $t(enableStatusRecord[record.status]);
|
||||
const label = t(enableStatusRecord[record.status]);
|
||||
|
||||
return <Tag color={tagMap[record.status]}>{label}</Tag>;
|
||||
}
|
||||
@@ -76,7 +78,7 @@ const { columns, columnChecks, data, loading, getData, mobilePagination, searchP
|
||||
title: $t('common.operate'),
|
||||
align: 'center',
|
||||
width: 200,
|
||||
customRender: ({ record }) =>
|
||||
customRender: ({ record }:any) =>
|
||||
!record.admin && (
|
||||
<div class="flex justify-around gap-8px">
|
||||
{isShowBtn('system:role:edit') && (
|
||||
|
||||
@@ -14,7 +14,7 @@ interface Props {
|
||||
/** the type of operation */
|
||||
operateType: AntDesign.TableOperateType;
|
||||
/** the edit row data */
|
||||
rowData?: Api.SystemManage.Role | null;
|
||||
rowData?: any;
|
||||
}
|
||||
|
||||
const props = defineProps<Props>();
|
||||
|
||||
Reference in New Issue
Block a user