mirror of
https://gitee.com/anji-plus/report.git
synced 2026-04-13 10:38:34 +08:00
表格 状态添加tag
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
* @Author: qianlishi
|
||||
* @Date: 2025-01-03 01:01:14
|
||||
* @LastEditors: qianlishi
|
||||
* @LastEditTime: 2025-01-10 16:47:20
|
||||
* @LastEditTime: 2025-01-10 16:49:28
|
||||
*/
|
||||
import { computed, h } from 'vue';
|
||||
import { cloneDeep } from 'lodash-es';
|
||||
|
||||
@@ -3,13 +3,13 @@
|
||||
* @Author: qianlishi
|
||||
* @Date: 2025-01-03 01:01:14
|
||||
* @LastEditors: qianlishi
|
||||
* @LastEditTime: 2025-01-10 14:44:28
|
||||
* @LastEditTime: 2025-01-10 16:51:16
|
||||
*/
|
||||
import { computed, h } from 'vue';
|
||||
import { cloneDeep } from 'lodash-es';
|
||||
import { isObject } from '@/utils/is';
|
||||
import { NButton } from 'naive-ui'
|
||||
import { editFormShow } from '@/enums/common'
|
||||
import { NButton, NTag } from 'naive-ui'
|
||||
import { editFormShow, enable } from '@/enums/common'
|
||||
import { FormSchema } from '@/components/Base/Jsq-crud/src/components/Jsq-searchForm';
|
||||
|
||||
// 表单配置
|
||||
@@ -249,6 +249,21 @@ export const getTableColumns = ({ updateClick, removeSingle }) => {
|
||||
title: '启用状态',
|
||||
key: 'enableFlag',
|
||||
align: 'center',
|
||||
render(row) {
|
||||
return h(
|
||||
NTag,
|
||||
{
|
||||
style: {
|
||||
marginRight: '6px'
|
||||
},
|
||||
type: row.enableFlag ? 'success' : 'error',
|
||||
bordered: false
|
||||
},
|
||||
{
|
||||
default: () => enable[row.enableFlag]
|
||||
}
|
||||
)
|
||||
}
|
||||
},
|
||||
{
|
||||
title: '最后一次登陆时间',
|
||||
|
||||
Reference in New Issue
Block a user