| | |
| | | import type { VxeTableGridOptions } from '#/adapter/vxe-table'; |
| | | import type { SystemUserApi } from '#/api/system/user'; |
| | | |
| | | import { CommonStatusEnum, DICT_TYPE } from '../../../packages/constants/src'; |
| | | import { getDictOptions } from '../../../packages/effects/hooks/src'; |
| | | import { $t } from '../../../packages/locales/src'; |
| | | import { handleTree } from '../../../packages/utils/src'; |
| | | import { CommonStatusEnum, DICT_TYPE } from '@vben/constants'; |
| | | import { getDictOptions } from '@vben/hooks'; |
| | | import { $t } from '@vben/locales'; |
| | | import { handleTree } from '@vben/utils'; |
| | | |
| | | import { z } from '#/adapter/form'; |
| | | import { getDeptList } from '#/api/system/dept'; |
| | |
| | | }, |
| | | { |
| | | fieldName: 'username', |
| | | label: '用户名称', |
| | | label: '用户账号', |
| | | component: 'Input', |
| | | componentProps: { |
| | | placeholder: '请输入用户名称', |
| | | placeholder: '请输入用户账号(4-30 位数字、字母)', |
| | | }, |
| | | rules: 'required', |
| | | }, |
| | |
| | | fieldName: 'postIds', |
| | | label: '岗位', |
| | | component: 'ApiSelect', |
| | | rules: 'required', |
| | | componentProps: { |
| | | api: getSimplePostList, |
| | | labelField: 'name', |
| | |
| | | }, |
| | | { |
| | | fieldName: 'username', |
| | | label: '用户名称', |
| | | label: '用户账号', |
| | | component: 'Input', |
| | | componentProps: { |
| | | disabled: true, |
| | |
| | | label: '用户数据', |
| | | component: 'Upload', |
| | | rules: 'required', |
| | | help: '仅允许导入 xls、xlsx 格式文件', |
| | | help: '仅允许导入 xls、xlsx 格式文件;请先下载导入模板,按模板列(用户账号、用户昵称、部门、岗位等)填写', |
| | | }, |
| | | { |
| | | fieldName: 'updateSupport', |
| | |
| | | unCheckedChildren: '否', |
| | | }, |
| | | rules: z.boolean().default(false), |
| | | help: '是否更新已经存在的用户数据', |
| | | help: '勾选后,用户账号已存在的行会更新该用户信息(不会修改其密码)', |
| | | }, |
| | | ]; |
| | | } |
| | |
| | | return [ |
| | | { |
| | | fieldName: 'username', |
| | | label: '用户名称', |
| | | label: '用户账号', |
| | | component: 'Input', |
| | | componentProps: { |
| | | placeholder: '请输入用户名称', |
| | | placeholder: '请输入用户账号', |
| | | allowClear: true, |
| | | }, |
| | | }, |
| | |
| | | }, |
| | | { |
| | | field: 'username', |
| | | title: '用户名称', |
| | | title: '用户账号', |
| | | minWidth: 120, |
| | | }, |
| | | { |
| | |
| | | field: 'createTime', |
| | | title: '创建时间', |
| | | minWidth: 180, |
| | | formatter: 'formatDateTime', |
| | | formatter: 'formatDate', |
| | | }, |
| | | { |
| | | title: '操作', |