548 lines
11 KiB
TypeScript
548 lines
11 KiB
TypeScript
import {BasicColumn} from '/@/components/Table';
|
|
import {FormSchema} from '/@/components/Table';
|
|
import { rules} from '/@/utils/helper/validator';
|
|
import { render } from '/@/utils/common/renderUtils';
|
|
import { getWeekMonthQuarterYear } from '/@/utils';
|
|
//列表数据
|
|
export const columns: BasicColumn[] = [
|
|
{
|
|
title: '课程任务代码',
|
|
align: "center",
|
|
dataIndex: 'kcrwdm',
|
|
width: 280,
|
|
ellipsis: false
|
|
},
|
|
{
|
|
title: '年级',
|
|
align: "center",
|
|
dataIndex: 'nj'
|
|
},
|
|
{
|
|
title: '学生状态',
|
|
align: "center",
|
|
dataIndex: 'xsztmc',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '专业',
|
|
align: "center",
|
|
dataIndex: 'zymc',
|
|
width: 200,
|
|
},
|
|
{
|
|
title: '学号',
|
|
align: "center",
|
|
dataIndex: 'xsbh',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '学生姓名',
|
|
align: "center",
|
|
dataIndex: 'xsxm',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '课程名称',
|
|
align: "center",
|
|
dataIndex: 'kcmc',
|
|
width: 200,
|
|
},
|
|
{
|
|
title: '课程类别',
|
|
align: "center",
|
|
dataIndex: 'kclb',
|
|
width: 200,
|
|
},
|
|
{
|
|
title: '任课教师',
|
|
align: "center",
|
|
dataIndex: 'teaxm',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '平时成绩1',
|
|
align: "center",
|
|
dataIndex: 'cj1',
|
|
children: [
|
|
{
|
|
title: '成绩类型',
|
|
dataIndex: 'cj1mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(0,text.indexOf("[")) : "");
|
|
return text;
|
|
},
|
|
},
|
|
{
|
|
title: '分数',
|
|
dataIndex: 'cj1',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '占比',
|
|
dataIndex: 'cj1mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(text.indexOf("["),text.indexOf("]")) : "");
|
|
return text;
|
|
}
|
|
},
|
|
],
|
|
},
|
|
{
|
|
title: '平时成绩2',
|
|
align: "center",
|
|
dataIndex: 'cj2',
|
|
children: [
|
|
{
|
|
title: '成绩类型',
|
|
dataIndex: 'cj2mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(0,text.indexOf("[")) : "");
|
|
return text;
|
|
},
|
|
},
|
|
{
|
|
title: '分数',
|
|
dataIndex: 'cj2',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '占比',
|
|
dataIndex: 'cj2mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(text.indexOf("["),text.indexOf("]")) : "");
|
|
return text;
|
|
}
|
|
},
|
|
],
|
|
},
|
|
{
|
|
title: '平时成绩3',
|
|
align: "center",
|
|
dataIndex: 'cj3',
|
|
children: [
|
|
{
|
|
title: '成绩类型',
|
|
dataIndex: 'cj3mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(0,text.indexOf("[")) : "");
|
|
return text;
|
|
},
|
|
},
|
|
{
|
|
title: '分数',
|
|
dataIndex: 'cj3',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '占比',
|
|
dataIndex: 'cj3mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(text.indexOf("["),text.indexOf("]")) : "");
|
|
return text;
|
|
}
|
|
},
|
|
],
|
|
},
|
|
{
|
|
title: '期中成绩',
|
|
align: "center",
|
|
dataIndex: 'cj4',
|
|
children: [
|
|
{
|
|
title: '成绩类型',
|
|
dataIndex: 'cj5mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(0,text.indexOf("[")) : "");
|
|
return text;
|
|
},
|
|
},
|
|
{
|
|
title: '分数',
|
|
dataIndex: 'cj4',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '占比',
|
|
dataIndex: 'cj4mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(text.indexOf("["),text.indexOf("]")) : "");
|
|
return text;
|
|
}
|
|
},
|
|
],
|
|
},
|
|
{
|
|
title: '期末成绩',
|
|
align: "center",
|
|
dataIndex: 'cj5',
|
|
children: [
|
|
{
|
|
title: '成绩类型',
|
|
dataIndex: 'cj5mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(0,text.indexOf("[")) : "");
|
|
return text;
|
|
},
|
|
},
|
|
{
|
|
title: '分数',
|
|
dataIndex: 'cj5',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '占比',
|
|
dataIndex: 'cj4mc',
|
|
width: 100,
|
|
customRender:({text}) =>{
|
|
text = !text ? "" : (text.length > 0 ? text.substr(text.indexOf("["),text.indexOf("]")) : "");
|
|
return text;
|
|
}
|
|
},
|
|
],
|
|
},
|
|
// {
|
|
// title: '平时成绩1',
|
|
// align: "center",
|
|
// dataIndex: 'cj1mc'
|
|
// },
|
|
// {
|
|
// title: '平时成绩2',
|
|
// align: "center",
|
|
// dataIndex: 'cj2mc'
|
|
// },
|
|
// {
|
|
// title: '平时成绩3',
|
|
// align: "center",
|
|
// dataIndex: 'cj3mc'
|
|
// },
|
|
// {
|
|
// title: '期中成绩',
|
|
// align: "center",
|
|
// dataIndex: 'cj4mc'
|
|
// },
|
|
// {
|
|
// title: '期末成绩',
|
|
// align: "center",
|
|
// dataIndex: 'cj5mc'
|
|
// },
|
|
{
|
|
title: '总成绩',
|
|
align: "center",
|
|
dataIndex: 'zcj',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '成绩方式',
|
|
align: "center",
|
|
dataIndex: 'cjfsmc',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '选读',
|
|
align: "center",
|
|
dataIndex: 'xdfsmc',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '考试性质',
|
|
align: "center",
|
|
dataIndex: 'ksxzmc',
|
|
width: 100,
|
|
},
|
|
];
|
|
|
|
|
|
//列表数据
|
|
export const columns3: BasicColumn[] = [
|
|
{
|
|
title: '学号',
|
|
align: "center",
|
|
dataIndex: 'xsbh',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '学生姓名',
|
|
align: "center",
|
|
dataIndex: 'xsxm',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '专业',
|
|
align: "center",
|
|
dataIndex: 'zymc',
|
|
width: 200,
|
|
},
|
|
{
|
|
title: '平时成绩1',
|
|
align: "center",
|
|
dataIndex: 'cj1',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '平时成绩2',
|
|
align: "center",
|
|
dataIndex: 'cj2',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '平时成绩3',
|
|
align: "center",
|
|
dataIndex: 'cj3',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '期中成绩',
|
|
align: "center",
|
|
dataIndex: 'cj4',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '期末成绩',
|
|
align: "center",
|
|
dataIndex: 'cj5',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '总成绩',
|
|
align: "center",
|
|
dataIndex: 'zcj',
|
|
width: 100,
|
|
},
|
|
];
|
|
|
|
//列表数据
|
|
export const columns2: BasicColumn[] = [
|
|
{
|
|
title: '课程任务代码',
|
|
align: "center",
|
|
dataIndex: 'kcrwdm',
|
|
width: 200,
|
|
},
|
|
{
|
|
title: '年级',
|
|
align: "center",
|
|
dataIndex: 'nj'
|
|
},
|
|
{
|
|
title: '学生状态',
|
|
align: "center",
|
|
dataIndex: 'xsztmc'
|
|
},
|
|
{
|
|
title: '专业',
|
|
align: "center",
|
|
dataIndex: 'zymc',
|
|
width: 200,
|
|
},
|
|
{
|
|
title: '学号',
|
|
align: "center",
|
|
dataIndex: 'xsbh'
|
|
},
|
|
{
|
|
title: '学生姓名',
|
|
align: "center",
|
|
dataIndex: 'xsxm'
|
|
},
|
|
{
|
|
title: '课程名称',
|
|
align: "center",
|
|
dataIndex: 'kcmc',
|
|
width: 200,
|
|
},
|
|
{
|
|
title: '课程类别',
|
|
align: "center",
|
|
dataIndex: 'kclb',
|
|
width: 200,
|
|
},
|
|
{
|
|
title: '任课教师',
|
|
align: "center",
|
|
dataIndex: 'teaxm'
|
|
},
|
|
{
|
|
title: '平时成绩1',
|
|
align: "center",
|
|
dataIndex: 'cj1',
|
|
},
|
|
{
|
|
title: '平时成绩2',
|
|
align: "center",
|
|
dataIndex: 'cj2',
|
|
},
|
|
{
|
|
title: '平时成绩3',
|
|
align: "center",
|
|
dataIndex: 'cj3',
|
|
},
|
|
{
|
|
title: '期中成绩',
|
|
align: "center",
|
|
dataIndex: 'cj4',
|
|
},
|
|
{
|
|
title: '期末成绩',
|
|
align: "center",
|
|
dataIndex: 'cj5',
|
|
},
|
|
{
|
|
title: '平时成绩1',
|
|
align: "center",
|
|
dataIndex: 'cj1mc'
|
|
},
|
|
{
|
|
title: '平时成绩2',
|
|
align: "center",
|
|
dataIndex: 'cj2mc'
|
|
},
|
|
{
|
|
title: '平时成绩3',
|
|
align: "center",
|
|
dataIndex: 'cj3mc'
|
|
},
|
|
{
|
|
title: '期中成绩',
|
|
align: "center",
|
|
dataIndex: 'cj4mc'
|
|
},
|
|
{
|
|
title: '期末成绩',
|
|
align: "center",
|
|
dataIndex: 'cj5mc'
|
|
},
|
|
{
|
|
title: '总成绩',
|
|
align: "center",
|
|
dataIndex: 'zcj'
|
|
},
|
|
{
|
|
title: '成绩方式',
|
|
align: "center",
|
|
dataIndex: 'cjfsmc'
|
|
},
|
|
{
|
|
title: '选读',
|
|
align: "center",
|
|
dataIndex: 'xdfsmc'
|
|
},
|
|
{
|
|
title: '考试性质',
|
|
align: "center",
|
|
dataIndex: 'ksxzmc'
|
|
},
|
|
];
|
|
|
|
|
|
|
|
//列表数据
|
|
export const columns4: BasicColumn[] = [
|
|
{
|
|
title: '考核方式',
|
|
align: "center",
|
|
dataIndex: 'khfs',
|
|
// customRender:({text}) =>{
|
|
// text = !text ? "" : (text.length > 0 ? text.substr(0,text.indexOf("[")) : "");
|
|
// return text;
|
|
// },
|
|
},
|
|
{
|
|
title: '占比',
|
|
align: "center",
|
|
dataIndex: 'zb',
|
|
// customRender:({text}) =>{
|
|
// if(text.indexOf("[") > -1){
|
|
// try{
|
|
// var a = text.indexOf("[")+1;
|
|
// var b = text.indexOf("]");
|
|
// var c = parseInt(b)-parseInt(a);
|
|
// text = !text ? "" : (text.length > 0 ? text.substr(a,c) : "");
|
|
// }catch(e){
|
|
|
|
// }
|
|
// }
|
|
// return text;
|
|
// }
|
|
},
|
|
{
|
|
title: '学生原始材料',
|
|
align: "center",
|
|
dataIndex: 'xsyscl',
|
|
children: [
|
|
{
|
|
title: '存档类型',
|
|
dataIndex: 'cdlx',
|
|
width: 140,
|
|
// slots: { customRender: 'cdlxaction' },
|
|
},
|
|
{
|
|
title: '详情',
|
|
dataIndex: 'xq',
|
|
width: 100,
|
|
slots: { customRender: 'xqaction' },
|
|
},
|
|
],
|
|
},
|
|
];
|
|
|
|
|
|
//列表数据
|
|
export const columns5: BasicColumn[] = [
|
|
{
|
|
title: '学生学号',
|
|
align: "center",
|
|
dataIndex: 'xsbh',
|
|
},
|
|
{
|
|
title: '学生姓名',
|
|
align: "center",
|
|
dataIndex: 'xsxm',
|
|
},
|
|
{
|
|
title: '专业',
|
|
align: "center",
|
|
dataIndex: 'zymc',
|
|
},
|
|
{
|
|
title: '得分',
|
|
align: "center",
|
|
dataIndex: 'fsshow',
|
|
},
|
|
];
|
|
|
|
// 高级查询数据
|
|
export const superQuerySchema = {
|
|
kcrwdm: {title: 'kcrwdm',order: 0,view: 'text', type: 'string',},
|
|
nj: {title: 'nj',order: 1,view: 'text', type: 'string',},
|
|
xsztmc: {title: 'xsztmc',order: 2,view: 'text', type: 'string',},
|
|
zymc: {title: 'zymc',order: 3,view: 'text', type: 'string',},
|
|
xsbh: {title: 'xsbh',order: 4,view: 'text', type: 'string',},
|
|
xsxm: {title: 'xsxm',order: 5,view: 'text', type: 'string',},
|
|
kcmc: {title: 'kcmc',order: 6,view: 'text', type: 'string',},
|
|
kclb: {title: 'kclb',order: 7,view: 'text', type: 'string',},
|
|
teaxm: {title: 'teaxm',order: 8,view: 'text', type: 'string',},
|
|
cj1: {title: 'cj1',order: 9,view: 'text', type: 'string',},
|
|
cj2: {title: 'cj2',order: 10,view: 'text', type: 'string',},
|
|
cj3: {title: 'cj3',order: 11,view: 'text', type: 'string',},
|
|
cj4: {title: 'cj4',order: 12,view: 'text', type: 'string',},
|
|
cj5: {title: 'cj5',order: 13,view: 'text', type: 'string',},
|
|
cj1mc: {title: 'cj1mc',order: 14,view: 'text', type: 'string',},
|
|
cj2mc: {title: 'cj2mc',order: 15,view: 'text', type: 'string',},
|
|
cj3mc: {title: 'cj3mc',order: 16,view: 'text', type: 'string',},
|
|
cj4mc: {title: 'cj4mc',order: 17,view: 'text', type: 'string',},
|
|
cj5mc: {title: 'cj5mc',order: 18,view: 'text', type: 'string',},
|
|
zcj: {title: 'zcj',order: 19,view: 'text', type: 'string',},
|
|
cjfsmc: {title: 'cjfsmc',order: 20,view: 'text', type: 'string',},
|
|
xdfsmc: {title: 'xdfsmc',order: 21,view: 'text', type: 'string',},
|
|
ksxzmc: {title: 'ksxzmc',order: 22,view: 'text', type: 'string',},
|
|
};
|