Commit d84505a4 authored by zhengke's avatar zhengke

修改

parent def76c52
<style> <style>
.examConfig .Period-rules { .examConfig .Period-rules {
display: flex; display: flex;
margin-bottom: 24px; margin-bottom: 24px;
padding-left: 20px; padding-left: 20px;
} }
.examConfig .Period_Spreate { .examConfig .Period_Spreate {
flex: 1; flex: 1;
width: 50%; width: 50%;
min-width: 400px; min-width: 400px;
margin-right: 32px; margin-right: 32px;
} }
.examConfig .Period-rule-title { .examConfig .Period-rule-title {
color: #646a73; color: #646a73;
margin-bottom: 4px; margin-bottom: 4px;
white-space: nowrap; white-space: nowrap;
display: flex; }
align-items: baseline;
}
.examConfig .Period-info-icon { .examConfig .Period-info-icon {
margin-left: 8px; margin-left: 8px;
color: #8f959e; color: #8f959e;
line-height: 1; line-height: 1;
vertical-align: top; vertical-align: top;
} }
.process_Btn_List { .process_Btn_List {
display: flex; display: flex;
justify-content: flex-end; justify-content: flex-end;
padding: 20px; padding: 20px;
} }
.processBtn_Cancel { .processBtn_Cancel {
width: 90px; width: 90px;
height: 35px; height: 35px;
border: 1px solid #a1aab2; border: 1px solid #a1aab2;
...@@ -44,9 +42,9 @@ ...@@ -44,9 +42,9 @@
border-radius: 5px; border-radius: 5px;
cursor: pointer; cursor: pointer;
margin-right: 20px; margin-right: 20px;
} }
.processBtn_Save { .processBtn_Save {
width: 90px; width: 90px;
height: 35px; height: 35px;
background-color: #2961fe; background-color: #2961fe;
...@@ -55,19 +53,19 @@ ...@@ -55,19 +53,19 @@
line-height: 35px; line-height: 35px;
border-radius: 5px; border-radius: 5px;
cursor: pointer; cursor: pointer;
} }
.baseSetForm_Dialog { .baseSetForm_Dialog {
margin: 20px; margin: 20px;
} }
.examConfig_title { .examConfig_title {
font-size: 14px; font-size: 14px;
color: #1f2329; color: #1f2329;
margin-bottom: 20px; margin-bottom: 20px;
} }
.Period-alert { .Period-alert {
padding: 9px 16px; padding: 9px 16px;
border-radius: 4px; border-radius: 4px;
background-color: #f0f4ff; background-color: #f0f4ff;
...@@ -78,50 +76,45 @@ ...@@ -78,50 +76,45 @@
margin-top: 20px; margin-top: 20px;
margin-bottom: 12px; margin-bottom: 12px;
font-size: 13px; font-size: 13px;
} }
.Okr_Length { .Okr_Length {
font-weight: 500; font-weight: 500;
color: #1f2329; color: #1f2329;
} }
.FormItem-asterisk { .FormItem-asterisk {
position: relative; position: relative;
top: 3px; top: 3px;
margin-left: 3px; margin-left: 3px;
color: #f54a45; color: #f54a45;
line-height: 1; line-height: 1;
} }
.baseSetForm_Dialog .el-radio { .baseSetForm_Dialog .el-radio {
display: block; display: block;
margin-bottom: 15px; margin-bottom: 15px;
} }
.exam-tip {
.exam-tip {
white-space: nowrap; white-space: nowrap;
font-size: 10px; font-size: 10px;
color: red; color: #A8A8B3;
} margin-top:5px;
}
</style> </style>
<template> <template>
<div class="page-body"> <div class="page-body">
<div class="examConfig"> <div class="examConfig">
<div style="text-align: right"> <div style="text-align: right">
<q-btn <q-btn color="accent" size="sm" class="q-mr-md" @click="geteject" label="修改基础配置" />
color="accent"
size="sm"
class="q-mr-md"
@click="geteject"
label="修改基础配置"
/>
</div> </div>
<div class="Period-rules"> <div class="Period-rules">
<div class="Period_Spreate"> <div class="Period_Spreate">
<div class="Period-rule-title"> <div class="Period-rule-title">
是否开启组卷审批 <div>是否开启组卷审批</div>
<span class="exam-tip" <div class="exam-tip">开启后教师组卷不能直接生成使用,需要等待主管审核</div>
>(开启后教师组卷不能直接生成使用,需要等待主管审核)</span
>
</div> </div>
<div> <div>
<span v-if="baseObj.IsOpenZuJuan === 1"></span> <span v-if="baseObj.IsOpenZuJuan === 1"></span>
...@@ -130,10 +123,8 @@ ...@@ -130,10 +123,8 @@
</div> </div>
<div class="Period_Spreate col-6"> <div class="Period_Spreate col-6">
<div class="Period-rule-title"> <div class="Period-rule-title">
是否开启自动阅卷 <div>是否开启自动阅卷</div>
<span class="exam-tip" <div class="exam-tip">考试不能直接发起,需要等待主管审核通过后自动化发布</div>
>(考试不能直接发起,需要等待主管审核通过后自动化发布)</span
>
</div> </div>
<div> <div>
<span v-if="baseObj.IsOpenAutoMarking === 1"></span> <span v-if="baseObj.IsOpenAutoMarking === 1"></span>
...@@ -144,10 +135,8 @@ ...@@ -144,10 +135,8 @@
<div class="Period-rules"> <div class="Period-rules">
<div class="Period_Spreate"> <div class="Period_Spreate">
<div class="Period-rule-title"> <div class="Period-rule-title">
是否开启考试申请 <div>是否开启考试申请</div>
<span class="exam-tip" <div class="exam-tip">注意:开启后系统将对所有试卷内的客观题进行自动阅卷</div>
>(注意:开启后系统将对所有试卷内的客观题进行自动阅卷)</span
>
</div> </div>
<div> <div>
<span v-if="baseObj.IsOpenExamApply === 1"></span> <span v-if="baseObj.IsOpenExamApply === 1"></span>
...@@ -168,47 +157,18 @@ ...@@ -168,47 +157,18 @@
</div> </div>
</div> </div>
</div> </div>
<q-dialog <q-dialog v-model="isShowBaseSet" maximized full-height seamless position="right" @hide="closeProcess">
v-model="isShowBaseSet" <q-card style="margin-top: 61px; width: 500px" class="no-border-radius classinfo_Dialog">
maximized
full-height
seamless
position="right"
@hide="closeProcess"
>
<q-card
style="margin-top: 61px; width: 500px"
class="no-border-radius classinfo_Dialog"
>
<div class="baseSetForm_Dialog"> <div class="baseSetForm_Dialog">
<div class="examConfig_title"> <div class="cycle_Title">考试配置</div>
<div class="examConfig_title" style="margin-top:10px;">
是否开启组卷审批 是否开启组卷审批
<el-switch <el-switch style="margin-left: 10px" v-model="addMsg.IsOpenZuJuan" :active-value="1" :inactive-value="0"></el-switch>
style="margin-left: 10px"
v-model="addMsg.IsOpenZuJuan"
:active-value="1"
:inactive-value="0"
active-text="是"
inactive-text="否"
></el-switch>
</div> </div>
<div v-if="baseObj.IsOpenZuJuan === 1"> <div v-if="baseObj.IsOpenZuJuan === 1">
<q-select <q-select filled stack-label :dense="false" v-model="addMsg.ZuJuanReviewer" :options="EmployeeListOption"
filled option-value="Id" option-label="EmployeeName" emit-value map-options label="组卷审核人" clearable use-input
stack-label :rules="[(val) => !!val || '请选择组卷审核人']" @filter="filterFn" ref="ZuJuanReviewer">
:dense="false"
v-model="addMsg.ZuJuanReviewer"
:options="EmployeeListOption"
option-value="Id"
option-label="EmployeeName"
emit-value
map-options
label="组卷审核人"
use-input
:rules="[(val) => !!val || '请选择组卷审核人']"
@filter="filterFn"
ref="ZuJuanReviewer"
>
<template v-slot:no-option> <template v-slot:no-option>
<q-item> <q-item>
<q-item-section class="text-grey"> <q-item-section class="text-grey">
...@@ -218,46 +178,14 @@ ...@@ -218,46 +178,14 @@
</template> </template>
</q-select> </q-select>
</div> </div>
<div class="examConfig_title">
是否开启自动阅卷
<el-switch
style="margin-left: 10px"
v-model="addMsg.IsOpenAutoMarking"
:active-value="1"
:inactive-value="0"
active-text="是"
inactive-text="否"
></el-switch>
</div>
<div class="examConfig_title"> <div class="examConfig_title">
是否开启考试申请 是否开启考试申请
<el-switch <el-switch style="margin-left: 10px" v-model="addMsg.IsOpenExamApply" :active-value="1" :inactive-value="0"></el-switch>
style="margin-left: 10px"
v-model="addMsg.IsOpenExamApply"
:active-value="1"
:inactive-value="0"
active-text="是"
inactive-text="否"
></el-switch>
</div> </div>
<div v-if="baseObj.IsOpenExamApply === 1"> <div v-if="baseObj.IsOpenExamApply === 1">
<q-select <q-select filled stack-label :dense="false" v-model="addMsg.ExamApplyReviewer" :options="EmployeeListOption"
filled option-value="Id" option-label="EmployeeName" emit-value map-options label="考试申请审核人" clearable use-input
stack-label :rules="[(val) => !!val || '请选择考试申请审核人']" @filter="filterFn" ref="ExamApplyReviewer">
:dense="false"
v-model="addMsg.ExamApplyReviewer"
:options="EmployeeListOption"
option-value="Id"
option-label="EmployeeName"
emit-value
map-options
label="考试申请审核人"
use-input
:rules="[(val) => !!val || '请选择考试申请审核人']"
@filter="filterFn"
ref="ExamApplyReviewer"
>
<template v-slot:no-option> <template v-slot:no-option>
<q-item> <q-item>
<q-item-section class="text-grey"> <q-item-section class="text-grey">
...@@ -267,33 +195,36 @@ ...@@ -267,33 +195,36 @@
</template> </template>
</q-select> </q-select>
</div> </div>
<div class="examConfig_title">
是否开启自动阅卷
<el-switch style="margin-left: 10px" v-model="addMsg.IsOpenAutoMarking" :active-value="1"
:inactive-value="0"></el-switch>
</div>
</div> </div>
<div class="process_Btn_List"> <div class="process_Btn_List">
<div class="processBtn_Cancel" @click="closeProcess">关闭</div> <div class="processBtn_Cancel" @click="closeProcess">关闭</div>
<div class="processBtn_Save" @click="setBaseInfo">确定</div> <div class="processBtn_Save" @click="setBaseInfo">确定</div>
</div> </div>
</q-card> </q-card>
<div <div class="dialog-out-close" @click="closeProcess" style="
class="dialog-out-close"
@click="closeProcess"
style="
height: 40px !important; height: 40px !important;
border-top-left-radius: 4px !important; border-top-left-radius: 4px !important;
border-bottom-left-radius: 4px !important; border-bottom-left-radius: 4px !important;
" ">
>
<q-icon name="iconfont icon-jujue1" size="26px" /> <q-icon name="iconfont icon-jujue1" size="26px" />
</div> </div>
</q-dialog> </q-dialog>
</div> </div>
</template> </template>
<script> <script>
import { import {
setExaminationConfigure, setExaminationConfigure,
getExaminationConfigureModel, getExaminationConfigureModel,
} from "../../api/system/exam"; } from "../../api/system/exam";
import { queryEmployee } from "../../api/users/user"; //获取业务员 import {
export default { queryEmployee
} from "../../api/users/user"; //获取业务员
export default {
meta: { meta: {
title: "考试设置", title: "考试设置",
}, },
...@@ -337,6 +268,68 @@ export default { ...@@ -337,6 +268,68 @@ export default {
}, },
//设置考试信息 //设置考试信息
setBaseInfo() { setBaseInfo() {
//都选否 直接保存
if(this.addMsg.IsOpenZuJuan==0&&this.addMsg.IsOpenExamApply==0){
setExaminationConfigure(this.addMsg).then((res) => {
if (res.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "数据保存成功!",
position: "top",
});
this.getData();
this.isShowBaseSet = false;
}
});
}
//只选择了开启组卷审批
if(this.addMsg.IsOpenZuJuan==1&&this.addMsg.IsOpenExamApply==0){
this.$refs.ZuJuanReviewer.validate();
this.addMsg.ZuJuanReviewerName = this.getName(
this.addMsg.ZuJuanReviewer
);
if(!this.$refs.ZuJuanReviewer.hasError){
setExaminationConfigure(this.addMsg).then((res) => {
if (res.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "数据保存成功!",
position: "top",
});
this.getData();
this.isShowBaseSet = false;
}
});
}
}
//组卷审批关闭 开起考试
if(this.addMsg.IsOpenZuJuan==0&&this.addMsg.IsOpenExamApply==1){
this.$refs.ExamApplyReviewer.validate();
this.addMsg.ExamApplyReviewerName = this.getName(
this.addMsg.ExamApplyReviewer
);
if(!this.$refs.ExamApplyReviewer.hasError){
setExaminationConfigure(this.addMsg).then((res) => {
if (res.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "数据保存成功!",
position: "top",
});
this.getData();
this.isShowBaseSet = false;
}
});
}
}
//组卷审批 开启考试同时打开
if(this.addMsg.IsOpenZuJuan==1&&this.addMsg.IsOpenExamApply==1){
this.$refs.ZuJuanReviewer.validate(); this.$refs.ZuJuanReviewer.validate();
this.$refs.ExamApplyReviewer.validate(); this.$refs.ExamApplyReviewer.validate();
if ( if (
...@@ -363,6 +356,7 @@ export default { ...@@ -363,6 +356,7 @@ export default {
} }
}); });
} }
}
}, },
//获取业务员 //获取业务员
getEmployee(id) { getEmployee(id) {
...@@ -406,6 +400,6 @@ export default { ...@@ -406,6 +400,6 @@ export default {
return name; return name;
}, },
}, },
}; };
</script>
</script>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment