123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228 |
- import { getDepListData } from '/@/api/common/api';
- import { BasicColumn } from '/@/components/Table';
- import { FormSchema } from '/@/components/Table';
- export const columns: BasicColumn[] = [
- {
- title: '登录名称',
- dataIndex: 'username',
- width: 100,
- align: 'center',
- },
- {
- title: '用户名称',
- dataIndex: 'realname',
- width: 100,
- },
- {
- title: '部门',
- dataIndex: 'departName',
- width: 100,
- },
- {
- title: '用户状态',
- dataIndex: 'status',
- width: 100,
- },
- {
- title: '创建时间',
- dataIndex: 'createTime',
- width: 100,
- },
- ];
- export const searchFormSchema: FormSchema[] = [
- {
- field: 'username',
- label: '登录名称',
- component: 'Input',
- colProps: { sm: 24 },
- },
- {
- field: 'phone',
- label: '手机号码',
- component: 'Input',
- colProps: { sm: 24 },
- },
- {
- field: 'status',
- label: '用户状态',
- component: 'Select',
- colProps: { sm: 24 },
- componentProps: {
- options: [
- {
- label: '所有',
- value: '',
- },
- {
- label: '正常',
- value: '1',
- },
- {
- label: '冻结',
- value: '2',
- },
- ],
- },
- },
- {
- field: 'datetime',
- label: '创建时间',
- component: 'RangePicker',
- colProps: { sm: 24 },
- componentProps: {
- format: 'YYYY-MM-DD',
- valueType: 'Date',
- },
- },
- ];
- export const formSchema: FormSchema[] = [
- {
- field: 'id',
- label: 'ID',
- component: 'Input',
- show: false,
- },
- {
- field: 'id',
- label: 'ID',
- component: 'Input',
- colSlot: 'title1',
- },
- {
- field: 'realname',
- label: '用户名称',
- component: 'Input',
- required: true,
- colProps: {
- lg: 12,
- sm: 24,
- },
- },
- {
- field: 'selecteddeparts',
- label: '归属部门',
- component: 'ApiSelect',
- componentProps: {
- api: getDepListData,
- resultField: 'result',
- labelField: 'departName',
- valueField: 'id',
- mode: 'tags',
- },
- required: true,
- colProps: {
- lg: 12,
- sm: 24,
- },
- },
- {
- field: 'username',
- label: '登录账号',
- component: 'Input',
- required: true,
- colProps: {
- lg: 12,
- sm: 24,
- },
- },
- {
- field: 'password',
- label: '登录密码',
- component: 'Input',
- required: true,
- colProps: {
- lg: 12,
- sm: 24,
- },
- },
- {
- field: 'status',
- label: '用户状态',
- component: 'Switch',
- required: true,
- componentProps: {
- checkedValue: 1,
- unCheckedValue: 2,
- },
- defaultValue: 1,
- },
- {
- field: 'selectedroles',
- label: '角色',
- component: 'JSelectRole',
- required: true,
- slot: 'jSelectPosition',
- },
- {
- field: 'id',
- label: 'ID',
- component: 'Input',
- colSlot: 'title2',
- },
- {
- field: 'trainingPrograms',
- label: '培训项目',
- component: 'ApiSelect',
- colSlot: 'trainingPrograms',
- required: true,
- },
- {
- field: 'backgroundImg',
- label: '背景图',
- component: 'JImageUpload',
- componentProps: {
- tipText: '单张图片,支持格式:.jpg .png .svg .gif ,单个文件不能超过5MB',
- },
- colSlot: 'backgroundImg',
- required: true,
- },
- {
- field: 'certificateInnocence',
- label: '无犯罪记录',
- component: 'JImageUpload',
- componentProps: {
- tipText: '单张图片,支持格式:.jpg .png .svg .gif ,单个文件不能超过5MB',
- },
- colSlot: 'certificateInnocence',
- colProps: { xl: 12, sm: 24 },
- required: true,
- },
- {
- field: 'healthy',
- label: '健康证',
- component: 'JImageUpload',
- colProps: { xl: 12, sm: 24 },
- colSlot: 'healthy',
- componentProps: {
- tipText: '单张图片,支持格式:.jpg .png .svg .gif ,单个文件不能超过5MB',
- },
- required: true,
- },
- {
- field: 'teachingPhilosophy',
- label: '教学理念',
- component: 'InputTextArea',
- colSlot: 'teachingPhilosophy',
- },
- {
- field: 'excelMsg',
- label: '擅长描述',
- component: 'InputTextArea',
- colSlot: 'excelMsg',
- },
- {
- field: 'honor',
- label: '荣誉认证',
- component: 'JImageUpload',
- componentProps: {
- tipText: '多张图片,支持格式:.jpg .png .svg .gif ,单个文件不能超过5MB',
- },
- colSlot: 'honor',
- },
- ];
|