@@ -1503,15 +1491,11 @@ import {
computed,
} from "vue";
-import * as api from "../../api/indexInvist.js";
import * as apis from "../../api/indexTaskManage";
import {message} from "ant-design-vue";
import {useRouter, useRoute} from "vue-router";
import CommonStudent from "@/components/student/CommonStudent";
import OwnerTableModelStudent from "@/components/student/OwnerTableModelStudent";
-// import StuAdd from "../../components/drawers/StuAdd";
-// import OwnPower from "../../components/drawers/OwnPower.vue";
-// import Corpowerlist from "../../components/drawers/CorPowerlist.vue";
import addOnlineCourse from "../../components/Modals/addOnlineCourse.vue";
import ProjOwnerShip from "../../components/drawers/ProjectOwn";
@@ -1550,11 +1534,11 @@ import SeeModal from "./components/seeModal.vue";
import CourseModal from "./courseModal.vue";
import * as moment from "moment";
import TwoDimensionalCode from "../../components/TwoDimensionalCode.vue";
-import {codeUrl, toDate} from "../../api/method";
+import {codeUrl, toDate} from "@/api/method";
import {queryWorkDetailById} from "@/api/indexWork";
import {queryExaminationDetailById} from "@/api/indexExam";
-import AddHomework from "../../components/drawers/AddHomework.vue";
-import AddTest from "../../components/drawers/AddTest.vue";
+import AddHomework from "../../components/drawers/CommonHomework.vue";
+import AddTest from "../../components/drawers/CommonTest.vue";
import TableStudent from "@/components/student/TableStudent";
import FJUpload from "@/components/common/FJUpload";
import {updateStudent} from "@/api/indexProjStu";
@@ -1562,7 +1546,6 @@ import {useStore} from "vuex";
import DropDown from "@/components/common/DropDown";
import {checkPer} from "@/utils/utils";
import dayjs from "dayjs";
-// import { commonExport } from '@/utils/commonExcel'
//列表表格
const columns1 = [
@@ -2171,6 +2154,8 @@ export default defineComponent({
const store = useStore();
const state = reactive({
+ workInfo:{},
+ examInfo:{},
tableLoading: false,
//新加
stuColumns: [
@@ -3193,13 +3178,11 @@ export default defineComponent({
const showDrawerAddTest = () => {
state.addtestvisible = true;
};
- const logW = (e) => {
- state.EditWorkId = null;
- console.log(e);
+ const logW = () => {
+ state.workInfo = {}
};
- const logT = (e) => {
- state.EditTestId = 0;
- console.log(e);
+ const logT = () => {
+ state.examInfo = {}
};
const removePG = () => {
console.log("11111");
@@ -3670,13 +3653,7 @@ export default defineComponent({
startTime = dayjs(state.xjkkinputV3[0]).format('YYYY-MM-DD HH:mm') //parseInt(state.xjkkinputV3[0].$d.getTime() / 1000);
endTime = dayjs(state.xjkkinputV3[1]).format('YYYY-MM-DD HH:mm') //parseInt(state.xjkkinputV3[1].$d.getTime() / 1000);
}
-// console.log("state.validate", state.validate);
-
-// if (!state.validate) {
-// message.destroy();
-// return message.warning("该开课名称已存在");
-// }
-const offName = await validateName({ name: state.xjkkinputV1, type: 5 }).then(res => {
+ const offName = await validateName({ name: state.xjkkinputV1, type: 5 ,id:state.offcoursePlanId}).then(res => {
console.log(res,res.data.data);
return res.data.data === 1;
});
@@ -3706,6 +3683,8 @@ const offName = await validateName({ name: state.xjkkinputV1, type: 5 }).then(re
// signWordFlag: state.xjkkradioV1 === 1 ? 1 : 0, //签到是否需要口令:1是0否
teacherId: state.member.value,
teacher: state.member.name,
+ workInfo: state.workInfo,//提交的作业信息
+ examInfo: state.examInfo//提交的考试信息
};
console.log(postData);
const checkList = [
@@ -3735,30 +3714,14 @@ const offName = await validateName({ name: state.xjkkinputV1, type: 5 }).then(re
state.offcourseId = item.offcourseId;
state.offcoursePlanId = item.id;
- if (item.evaluateId) {
- api
- .queryAppraiseDetailById({assessmentId: item.evaluateId})
- .then((res) => {
- state.assessmentName = res.data.data.assessmentName;
- })
- .catch();
- }
if (item.homeWorkId) {
- queryWorkDetailById({workId: item.homeWorkId}).then((res) => {
- state.workName = res.data.data.workName;
- });
+ queryWorkDetailById({workId: item.homeWorkId}).then((res) => state.workInfo = res.data.data);
}
if (item.testId) {
- queryExaminationDetailById({examinationId: item.testId}).then(
- (res) => {
- state.testName = res.data.data.examinationName;
- }
- );
+ queryExaminationDetailById({examinationId: item.testId}).then((res) => state.examInfo = res.data.data);
}
- console.log("res");
console.log("获取面授课开课详情", item);
-
state.xjkkinputV2 = item.address;
state.checked1 = item.applyFlag === 1 ? true : false;
let arrss = item.attach.split(",");
@@ -3781,7 +3744,8 @@ const offName = await validateName({ name: state.xjkkinputV1, type: 5 }).then(re
(state.comLeave =
item.completeType.split(",")[1] == "1" ? true : false),
(state.checked4 = item.evalFlag === 1 ? true : false);
- state.assessmentId = String(item.evaluateId);
+ state.assessmentName = item.assessmentName;
+ state.assessmentId = String(item.assessmentId);
state.EditTestId = Number(item.testId);
state.EditWorkId = String(item.homeWorkId);
state.xjkkinputV1 = item.name;
@@ -4675,7 +4639,6 @@ const offName = await validateName({ name: state.xjkkinputV1, type: 5 }).then(re
};
const disabledDate = (current) => {
// Can not select days before today and today
- console.log("1111", dayjs().endOf("day"));
return current && current < dayjs().startOf("day");
};