dev_2022-05-11
yujialong 3 years ago
parent c19c41390d
commit 711829036a
  1. 4
      src/pages/account/login/index.vue
  2. 48
      src/pages/achievement/list/index.vue
  3. 15
      src/pages/achievement/teach/index.vue
  4. 15
      src/pages/achievement/vir/index.vue
  5. 2
      src/pages/assessment/add/index.vue
  6. 73
      src/pages/assessment/list/index.vue
  7. 35
      src/pages/course/courseManagement/contentSettings.vue
  8. 4
      src/pages/match/manage/matchSignup.vue

@ -79,12 +79,12 @@ export default {
isHh: Setting.isHh,
tabName: "1",
param: {
account: "admin",
account: "zh",
password: "111aaa",
code: "", //
random: "", //
distinguish: null, // ,1,2
platform: 3 // 123
platform: 1 // 123
},
rules: {
account: [{ required: true, message: "请输入账号", trigger: "blur" }],

@ -18,7 +18,7 @@
</li>
<li v-show="projectPermissions === 1">
<label>班级</label>
<el-select size="small" v-model="classId" placeholder="请选择" @change="initData">
<el-select size="small" v-model="classId" @change="initData">
<el-option
v-for="item in classList"
:key="item.id"
@ -32,13 +32,13 @@
<div class="tool mul">
<ul class="filter">
<li>
<label>系统</label>
<el-select size="small" v-model="systemId" placeholder="请选择" @change="initData">
<label>课程</label>
<el-select v-model="curriculumId" @change="initData">
<el-option
v-for="item in systemList"
:key="item.value"
:label="item.label"
:value="item.id"
v-for="item in curriculumList"
:key="item.cid"
:label="item.curriculumName"
:value="item.cid"
></el-option>
</el-select>
</li>
@ -98,8 +98,8 @@ export default {
return {
classId: "",
classList: [],
systemId: "",
systemList: Setting.systemList,
curriculumId: "",
curriculumList: [],
projectPermissions: this.$route.query.per ? Number(this.$route.query.per) : 0,
keyword: "",
searchTimer: null,
@ -139,11 +139,6 @@ export default {
loadIns: null,
};
},
computed: {
...mapState("project", [
"lastSystemId"
])
},
watch: {
month: function(val) {
if (val) {
@ -171,15 +166,21 @@ export default {
}
},
mounted() {
// systemIdsystemIdsystemId
this.systemId = this.lastSystemId ? this.lastSystemId : Setting.systemId;
this.getData();
this.getschoolCourse();
this.getClassData();
},
methods: {
...mapActions("project", [
"setSystemId"
]),
getschoolCourse() { //
this.$get(this.api.schoolCourse).then(res => {
if (res.data && res.data.length) {
this.curriculumList = res.data;
this.curriculumId = this.curriculumList[0].cid;
this.getData();
}
}).catch(err => {
console.log(err);
});
},
getClassData() { //
this.$post(this.api.myClass).then(res => {
this.classList = res.list;
@ -192,7 +193,7 @@ export default {
let data = {
classId: this.classId,
permissions: this.projectPermissions,
systemId: this.systemId,
curriculumId: this.curriculumId,
keyWord: this.keyword,
startTime: this.startingtime,
endTime: this.endTime,
@ -221,14 +222,13 @@ export default {
return true;
},
entry(row) { //
this.setSystemId(this.systemId);
if (this.projectPermissions === 1) {
let list = row.classList.map(i => {
return {id: i.id.toString(), name: i.className}
})
this.$router.push(`teach?assessmentId=${row.assessmentId}&projectName=${row.projectName}&permissions=${row.permissions}&systemId=${this.systemId}&classList=${JSON.stringify(list)}`);
this.$router.push(`teach?assessmentId=${row.assessmentId}&projectName=${row.projectName}&permissions=${row.permissions}&classList=${JSON.stringify(list)}`);
} else {
this.$router.push(`vir?projectId=${row.projectId}&projectName=${row.projectName}&permissions=${row.permissions}&systemId=${this.systemId}`);
this.$router.push(`vir?projectId=${row.projectId}&projectName=${row.projectName}&permissions=${row.permissions}`);
}
},
handleDelete(row) { //

@ -63,7 +63,6 @@
</el-table-column>
<el-table-column label="操作" align="center" width="220">
<template slot-scope="scope">
<!-- <el-button type="text" @click="edit(scope.row)">修改分数</el-button> -->
<el-button type="text" @click="show(scope.row)">查看成绩报告</el-button>
<el-button type="text" @click="handleDelete(scope.row)">删除</el-button>
</template>
@ -88,7 +87,6 @@ export default {
activeName: "", //
classId: "", // id
classList: [], //
systemId: this.$route.query.systemId,
permissions: this.$route.query.permissions,
experimentalName: this.$route.query.projectName,
assessmentId: this.$route.query.assessmentId,
@ -136,25 +134,12 @@ export default {
}).catch(err => {
});
},
edit(row) {
if (this.systemId == 2 || this.systemId == 3) {
this.$router.push(`addexperiment?id=${row.reportId}&stuId=${row.userId}&studentName=${row.studentName}&class=${row.class}`);
} else {
this.$router.push(`addexperiment?id=${row.reportId}`);
}
},
show(row) { //
if (this.systemId == 2) {
this.$router.push(`showexperimentOption?id=${row.reportId}&stuId=${row.userId}&studentName=${row.studentName}&class=${row.class}`);
} else if (this.systemId == 3) {
this.$router.push(`showexperimentOptions?id=${row.reportId}&stuId=${row.userId}&studentName=${row.studentName}&class=${row.class}`);
} else {
if (this.permissions) {
this.$router.push(`show?id=${row.recordId}&projectId=${row.projectId}&reportId=${row.reportId}&studentId=${row.studentId}`);
} else {
this.$router.push(`show?id=${row.recordId}&type=1`);
}
}
},
exportData() { // ()
if (this.multipleSelection.length) {

@ -48,7 +48,6 @@
</el-table-column>
<el-table-column label="操作" align="center" width="220">
<template slot-scope="scope">
<!-- <el-button type="text" @click="edit(scope.row)">修改分数</el-button> -->
<el-button type="text" @click="show(scope.row)">查看成绩报告</el-button>
<el-button type="text" @click="handleDelete(scope.row)">删除</el-button>
</template>
@ -70,7 +69,6 @@ import echarts from "echarts";
export default {
data() {
return {
systemId: this.$route.query.systemId,
permissions: this.$route.query.permissions,
experimentName: this.$route.query.projectName,
projectId: this.$route.query.projectId,
@ -112,25 +110,12 @@ export default {
}).catch(res => {
});
},
edit(row) {
if (this.systemId == 2 || this.systemId == 3) {
this.$router.push(`addexperiment?id=${row.reportId}&stuId=${row.userId}&studentName=${row.studentName}&class=${row.class}`);
} else {
this.$router.push(`addexperiment?id=${row.reportId}`);
}
},
show(row) {
if (this.systemId == 2) {
this.$router.push(`showexperimentOption?id=${row.reportId}&stuId=${row.userId}&studentName=${row.studentName}&class=${row.class}`);
} else if (this.systemId == 3) {
this.$router.push(`showexperimentOptions?id=${row.reportId}&stuId=${row.userId}&studentName=${row.studentName}&class=${row.class}`);
} else {
if (this.permissions) {
this.$router.push(`show?id=${row.recordId}&projectId=${this.projectId}&reportId=${row.reportId}`);
} else {
this.$router.push(`show?id=${row.recordId}&type=1`);
}
}
},
exportData() {
if (this.multipleSelection.length) {

@ -68,7 +68,7 @@
<div>
<p class="m-b-20">课程</p>
<div class="inline-input">
<el-select v-model="form.curriculumId" placeholder="请选择" @change="initData">
<el-select v-model="form.curriculumId" @change="initData">
<el-option
v-for="item in curriculumList"
:key="item.cid"

@ -23,14 +23,14 @@
</el-select>
</li>
<li>
<label>系统</label>
<el-select size="small" v-model="systemId" placeholder="请选择" @change="initData">
<label>课程</label>
<el-select size="small" v-model="curriculumId" placeholder="请选择" @change="initData">
<el-option label="不限" value=""></el-option>
<el-option
v-for="item in systemList"
:key="item.value"
:label="item.label"
:value="item.id"
v-for="item in curriculumList"
key="item.cid"
:label="item.curriculumName"
:value="item.cid"
></el-option>
</el-select>
</li>
@ -85,7 +85,7 @@
</el-table-column>
<el-table-column label="倒计时" align="center">
<template slot-scope="scope">
<span>{{ changeTime(scope.row.countDown) }}</span>
<span>{{ scope.row.countDown | timeFilter }}</span>
</template>
</el-table-column>
<el-table-column label="实验状态" align="center">
@ -175,8 +175,8 @@ export default {
}
],
date: [],
systemList: Setting.systemList,
systemId: "",
curriculumList: [],
curriculumId: "",
keyWord: "", //
searchTimer: null,
form: {
@ -191,7 +191,7 @@ export default {
total: 0, //
listData: [], //
multipleSelection: [], //
ticker: null
ticker: null //
};
},
watch: {
@ -221,12 +221,24 @@ export default {
}
},
mounted() {
//
this.$once("hook:beforeDestroy", function() {
clearInterval(this.ticker);
this.ticker = null;
});
this.getData();
this.beginTimer();
this.getschoolCourse();
},
created() {
if (this.ticker) {
clearInterval(this.ticker);
filters: {
timeFilter(countDown) {
if (countDown > 0) {
let h = Math.floor(countDown / (60 * 60));
let m = Math.floor(countDown % (60 * 60) / 60);
let s = Math.floor(countDown % (60 * 60) % 60);
return `${h > 9 ? h : `0${h}`}:${m > 9 ? m : `0${m}`}:${s > 9 ? s : `0${s}`}`;
} else {
return "00:00:00";
}
}
},
methods: {
@ -241,30 +253,19 @@ export default {
}
}, 1000);
},
changeTime(countDown) {
let that = this;
if (countDown < 0) {
clearInterval(setInterval(this.changeTime(countDown), 1000));
}
let hh = that.fillNumber(countDown / (60 * 60));
let mm = that.fillNumber(countDown % (60 * 60) / 60);
let ss = that.fillNumber(countDown % (60 * 60) % 60);
return `${hh}:${mm}:${ss}`;
},
fillNumber(num) {
let number = Math.floor(num);
return number > 9 ? number : `0${number}`;
},
getData() {
if (this.ticker) {
clearInterval(this.ticker);
}
let data = {
...this.form,
keyWord: this.keyWord,
pageNum: this.pageNum,
pageSize: this.pageSize,
systemId: this.systemId
curriculumId: this.curriculumId
};
this.$post(this.api.pageByCondition, data).then(res => {
if (res.status === 200) {
if (res.status === 200 && res.list && res.list.length) {
this.listData = res.list;
this.total = res.total;
this.listData.forEach(i => {
@ -290,8 +291,7 @@ export default {
}
}
});
} else {
util.errorMsg(res.message);
this.beginTimer();
}
}).catch(err => {
console.log(err);
@ -302,6 +302,13 @@ export default {
this.pageNum = 1;
this.getData();
},
getschoolCourse() { //
this.$get(this.api.schoolCourse).then(res => {
this.curriculumList = res.data;
}).catch(err => {
console.log(err);
});
},
add() {
this.$router.push("add");
},
@ -309,7 +316,7 @@ export default {
this.$router.push(`add?id=${row.id}`);
},
show(row) {
this.$router.push(`/achievement/ass?systemId=${this.systemId}&id=${row.id}&projectId=${row.projectId}&name=${row.projectName}&experimentalName=${row.experimentalName}&class=${row.experimentalClassName}`);
this.$router.push(`/achievement/ass?curriculumId=${this.curriculumId}&id=${row.id}&projectId=${row.projectId}&name=${row.projectName}&experimentalName=${row.experimentalName}&class=${row.experimentalClassName}`);
},
start(row) {
let data = {

@ -12,12 +12,12 @@
<div class="p-title">内容设置</div>
<div class="btns" style="top: -10px">
<template v-if="!sorting">
<el-button type="primary" size="small" round v-throttle @click="addChapter">添加章节</el-button>
<el-button type="primary" size="small" round v-throttle @click="sort">编辑顺序</el-button>
<el-button type="primary" round v-throttle @click="addChapter">添加章节</el-button>
<el-button type="primary" round v-throttle @click="sort">编辑顺序</el-button>
</template>
<template v-else>
<el-button type="primary" size="small" round v-throttle @click="cancelSort">取消</el-button>
<el-button type="primary" size="small" round v-throttle @click="saveSort">保存</el-button>
<el-button type="primary" round v-throttle @click="cancelSort">取消</el-button>
<el-button type="primary" round v-throttle @click="saveSort">保存</el-button>
</template>
</div>
</div>
@ -28,9 +28,9 @@
<div>{{ chapter.name }}</div>
<div>
<template v-if="!sorting">
<el-button class="action-btn" type="primary" size="small" round v-throttle @click="editChapter(chapter)">修改章节名称</el-button>
<el-button class="action-btn" type="primary" size="small" round v-throttle @click="addSection(chapter.id)">添加小节</el-button>
<el-button class="action-btn" type="primary" size="small" round v-throttle @click="delChapter(chapter.id)">删除</el-button>
<el-button class="action-btn" type="primary" round v-throttle @click="editChapter(chapter)">修改章节名称</el-button>
<el-button class="action-btn" type="primary" round v-throttle @click="addSection(chapter.id)">添加小节</el-button>
<el-button class="action-btn" type="primary" round v-throttle @click="delChapter(chapter.id)">删除</el-button>
</template>
<template v-else>
<i class="el-icon-top sort-icon" :class="{disabled: index == 0}" style="margin-right: 5px" @click="sortChapter(chapter,'up',index == 0,index)"></i>
@ -72,8 +72,8 @@
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="chapterVisible = false">取消</el-button>
<el-button size="small" type="primary" @click="chapterSubmit">确定</el-button>
<el-button @click="chapterVisible = false">取消</el-button>
<el-button type="primary" @click="chapterSubmit">确定</el-button>
</span>
</el-dialog>
@ -101,8 +101,8 @@
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="sectionVisible = false">取消</el-button>
<el-button size="small" type="primary" @click="sectionSubmit">确定</el-button>
<el-button @click="sectionVisible = false">取消</el-button>
<el-button type="primary" @click="sectionSubmit">确定</el-button>
</span>
</el-dialog>
@ -124,8 +124,8 @@
</el-upload>
</div>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="switchVisible = false">取消</el-button>
<el-button size="small" type="primary" @click="switchSubmit">确定</el-button>
<el-button @click="switchVisible = false">取消</el-button>
<el-button type="primary" @click="switchSubmit">确定</el-button>
</span>
</el-dialog>
@ -136,8 +136,8 @@
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="sectionNameVisible = false">取消</el-button>
<el-button size="small" type="primary" @click="sectionNameSubmit">确定</el-button>
<el-button @click="sectionNameVisible = false">取消</el-button>
<el-button type="primary" @click="sectionNameSubmit">确定</el-button>
</span>
</el-dialog>
@ -459,9 +459,10 @@ export default {
this.sectionId = "";
},
preview(row) {
// console.log(JSON.stringify(row));
if (this.transferType(row.fileType) == "视频") {
this.$get(`${this.api.getPlayAuth}/${row.fileId}`).then(res => {
this.playAuth = res.data.playAuth;
this.playAuth = res.playAuth;
if (this.player) {
this.player.replayByVidAndPlayAuth(row.fileId, this.playAuth);
} else {
@ -503,7 +504,7 @@ export default {
this.isWord = false;
this.isExcel = false;
}
this.iframeSrc = res.data.previewUrl;
this.iframeSrc = res.previewUrl;
this.$nextTick(() => {
this.iframeOnload();
});

@ -85,8 +85,8 @@ export default {
};
if (this.keyword) data.name = this.keyword;
this.$get(`${this.api.queryApplicantByCondition}/${this.pageNo}/${this.pageSize}`, data).then(res => {
this.listData = res.data.applicantList;
this.totals = res.data.total;
this.listData = res.applicantList;
this.totals = res.total;
this.$refs.table.clearSelection();
}).catch(res => {
});

Loading…
Cancel
Save