diff --git a/jeecgboot-vue3/src/views/bl/xxhbjwxtxsmd/Xxhbjwxtxsmd.data.ts b/jeecgboot-vue3/src/views/bl/xxhbjwxtxsmd/Xxhbjwxtxsmd.data.ts index 187d387..b657bfb 100644 --- a/jeecgboot-vue3/src/views/bl/xxhbjwxtxsmd/Xxhbjwxtxsmd.data.ts +++ b/jeecgboot-vue3/src/views/bl/xxhbjwxtxsmd/Xxhbjwxtxsmd.data.ts @@ -53,53 +53,178 @@ export const columns: BasicColumn[] = [ { title: '平时成绩1', align: "center", - dataIndex: 'cj1' + 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' + 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' + 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' + 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' - }, - { - 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' + 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", diff --git a/jeecgboot-vue3/src/views/bl/xxhbjwxtxsmd/XxhbjwxtxsmdList.vue b/jeecgboot-vue3/src/views/bl/xxhbjwxtxsmd/XxhbjwxtxsmdList.vue index 73f1819..69c2c95 100644 --- a/jeecgboot-vue3/src/views/bl/xxhbjwxtxsmd/XxhbjwxtxsmdList.vue +++ b/jeecgboot-vue3/src/views/bl/xxhbjwxtxsmd/XxhbjwxtxsmdList.vue @@ -18,31 +18,30 @@
概要信息
- + 开课单位{{jxrwInfo?.value.kkyxmc}} - + 课程类别{{jxrwInfo?.value.kclb}} - + 课程名称{{jxrwInfo?.value.kcmc}} - + 课程负责人{{jxrwInfo?.value.teaxm}} - - - 成绩方式 - - - 修读方式 - - + 考试性质{{jxrwInfo?.value.khfsmc}} - - 任课教师职称{{jxrwInfo?.value.teaxm.substring(jxrwInfo?.value.teaxm.indexOf("[")+1,jxrwInfo?.value.teaxm.indexOf("]"))}} - + + + + + + + + +
@@ -81,7 +80,7 @@ const registerModal = ref(); const userStore = useUserStore(); const spinning = ref(false); - + const jxrwInfo = reactive({}); //注册table数据 const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({ @@ -122,17 +121,17 @@ }); function textDown(){ - var a = document.createElement("a"); //创建一个标签 - a.href = "/download/a.docx"; - //给a标签的href属性值加上地址,注意,这里是绝对路径,不用加 点. + var a = document.createElement("a"); //创建一个标签 + a.href = "/download/a.docx"; + //给a标签的href属性值加上地址,注意,这里是绝对路径,不用加 点. a.download ="a.docx"; //设置下载文件文件名,这里加上.xlsx指定文件类型,pdf文件就指定.fpd即可 - a.style.display = "none"; // 障眼法藏起来a标签 + a.style.display = "none"; // 障眼法藏起来a标签 document.body.appendChild(a); - // 将a标签追加到文档对象中 + // 将a标签追加到文档对象中 a.click(); //模拟点击了a标签,会触发a标签的href的读取,浏览器就会自动下载了 a.remove(); - // 一次性的,用完就删除a标签 + // 一次性的,用完就删除a标签 } /** @@ -142,15 +141,15 @@ function textDown(){ registerModal.value.disableSubmit = false; registerModal.value.edit(record); } - - + + /** * 成功回调 */ function handleSuccess() { (selectedRowKeys.value = []) && reload(); } - + /** * 操作栏 */ @@ -175,7 +174,7 @@ function textDown(){ },]; } } - + /** * 查询 @@ -183,7 +182,7 @@ function textDown(){ function searchQuery() { reload(); } - + /** * 重置 */ @@ -193,7 +192,7 @@ function textDown(){ //刷新数据 reload(); } - + function init(record) { console.log('🧞', record); queryParam.kcrwdm = record.kcrwdm;