239 lines
4.8 KiB
TypeScript
239 lines
4.8 KiB
TypeScript
|
import {BasicColumn} from '/@/components/Table';
|
|||
|
import {FormSchema} from '/@/components/Table';
|
|||
|
import { rules} from '/@/utils/helper/validator';
|
|||
|
import { render } from '/@/utils/common/renderUtils';
|
|||
|
//列表数据
|
|||
|
export const columns: BasicColumn[] = [
|
|||
|
{
|
|||
|
title: '学院',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'xy'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '候选人',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'hxr'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '职称',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'zc'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '日期',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'rq'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '开始时间',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'kssj'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '结束时间',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'jssj'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '课程名称',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'kcmc'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '课堂主题',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'ktzt'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '课程链接',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'kclj'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '图片名称',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'tpmc'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '教师介绍链接',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'jslj'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '当前状态',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'dqzt'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '当前状态排序 1 正在上课 2公开课预告 3 已下课',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'dqztpx_dictText'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '是否显示 1 显示 0 不显示',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'sfxs_dictText'
|
|||
|
},
|
|||
|
{
|
|||
|
title: '类别',
|
|||
|
align: "center",
|
|||
|
dataIndex: 'hxrlb'
|
|||
|
},
|
|||
|
];
|
|||
|
|
|||
|
//查询数据
|
|||
|
export const searchFormSchema: FormSchema[] = [
|
|||
|
];
|
|||
|
|
|||
|
//表单数据
|
|||
|
export const formSchema: FormSchema[] = [
|
|||
|
{
|
|||
|
label: '学院',
|
|||
|
field: 'xy',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入学院!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '候选人',
|
|||
|
field: 'hxr',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入候选人!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '职称',
|
|||
|
field: 'zc',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入职称!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '日期',
|
|||
|
field: 'rq',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入日期!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '开始时间',
|
|||
|
field: 'kssj',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入开始时间!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '结束时间',
|
|||
|
field: 'jssj',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入结束时间!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '课程名称',
|
|||
|
field: 'kcmc',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入课程名称!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '课堂主题',
|
|||
|
field: 'ktzt',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入课堂主题!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '课程链接',
|
|||
|
field: 'kclj',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入课程链接!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '图片名称',
|
|||
|
field: 'tpmc',
|
|||
|
component: 'Input',
|
|||
|
},
|
|||
|
{
|
|||
|
label: '教师介绍链接',
|
|||
|
field: 'jslj',
|
|||
|
component: 'Input',
|
|||
|
},
|
|||
|
{
|
|||
|
label: '当前状态',
|
|||
|
field: 'dqzt',
|
|||
|
component: 'Input',
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入当前状态!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '当前状态排序 1 正在上课 2公开课预告 3 已下课',
|
|||
|
field: 'dqztpx',
|
|||
|
component: 'JDictSelectTag',
|
|||
|
componentProps:{
|
|||
|
dictCode: "dqztpx"
|
|||
|
},
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入当前状态排序 1 正在上课 2公开课预告 3 已下课!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '是否显示 1 显示 0 不显示',
|
|||
|
field: 'sfxs',
|
|||
|
component: 'JDictSelectTag',
|
|||
|
componentProps:{
|
|||
|
dictCode: "sfxs"
|
|||
|
},
|
|||
|
dynamicRules: ({model,schema}) => {
|
|||
|
return [
|
|||
|
{ required: true, message: '请输入是否显示 1 显示 0 不显示!'},
|
|||
|
];
|
|||
|
},
|
|||
|
},
|
|||
|
{
|
|||
|
label: '类别',
|
|||
|
field: 'hxrlb',
|
|||
|
component: 'Input',
|
|||
|
},
|
|||
|
// TODO 主键隐藏字段,目前写死为ID
|
|||
|
{
|
|||
|
label: '',
|
|||
|
field: 'id',
|
|||
|
component: 'Input',
|
|||
|
show: false,
|
|||
|
},
|
|||
|
];
|