feat: dict css class
parent
d2e4a26c84
commit
c264945d8f
|
@ -317,10 +317,12 @@ export function useDataGridColumns(): VxeTableGridOptions['columns'] {
|
||||||
{
|
{
|
||||||
field: 'colorType',
|
field: 'colorType',
|
||||||
title: '颜色类型',
|
title: '颜色类型',
|
||||||
|
slots: { default: 'colorType' },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: 'cssClass',
|
field: 'cssClass',
|
||||||
title: 'CSS Class',
|
title: 'CSS Class',
|
||||||
|
slots: { default: 'cssClass' },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '创建时间',
|
title: '创建时间',
|
||||||
|
|
|
@ -7,7 +7,7 @@ import { ref, watch } from 'vue';
|
||||||
import { useVbenModal } from '@vben/common-ui';
|
import { useVbenModal } from '@vben/common-ui';
|
||||||
import { downloadFileFromBlobPart, isEmpty } from '@vben/utils';
|
import { downloadFileFromBlobPart, isEmpty } from '@vben/utils';
|
||||||
|
|
||||||
import { message } from 'ant-design-vue';
|
import { message, Tag } from 'ant-design-vue';
|
||||||
|
|
||||||
import { ACTION_ICON, TableAction, useVbenVxeGrid } from '#/adapter/vxe-table';
|
import { ACTION_ICON, TableAction, useVbenVxeGrid } from '#/adapter/vxe-table';
|
||||||
import {
|
import {
|
||||||
|
@ -177,6 +177,12 @@ watch(
|
||||||
]"
|
]"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
<template #colorType="{ row }">
|
||||||
|
<Tag :color="row.colorType">{{ row.colorType }}</Tag>
|
||||||
|
</template>
|
||||||
|
<template #cssClass="{ row }">
|
||||||
|
<Tag :color="row.cssClass">{{ row.cssClass }}</Tag>
|
||||||
|
</template>
|
||||||
<template #actions="{ row }">
|
<template #actions="{ row }">
|
||||||
<TableAction
|
<TableAction
|
||||||
:actions="[
|
:actions="[
|
||||||
|
|
Loading…
Reference in New Issue