mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-11 20:06:47 +08:00
feat:合并
This commit is contained in:
6
src/api/indexTaskManage.js
Normal file
6
src/api/indexTaskManage.js
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
import http from "./config";
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// 获取考试管理的信息
|
||||||
|
export const ExamManagementMessage = (obj) => http.post('/admin/exam/manage/queryExamManagementMessage',obj)
|
||||||
@@ -1,5 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-drawer
|
<a-drawer
|
||||||
|
v-if="TMvisible"
|
||||||
:visible="TMvisible"
|
:visible="TMvisible"
|
||||||
class="drawerStyle ProjectExamManage"
|
class="drawerStyle ProjectExamManage"
|
||||||
placement="right"
|
placement="right"
|
||||||
@@ -16,7 +17,7 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div class="main">
|
<div class="main">
|
||||||
<div class="endtime">起止时间:2022-07-21 14:00 ~ 2022-7-30 14:00</div>
|
<div class="endtime">起止时间:{{datasource.startTime}} ~ {{datasource.endTime}}</div>
|
||||||
<div class="search">
|
<div class="search">
|
||||||
<div class="namecon" style="margin-right: 30px">
|
<div class="namecon" style="margin-right: 30px">
|
||||||
<div class="name">姓名:</div>
|
<div class="name">姓名:</div>
|
||||||
@@ -44,12 +45,12 @@
|
|||||||
<div
|
<div
|
||||||
class="btn btn1"
|
class="btn btn1"
|
||||||
style="margin-right: 20px"
|
style="margin-right: 20px"
|
||||||
@click="searchTaskList"
|
@click="searchTableData"
|
||||||
>
|
>
|
||||||
<div class="img1"></div>
|
<div class="img1"></div>
|
||||||
<div class="wz">搜索</div>
|
<div class="wz">搜索</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="btn btn2" @click="resetTaskList">
|
<div class="btn btn2" @click="reseatTableData">
|
||||||
<div class="img2"></div>
|
<div class="img2"></div>
|
||||||
<div class="wz">重置</div>
|
<div class="wz">重置</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -64,9 +65,9 @@
|
|||||||
<div class="img2"></div>
|
<div class="img2"></div>
|
||||||
<div class="wz">导出数据</div>
|
<div class="wz">导出数据</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="btn btn2" @click="showEScoreModal">
|
<!-- <div class="btn btn2" @click="showEScoreModal">
|
||||||
<div class="wz">导入成绩</div>
|
<div class="wz">导入成绩</div>
|
||||||
</div>
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="line">
|
<!-- <div class="line">
|
||||||
<div class="inline">
|
<div class="inline">
|
||||||
@@ -86,7 +87,7 @@
|
|||||||
style="border: 1px solid #f2f6fe"
|
style="border: 1px solid #f2f6fe"
|
||||||
:columns="tablecolumns"
|
:columns="tablecolumns"
|
||||||
:data-source="tabledata"
|
:data-source="tabledata"
|
||||||
:loading="tableDataTotal === -1 ? true : false"
|
:loading="loadingData"
|
||||||
:scroll="{ x: 900 }"
|
:scroll="{ x: 900 }"
|
||||||
:pagination="false"
|
:pagination="false"
|
||||||
:row-selection="{
|
:row-selection="{
|
||||||
@@ -105,13 +106,14 @@
|
|||||||
:total="tableDataTotal"
|
:total="tableDataTotal"
|
||||||
class="pagination"
|
class="pagination"
|
||||||
v-if="tableDataTotal > 10"
|
v-if="tableDataTotal > 10"
|
||||||
|
@change="changePaginationStu"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnn">
|
<div class="btnn">
|
||||||
<button class="btn1">取消</button>
|
<button class="btn1" @click="closeDrawer">取消</button>
|
||||||
<button class="btn2">确定</button>
|
<button class="btn2" @click="closeDrawer">确定</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- 导出成绩抽屉 -->
|
<!-- 导出成绩抽屉 -->
|
||||||
@@ -123,6 +125,8 @@
|
|||||||
import { toRefs, reactive } from "vue";
|
import { toRefs, reactive } from "vue";
|
||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import EScore from "../ExportScore.vue";
|
import EScore from "../ExportScore.vue";
|
||||||
|
import * as api from '../../../api/indexTaskManage';
|
||||||
|
|
||||||
// import * as api from "../../../api/index";
|
// import * as api from "../../../api/index";
|
||||||
export default {
|
export default {
|
||||||
name: "ProjectExamManage",
|
name: "ProjectExamManage",
|
||||||
@@ -142,23 +146,28 @@ export default {
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
datasource: {
|
||||||
|
type: Object,
|
||||||
|
default: function () {
|
||||||
|
return {};
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
name: "",
|
name: "",
|
||||||
|
|
||||||
open: false,
|
open: false,
|
||||||
projectName: null,
|
projectName: "",
|
||||||
projectNameList: [
|
projectNameList: [
|
||||||
{
|
{
|
||||||
id: 1,
|
id: 1,
|
||||||
value: "-1",
|
value: "0",
|
||||||
label: "未开始",
|
label: "未开始",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 2,
|
id: 2,
|
||||||
value: "0",
|
value: "10",
|
||||||
label: "未通过",
|
label: "未通过",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -172,56 +181,45 @@ export default {
|
|||||||
pageNo: 1,
|
pageNo: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
currentPage: 1,
|
currentPage: 1,
|
||||||
tableDataTotal: 1,
|
tableDataTotal: 0,
|
||||||
tabledata: [
|
tabledata: [],
|
||||||
{
|
|
||||||
workNum: "123",
|
|
||||||
userName: "li",
|
|
||||||
deptName: "开发",
|
|
||||||
jobName: "前端开发",
|
|
||||||
score: 89,
|
|
||||||
examNum: 1,
|
|
||||||
comptime: "2022-07-22 14:00:30",
|
|
||||||
status: "已完成",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
tablecolumns: [
|
tablecolumns: [
|
||||||
{
|
{
|
||||||
title: "工号",
|
title: "工号",
|
||||||
dataIndex: "workNum",
|
dataIndex: "studentCode",
|
||||||
key: "workNum",
|
key: "studentCode",
|
||||||
width: 50,
|
width: 50,
|
||||||
align: "left",
|
align: "left",
|
||||||
className: "h head",
|
className: "h head"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "姓名",
|
title: "姓名",
|
||||||
dataIndex: "userName",
|
dataIndex: "studentName",
|
||||||
key: "userName",
|
key: "studentName",
|
||||||
width: 50,
|
width: 50,
|
||||||
align: "left",
|
align: "left",
|
||||||
className: "h head",
|
className: "h head",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "所在部门",
|
title: "所在部门",
|
||||||
dataIndex: "deptName",
|
dataIndex: "studentDepartName",
|
||||||
key: "userName",
|
key: "studentDepartName",
|
||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "所在岗位",
|
title: "所在岗位",
|
||||||
dataIndex: "jobName",
|
dataIndex: "studentJobName",
|
||||||
key: "jobName",
|
key: "studentJobName",
|
||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "考试次数",
|
title: "考试次数",
|
||||||
dataIndex: "examNum",
|
dataIndex: "testNumber",
|
||||||
key: "examNum",
|
key: "testNumber",
|
||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
@@ -237,8 +235,8 @@ export default {
|
|||||||
|
|
||||||
{
|
{
|
||||||
title: "完成时间",
|
title: "完成时间",
|
||||||
dataIndex: "comptime",
|
dataIndex: "finishedTime",
|
||||||
key: "comptime",
|
key: "finishedTime",
|
||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
@@ -250,8 +248,17 @@ export default {
|
|||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
|
customRender: (text) => {
|
||||||
|
console.log(text.record.status);
|
||||||
|
return (
|
||||||
|
<div class="racona">
|
||||||
|
<span> {text.record.status==0?"未开始":text.record.status==10?"未通过":"已通过"}</span>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
},
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
loadingData: true
|
||||||
});
|
});
|
||||||
|
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
@@ -260,16 +267,19 @@ export default {
|
|||||||
state.projectName = "";
|
state.projectName = "";
|
||||||
state.selectedRowKeys = [];
|
state.selectedRowKeys = [];
|
||||||
state.currentPage = 1;
|
state.currentPage = 1;
|
||||||
|
state.tabledata = [];
|
||||||
};
|
};
|
||||||
const afterVisibleChange = (bol) => {
|
const afterVisibleChange = (bol) => {
|
||||||
if (bol == true) {
|
if (bol == true) {
|
||||||
// getManageList();
|
state.loadingData = true;
|
||||||
|
getData();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
const selectProjectName = (value) => {
|
const selectProjectName = (value) => {
|
||||||
state.projectName = value;
|
state.projectName = value;
|
||||||
};
|
};
|
||||||
const onSelectChange = (selectedRowKeys) => {
|
const onSelectChange = (selectedRowKeys) => {
|
||||||
|
console.log('表格前方选中项目', selectedRowKeys)
|
||||||
if (selectedRowKeys.length > 2) {
|
if (selectedRowKeys.length > 2) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -290,6 +300,64 @@ export default {
|
|||||||
state.selectedRowKeys = [];
|
state.selectedRowKeys = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 获取数据
|
||||||
|
function getData() {
|
||||||
|
console.log('我是传递的参数',{
|
||||||
|
"chapterId": props.datasource.stageId,
|
||||||
|
"pageNo": state.currentPage,
|
||||||
|
"pageSize": state.pageSize,
|
||||||
|
"studentName": state.name,
|
||||||
|
"targetId": props.datasource.projectId,
|
||||||
|
"taskId": props.datasource.courseId,
|
||||||
|
"type": 1
|
||||||
|
})
|
||||||
|
api.ExamManagementMessage({
|
||||||
|
"chapterId": props.datasource.stageId,
|
||||||
|
"pageNo": state.currentPage,
|
||||||
|
"pageSize": state.pageSize,
|
||||||
|
"studentName": state.name,
|
||||||
|
"targetId": props.datasource.projectId,
|
||||||
|
"taskId": props.datasource.courseId,
|
||||||
|
"type": 1
|
||||||
|
}).then(res=>{
|
||||||
|
console.log(res)
|
||||||
|
if(res.data.code == 200){
|
||||||
|
let newData = [];
|
||||||
|
for(let i=0;i<res.data.data.managementDtoList.length;i++){
|
||||||
|
res.data.data.managementDtoList[i].key = i + 1;
|
||||||
|
newData.push(res.data.data.managementDtoList[i])
|
||||||
|
}
|
||||||
|
state.tabledata = newData;
|
||||||
|
state.tableDataTotal = res.data.data.total;
|
||||||
|
state.loadingData = false;
|
||||||
|
console.log('我是处理过后的数据', newData)
|
||||||
|
}
|
||||||
|
}).catch(err=>{
|
||||||
|
console.log(err)
|
||||||
|
state.loadingData = false;
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 搜索
|
||||||
|
function searchTableData() {
|
||||||
|
state.loadingData = true;
|
||||||
|
getData();
|
||||||
|
}
|
||||||
|
// 重置
|
||||||
|
function reseatTableData() {
|
||||||
|
state.loadingData = true;
|
||||||
|
state.currentPage = 1;
|
||||||
|
state.name = '';
|
||||||
|
state.projectName = '';
|
||||||
|
getData();
|
||||||
|
}
|
||||||
|
|
||||||
|
//分页
|
||||||
|
const changePaginationStu = (page) => {
|
||||||
|
state.loadingData = true;
|
||||||
|
state.currentPage = page;
|
||||||
|
getData();
|
||||||
|
};
|
||||||
|
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
selectProjectName,
|
selectProjectName,
|
||||||
@@ -299,6 +367,9 @@ export default {
|
|||||||
godie,
|
godie,
|
||||||
clearLine,
|
clearLine,
|
||||||
showEScoreModal,
|
showEScoreModal,
|
||||||
|
searchTableData,
|
||||||
|
reseatTableData,
|
||||||
|
changePaginationStu
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
@@ -597,3 +668,4 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|||||||
@@ -45,12 +45,12 @@
|
|||||||
<div
|
<div
|
||||||
class="btn btn1"
|
class="btn btn1"
|
||||||
style="margin-right: 20px"
|
style="margin-right: 20px"
|
||||||
@click="searchTaskList"
|
@click="searchTableData"
|
||||||
>
|
>
|
||||||
<div class="img1"></div>
|
<div class="img1"></div>
|
||||||
<div class="wz">搜索</div>
|
<div class="wz">搜索</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="btn btn2" @click="resetTaskList">
|
<div class="btn btn2" @click="reseatTableData">
|
||||||
<div class="img2"></div>
|
<div class="img2"></div>
|
||||||
<div class="wz">重置</div>
|
<div class="wz">重置</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -65,9 +65,9 @@
|
|||||||
<div class="img2"></div>
|
<div class="img2"></div>
|
||||||
<div class="wz">导出数据</div>
|
<div class="wz">导出数据</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="btn btn2" @click="showEScoreModal">
|
<!-- <div class="btn btn2" @click="showEScoreModal">
|
||||||
<div class="wz">导入成绩</div>
|
<div class="wz">导入成绩</div>
|
||||||
</div>
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="line">
|
<!-- <div class="line">
|
||||||
<div class="inline">
|
<div class="inline">
|
||||||
@@ -87,7 +87,7 @@
|
|||||||
style="border: 1px solid #f2f6fe"
|
style="border: 1px solid #f2f6fe"
|
||||||
:columns="tablecolumns"
|
:columns="tablecolumns"
|
||||||
:data-source="tabledata"
|
:data-source="tabledata"
|
||||||
:loading="tableDataTotal === -1 ? true : false"
|
:loading="loadingData"
|
||||||
:scroll="{ x: 900 }"
|
:scroll="{ x: 900 }"
|
||||||
:pagination="false"
|
:pagination="false"
|
||||||
:row-selection="{
|
:row-selection="{
|
||||||
@@ -106,13 +106,14 @@
|
|||||||
:total="tableDataTotal"
|
:total="tableDataTotal"
|
||||||
class="pagination"
|
class="pagination"
|
||||||
v-if="tableDataTotal > 10"
|
v-if="tableDataTotal > 10"
|
||||||
|
@change="changePaginationStu"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnn">
|
<div class="btnn">
|
||||||
<button class="btn1">取消</button>
|
<button class="btn1" @click="closeDrawer">取消</button>
|
||||||
<button class="btn2">确定</button>
|
<button class="btn2" @click="closeDrawer">确定</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- 导出成绩抽屉 -->
|
<!-- 导出成绩抽屉 -->
|
||||||
@@ -124,6 +125,8 @@
|
|||||||
import { toRefs, reactive } from "vue";
|
import { toRefs, reactive } from "vue";
|
||||||
import { message } from "ant-design-vue";
|
import { message } from "ant-design-vue";
|
||||||
import EScore from "../ExportScore.vue";
|
import EScore from "../ExportScore.vue";
|
||||||
|
import * as api from '../../../api/indexTaskManage';
|
||||||
|
|
||||||
// import * as api from "../../../api/index";
|
// import * as api from "../../../api/index";
|
||||||
export default {
|
export default {
|
||||||
name: "RouterExaminationManage",
|
name: "RouterExaminationManage",
|
||||||
@@ -154,18 +157,17 @@
|
|||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
name: "",
|
name: "",
|
||||||
|
|
||||||
open: false,
|
open: false,
|
||||||
projectName: null,
|
projectName: "",
|
||||||
projectNameList: [
|
projectNameList: [
|
||||||
{
|
{
|
||||||
id: 1,
|
id: 1,
|
||||||
value: "-1",
|
value: "0",
|
||||||
label: "未开始",
|
label: "未开始",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 2,
|
id: 2,
|
||||||
value: "0",
|
value: "10",
|
||||||
label: "未通过",
|
label: "未通过",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -179,64 +181,53 @@
|
|||||||
pageNo: 1,
|
pageNo: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
currentPage: 1,
|
currentPage: 1,
|
||||||
tableDataTotal: 1,
|
tableDataTotal: 0,
|
||||||
tabledata: [
|
tabledata: [],
|
||||||
{
|
|
||||||
workNum: "123",
|
|
||||||
userName: "li",
|
|
||||||
deptName: "开发",
|
|
||||||
jobName: "前端开发",
|
|
||||||
score: 89,
|
|
||||||
examNum: 1,
|
|
||||||
comptime: "2022-07-22 14:00:30",
|
|
||||||
status: "已完成",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
tablecolumns: [
|
tablecolumns: [
|
||||||
{
|
{
|
||||||
title: "工号",
|
title: "工号",
|
||||||
dataIndex: "workNum",
|
dataIndex: "studentCode",
|
||||||
key: "workNum",
|
key: "studentCode",
|
||||||
width: 50,
|
width: 50,
|
||||||
align: "left",
|
align: "left",
|
||||||
className: "h head",
|
className: "h head"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "姓名",
|
title: "姓名",
|
||||||
dataIndex: "userName",
|
dataIndex: "studentName",
|
||||||
key: "userName",
|
key: "studentName",
|
||||||
width: 50,
|
width: 50,
|
||||||
align: "left",
|
align: "left",
|
||||||
className: "h head",
|
className: "h head",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "所在部门",
|
title: "所在部门",
|
||||||
dataIndex: "deptName",
|
dataIndex: "studentDepartName",
|
||||||
key: "userName",
|
key: "studentDepartName",
|
||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "所在岗位",
|
title: "所在岗位",
|
||||||
dataIndex: "jobName",
|
dataIndex: "studentJobName",
|
||||||
key: "jobName",
|
key: "studentJobName",
|
||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "学员关卡",
|
title: "学员关卡",
|
||||||
dataIndex: "level",
|
dataIndex: "currentStageId",
|
||||||
key: "level",
|
key: "currentStageId",
|
||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "考试次数",
|
title: "考试次数",
|
||||||
dataIndex: "examNum",
|
dataIndex: "testNumber",
|
||||||
key: "examNum",
|
key: "testNumber",
|
||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
@@ -252,8 +243,8 @@
|
|||||||
|
|
||||||
{
|
{
|
||||||
title: "完成时间",
|
title: "完成时间",
|
||||||
dataIndex: "comptime",
|
dataIndex: "finishedTime",
|
||||||
key: "comptime",
|
key: "finishedTime",
|
||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
@@ -265,8 +256,17 @@
|
|||||||
width: 60,
|
width: 60,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
|
customRender: (text) => {
|
||||||
|
console.log(text.record.status);
|
||||||
|
return (
|
||||||
|
<div class="racona">
|
||||||
|
<span> {text.record.status==0?"未开始":text.record.status==10?"未通过":"已通过"}</span>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
},
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
loadingData: true
|
||||||
});
|
});
|
||||||
|
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
@@ -279,6 +279,7 @@
|
|||||||
};
|
};
|
||||||
const afterVisibleChange = (bol) => {
|
const afterVisibleChange = (bol) => {
|
||||||
if (bol == true) {
|
if (bol == true) {
|
||||||
|
state.loadingData = true;
|
||||||
getData();
|
getData();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@@ -286,6 +287,7 @@
|
|||||||
state.projectName = value;
|
state.projectName = value;
|
||||||
};
|
};
|
||||||
const onSelectChange = (selectedRowKeys) => {
|
const onSelectChange = (selectedRowKeys) => {
|
||||||
|
console.log('表格前方选中项目', selectedRowKeys)
|
||||||
if (selectedRowKeys.length > 2) {
|
if (selectedRowKeys.length > 2) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -308,20 +310,62 @@
|
|||||||
|
|
||||||
// 获取数据
|
// 获取数据
|
||||||
function getData() {
|
function getData() {
|
||||||
state.tabledata = [
|
console.log('我是传递的参数',{
|
||||||
{
|
"chapterId": props.datasource.chapterId,
|
||||||
workNum: "123",
|
"pageNo": state.currentPage,
|
||||||
userName: "li",
|
"pageSize": state.pageSize,
|
||||||
deptName: "开发",
|
"studentName": state.name,
|
||||||
jobName: "前端开发",
|
"targetId": props.datasource.routerId,
|
||||||
score: 89,
|
"taskId": props.datasource.courseId,
|
||||||
examNum: 1,
|
"type": 1
|
||||||
comptime: "2022-07-22 14:00:30",
|
})
|
||||||
status: "已完成",
|
api.ExamManagementMessage({
|
||||||
},
|
"chapterId": props.datasource.chapterId,
|
||||||
]
|
"pageNo": state.currentPage,
|
||||||
|
"pageSize": state.pageSize,
|
||||||
|
"studentName": state.name,
|
||||||
|
"targetId": props.datasource.routerId,
|
||||||
|
"taskId": props.datasource.courseId,
|
||||||
|
"type": 1
|
||||||
|
}).then(res=>{
|
||||||
|
console.log(res)
|
||||||
|
if(res.data.code == 200){
|
||||||
|
let newData = [];
|
||||||
|
for(let i=0;i<res.data.data.managementDtoList.length;i++){
|
||||||
|
res.data.data.managementDtoList[i].key = i + 1;
|
||||||
|
newData.push(res.data.data.managementDtoList[i])
|
||||||
|
}
|
||||||
|
state.tabledata = newData;
|
||||||
|
state.tableDataTotal = res.data.data.total;
|
||||||
|
state.loadingData = false;
|
||||||
|
console.log('我是处理过后的数据', newData)
|
||||||
|
}
|
||||||
|
}).catch(err=>{
|
||||||
|
console.log(err)
|
||||||
|
state.loadingData = false;
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
// 搜索
|
||||||
|
function searchTableData() {
|
||||||
|
state.loadingData = true;
|
||||||
|
getData();
|
||||||
|
}
|
||||||
|
// 重置
|
||||||
|
function reseatTableData() {
|
||||||
|
state.loadingData = true;
|
||||||
|
state.currentPage = 1;
|
||||||
|
state.name = '';
|
||||||
|
state.projectName = '';
|
||||||
|
getData();
|
||||||
|
}
|
||||||
|
|
||||||
|
//分页
|
||||||
|
const changePaginationStu = (page) => {
|
||||||
|
state.loadingData = true;
|
||||||
|
state.currentPage = page;
|
||||||
|
getData();
|
||||||
|
};
|
||||||
|
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
selectProjectName,
|
selectProjectName,
|
||||||
@@ -331,6 +375,9 @@
|
|||||||
godie,
|
godie,
|
||||||
clearLine,
|
clearLine,
|
||||||
showEScoreModal,
|
showEScoreModal,
|
||||||
|
searchTableData,
|
||||||
|
reseatTableData,
|
||||||
|
changePaginationStu
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -625,7 +625,7 @@
|
|||||||
: item.type == '4'
|
: item.type == '4'
|
||||||
? showWork(item.name, item.projectTaskId)
|
? showWork(item.name, item.projectTaskId)
|
||||||
: item.type == '5'
|
: item.type == '5'
|
||||||
? showTest(item.name, item.projectTaskId)
|
? showTest(item.name, item.projectTaskId, item)
|
||||||
: item.type == '10'
|
: item.type == '10'
|
||||||
? showEval(item.name, item.projectTaskId)
|
? showEval(item.name, item.projectTaskId)
|
||||||
: item.type == '12'
|
: item.type == '12'
|
||||||
@@ -1114,6 +1114,7 @@
|
|||||||
v-model:TMvisible="TMvisible"
|
v-model:TMvisible="TMvisible"
|
||||||
:title="showTestText"
|
:title="showTestText"
|
||||||
:projectTaskId="projectTaskId"
|
:projectTaskId="projectTaskId"
|
||||||
|
:datasource="examData"
|
||||||
/>
|
/>
|
||||||
<!-- 测评抽屉 -->
|
<!-- 测评抽屉 -->
|
||||||
<ProjectEvalManage
|
<ProjectEvalManage
|
||||||
@@ -2444,6 +2445,8 @@ export default {
|
|||||||
|
|
||||||
codevisible: false, //二维码是否显示
|
codevisible: false, //二维码是否显示
|
||||||
codeInfo: null, //二维码标题
|
codeInfo: null, //二维码标题
|
||||||
|
|
||||||
|
examData: "",
|
||||||
});
|
});
|
||||||
|
|
||||||
const levelList = reactive({
|
const levelList = reactive({
|
||||||
@@ -2724,13 +2727,14 @@ export default {
|
|||||||
state.showkaoqinText = title;
|
state.showkaoqinText = title;
|
||||||
};
|
};
|
||||||
//作业管理的抽屉
|
//作业管理的抽屉
|
||||||
const showWork = (name, id) => {
|
const showWork = (name, id, ) => {
|
||||||
state.Wvisible = true;
|
state.Wvisible = true;
|
||||||
state.showWorkText = name;
|
state.showWorkText = name;
|
||||||
state.projectTaskId = id;
|
state.projectTaskId = id;
|
||||||
};
|
};
|
||||||
//考试管理的抽屉
|
//考试管理的抽屉
|
||||||
const showTest = (name, id) => {
|
const showTest = (name, id, data) => {
|
||||||
|
state.examData = data;
|
||||||
state.TMvisible = true;
|
state.TMvisible = true;
|
||||||
state.showTestText = name;
|
state.showTestText = name;
|
||||||
state.projectTaskId = id;
|
state.projectTaskId = id;
|
||||||
|
|||||||
Reference in New Issue
Block a user