Commit 76b8090e authored by 罗超's avatar 罗超

1

parent 370b8363
<!--考试申请信息-->
<style>
.backbill-Dialog .drawerTop {
width: 100%;
height: 50px;
display: flex;
justify-content: space-between;
background-color: #f0f5fb;
padding: 5px 10px;
align-items: center;
}
.backbill-Dialog .classFirst {
color: #000000;
font-weight: bold;
}
.backbill-Dialog .className {
margin-left: 10px;
}
.backbill-Dialog .classStatus {
padding: 3px 8px;
background-color: #c8d7fc;
color: #2961fe;
font-size: 12px;
border-radius: 2px;
margin-left: 20px;
}
.backbill-Dialog .normalName {
color: #999999;
}
.backbill-Dialog .normalInner {
color: #111111;
}
.drop_NameDown {
margin-top: 20px;
width: 300px;
}
.backinfoContent .replayReason {
width: 100%;
min-height: 100px;
background-color: #f7f7f7;
border-radius: 3px;
padding: 20px;
margin: 20px 0;
}
.backinfoContent .replay_Title {
font-weight: 700;
color: #111;
}
.backinfoContent .baseInfo_Item {
margin-bottom: 20px;
}
.backinfoContent .EmpList {
background-color: #f7f7f7;
min-height: 70px;
margin-right: 15px;
border-radius: 3px;
padding: 15px;
}
.backinfoContent .EmpList:last-child {
margin-right: 0;
}
.backinfoContent .normalName {
color: #999999;
font-size: 12px;
}
.backinfoContent .normalInner {
color: #111111;
font-weight: bold;
font-size: 13px;
margin-top: 5px;
}
.changeBTable th {
font-size: 12px;
font-weight: 400;
background-color: rgba(0, 0, 0, 0.12);
height: 40px;
line-height: 40px;
}
.changeBTable td {
text-align: center;
height: 30px;
}
.BillredClass {
color: red;
}
._addUpload_box {
display: block;
margin-top: 15px;
}
._addUpload_box img {
width: 100%;
}
._addUpload_box > div {
float: left;
width: 138px;
height: 92px;
border: 1px dashed rgba(210, 210, 210, 1);
border-radius: 2px;
cursor: pointer;
margin-bottom: 10px;
padding: 5px;
margin-right: 10px;
position: relative;
text-align: center;
}
._addUpload_box > div:hover {
background-color: #f5f5f5;
}
._addFile_name {
padding-left: 15px;
max-width: 450px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
._addUpload_box .icon-guanbi1 {
font-size: 12px;
color: white;
display: inline-block;
margin-left: 15px;
position: absolute;
right: -6px;
top: -9px;
background-color: #f56c6c;
border-radius: 50%;
height: 20px;
width: 20px;
text-align: center;
line-height: 20px;
}
._addUpload_box .icon-guanbi1:hover {
font-size: 12px;
color: #c94052;
}
._addUpload_box .icon-excel,
._addUpload_box .icon-pdf,
._addUpload_box .icon-txt,
._addUpload_box .icon-wenjian,
._addUpload_box .icon-yasuobao,
._addUpload_box .icon-shipin,
._addUpload_box .icon-word {
text-align: center;
font-size: 38px;
color: green;
line-height: 75px;
}
._addUpload_box .icon-yasuobao {
color: gray;
}
._show_img_box {
position: fixed;
background: rgba(0, 0, 0, 0.6);
left: 0;
top: 0;
width: 100%;
height: 100%;
z-index: 999;
text-align: center;
}
._addUpload_tips {
font-size: 12px;
color: #999999;
}
._jump_page {
cursor: pointer;
text-decoration: underline;
}
._jump_page:hover {
color: #c94052;
}
</style>
<template>
<q-dialog
v-model="persistent"
maximized
full-height
seamless
position="right"
@hide="closeShenheForm"
>
<q-card
style="margin-top: 61px; width: 850px"
class="no-border-radius backbill-Dialog"
>
<div class="drawerTop">
<div style="display: flex; align-items: center">
<div class="className">
<div class="classFirst">{{ changeTitle }}</div>
</div>
</div>
</div>
<q-tabs
style="margin: 15px"
v-model="tabCheck"
narrow-indicator
dense
align="left"
class="text-primary"
>
<q-tab :ripple="false" name="first" label="详细信息" />
<q-tab :ripple="false" name="second" label="审批记录" />
</q-tabs>
<div v-if="tabCheck == 'first'" style="margin: 0 15px">
<div class="backinfoContent">
<div>
<div class="topBaseInfo">
<div class="backinfo_Item">
<span class="role_Line"></span>基本信息
</div>
<div class="row backInfo_One">
<div class="col-6">
<span class="backInfo_Title">试卷名称:</span>
<span class="backOtherInfo"
>{{ setingObj.DataObj.PaperName }}
<q-btn
size="xs"
text-color="primary"
label="查看详情"
style="margin-left: 10px"
@click="goExamPaper"
flat
/></span>
</div>
<div class="col-6">
<span class="backInfo_Title">申请人:</span>
<span class="backOtherInfo">{{
setingObj.CreateByName
}}</span>
</div>
</div>
<div class="row backInfo_One">
<div class="col-12">
<span class="backInfo_Title">申请时间:</span>
<span class="backOtherInfo">{{ setingObj.CreateTime }}</span>
</div>
</div>
</div>
<div v-if="showType == 2">
<div
style="
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 20px;
"
>
<div>审批意见</div>
<div>
<q-radio
v-model="changeBillMsg.AuditStatus"
:val="2"
label="通过"
/>
<q-radio
v-model="changeBillMsg.AuditStatus"
:val="3"
label="驳回"
/>
</div>
</div>
<q-input
filled
stack-label
:dense="false"
v-model="changeBillMsg.Description"
type="textarea"
label="审批意见"
/>
</div>
<div style="margin-top: 20px">
<div class="row">
<div class="col-6" style="display: flex; align-items: top">
<template v-if="tempPeople.length > 0">
<div style="display: inline-block; width: 45px">抄送:</div>
<div
style="
display: inline-block;
margin-left: 5px;
width: 340px;
"
>
<span
class="chaosong_Peo"
v-for="(childItem, cindex) in tempPeople"
>
{{ getName(childItem) }}
</span>
</div>
</template>
</div>
<div
class="col-6"
style="
justify-content: flex-end;
display: flex;
align-items: center;
"
>
<i
class="iconfont icon-aite"
style="
font-size: 20px;
margin: 7px 20px 0 0;
cursor: pointer;
"
v-if="showType == 2"
>
<q-popup-proxy>
<q-banner>
<div style="width: 350px">
<div style="margin: 10px 0 15px 0">抄送</div>
<q-select
class="col-6 q-pb-lg q-pr-lg"
multiple
clearable
filled
stack-label
use-input
option-value="Id"
option-label="EmployeeName"
v-model="tempPeople"
ref="ManagerId"
:options="EmployeeList"
label="选择人员"
:dense="false"
emit-value
map-options
@filter="filterFn"
>
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">
未找到相关数据
</q-item-section>
</q-item>
</template>
</q-select>
</div>
</q-banner>
</q-popup-proxy>
</i>
<q-btn class="q-mr-md" label="关闭" @click="closeBackInfo" />
<q-btn
v-if="showType == 2"
color="accent q-px-md"
label="确认"
@click="saveBackClassInfo()"
/>
</div>
</div>
</div>
</div>
</div>
</div>
<div v-if="tabCheck == 'second'">
 <flowinfoForm
:seting-obj="setingObj"
:showType="showType"
@close="closeShenheForm"
@success="refreshPage"
>
</flowinfoForm>
</div>
</q-card>
<div
class="dialog-out-close"
@click="closeShenheForm"
style="
height: 40px !important;
border-top-left-radius: 4px !important;
border-bottom-left-radius: 4px !important;
"
>
<q-icon name="iconfont icon-jujue1" size="26px" />
</div>
<div
v-if="picIsShow"
class="_show_img_box"
@click="(picIsShow = false), (picObj = [])"
>
<div
style="
position: absolute;
width: 800px;
height: 600px;
left: 50%;
top: 50%;
margin-left: -400px;
transform: translateY(-50%);
"
>
<el-carousel
:initial-index="initialIndex"
height="600px"
:interval="5000"
trigger="click"
>
<el-carousel-item
style="height: 600px; overflow: auto"
v-for="(item, index) in picObj"
:key="index"
>
<img :src="item" style="" />
</el-carousel-item>
</el-carousel>
</div>
</div>
</q-dialog>
</template>
<script>
import flowinfoForm from "../sale/flowinfo-form";
import { saveBackBillAduit } from "../../api/sale/bill";
import { queryEmployee } from "../../api/users/user";
export default {
props: {
setingObj: {
type: Object,
default: null,
},
showType: {
type: Number,
default: 1,
},
},
components: {
flowinfoForm,
},
data() {
return {
persistent: true,
tabCheck: "first", //默认选第一个
loading: false,
changeBillMsg: {
Id: 0,
Description: "", //审批意见
AuditStatus: 2, //审核状态
SpecialNode: 0, //是否特殊节点
RecipientIds: "", //抄送人
},
classPriceObj: {}, //课程价格信息
EmployeeList: [],
AllemployeeList: [],
tempPeople: [], //抄送人数组
changeTitle: "考试申请",
dataList: [],
picIsShow: false,
picObj: [],
initialIndex: 0,
};
},
created() {
this.getEmployee();
},
mounted() {
this.changeBillMsg.Id = this.setingObj.Id;
this.changeBillMsg.SpecialNode = this.setingObj.SpecialNode;
},
methods: {
closeBackInfo() {
this.persistent = false;
this.$emit("close");
},
//退课单据审核
saveBackClassInfo() {
var str = "";
if (this.tempPeople && this.tempPeople.length > 0) {
this.tempPeople.forEach((item) => {
str += "," + item;
});
}
if (str && str != "") {
str = str.substr(1);
}
this.changeBillMsg.RecipientIds = str;
if (this.changeBillMsg.AuditStatus == 3) {
if (
this.changeBillMsg.Description == "" ||
!this.changeBillMsg.Description
) {
this.$q.notify({
type: "negative",
message: "请填写驳回理由",
position: "top",
timeout: 2000,
});
return;
}
this.$q
.dialog({
title: "提示信息",
message: "确定要驳回吗?",
cancel: true,
persistent: true,
ok: "确定",
cancel: "取消",
})
.onOk(() => {
saveBackBillAduit(this.changeBillMsg).then((res) => {
if (res.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "审核成功!",
position: "top",
});
//调用父页面成功方法
this.$emit("success");
this.$emit("close");
}
});
})
.onCancel(() => {});
} else {
saveBackBillAduit(this.changeBillMsg).then((res) => {
if (res.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "审核成功!",
position: "top",
});
//调用父页面成功方法
this.$emit("success");
this.$emit("close");
}
});
}
},
//获取员工列表
getEmployee() {
var qMsg = {
EmployeeName: "",
};
queryEmployee(qMsg).then((res) => {
if (res.Code == 1) {
var jsonData = res.Data;
if (jsonData && jsonData.length > 0) {
this.AllemployeeList = JSON.parse(JSON.stringify(jsonData));
this.EmployeeList = JSON.parse(JSON.stringify(jsonData));
}
}
});
},
//筛选员工
filterFn(val, update) {
update(() => {
if (val === "") {
this.EmployeeList = JSON.parse(JSON.stringify(this.AllemployeeList));
} else {
const needle = val.toLowerCase();
this.EmployeeList = this.AllemployeeList.filter(
(v) => v.EmployeeName.toLowerCase().indexOf(needle) > -1
);
}
});
},
//获取员工姓名
getName(id) {
let str = "";
this.EmployeeList.forEach((x) => {
if (id == x.Id) {
str = x.EmployeeName;
}
});
return str;
},
//跳转到班级管理
goExamPaper() {
this.OpenNewUrl("/exam/paperPublishReadonly", {
Id: this.setingObj.DataObj.Id,
});
},
refreshPage() {
this.persistent = false;
this.$emit("success");
},
closeShenheForm() {
this.persistent = false;
this.$emit("close");
},
},
};
</script>
<!--组卷审核信息-->
<style>
.backbill-Dialog .drawerTop {
width: 100%;
height: 50px;
display: flex;
justify-content: space-between;
background-color: #f0f5fb;
padding: 5px 10px;
align-items: center;
}
.backbill-Dialog .classFirst {
color: #000000;
font-weight: bold;
}
.backbill-Dialog .className {
margin-left: 10px;
}
.backbill-Dialog .classStatus {
padding: 3px 8px;
background-color: #c8d7fc;
color: #2961fe;
font-size: 12px;
border-radius: 2px;
margin-left: 20px;
}
.backbill-Dialog .normalName {
color: #999999;
}
.backbill-Dialog .normalInner {
color: #111111;
}
.drop_NameDown {
margin-top: 20px;
width: 300px;
}
.backinfoContent .replayReason {
width: 100%;
min-height: 100px;
background-color: #f7f7f7;
border-radius: 3px;
padding: 20px;
margin: 20px 0;
}
.backinfoContent .replay_Title {
font-weight: 700;
color: #111;
}
.backinfoContent .baseInfo_Item {
margin-bottom: 20px;
}
.backinfoContent .EmpList {
background-color: #f7f7f7;
min-height: 70px;
margin-right: 15px;
border-radius: 3px;
padding: 15px;
}
.backinfoContent .EmpList:last-child {
margin-right: 0;
}
.backinfoContent .normalName {
color: #999999;
font-size: 12px;
}
.backinfoContent .normalInner {
color: #111111;
font-weight: bold;
font-size: 13px;
margin-top: 5px;
}
.changeBTable th {
font-size: 12px;
font-weight: 400;
background-color: rgba(0, 0, 0, 0.12);
height: 40px;
line-height: 40px;
}
.changeBTable td {
text-align: center;
height: 30px;
}
.BillredClass {
color: red;
}
._addUpload_box {
display: block;
margin-top: 15px;
}
._addUpload_box img {
width: 100%;
}
._addUpload_box > div {
float: left;
width: 138px;
height: 92px;
border: 1px dashed rgba(210, 210, 210, 1);
border-radius: 2px;
cursor: pointer;
margin-bottom: 10px;
padding: 5px;
margin-right: 10px;
position: relative;
text-align: center;
}
._addUpload_box > div:hover {
background-color: #f5f5f5;
}
._addFile_name {
padding-left: 15px;
max-width: 450px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
._addUpload_box .icon-guanbi1 {
font-size: 12px;
color: white;
display: inline-block;
margin-left: 15px;
position: absolute;
right: -6px;
top: -9px;
background-color: #f56c6c;
border-radius: 50%;
height: 20px;
width: 20px;
text-align: center;
line-height: 20px;
}
._addUpload_box .icon-guanbi1:hover {
font-size: 12px;
color: #c94052;
}
._addUpload_box .icon-excel,
._addUpload_box .icon-pdf,
._addUpload_box .icon-txt,
._addUpload_box .icon-wenjian,
._addUpload_box .icon-yasuobao,
._addUpload_box .icon-shipin,
._addUpload_box .icon-word {
text-align: center;
font-size: 38px;
color: green;
line-height: 75px;
}
._addUpload_box .icon-yasuobao {
color: gray;
}
._show_img_box {
position: fixed;
background: rgba(0, 0, 0, 0.6);
left: 0;
top: 0;
width: 100%;
height: 100%;
z-index: 999;
text-align: center;
}
._addUpload_tips {
font-size: 12px;
color: #999999;
}
._jump_page {
cursor: pointer;
text-decoration: underline;
}
._jump_page:hover {
color: #c94052;
}
</style>
<template>
<q-dialog
v-model="persistent"
maximized
full-height
seamless
position="right"
@hide="closeShenheForm"
>
<q-card
style="margin-top: 61px; width: 850px"
class="no-border-radius backbill-Dialog"
>
<div class="drawerTop">
<div style="display: flex; align-items: center">
<div class="className">
<div class="classFirst">{{ changeTitle }}</div>
</div>
</div>
</div>
<q-tabs
style="margin: 15px"
v-model="tabCheck"
narrow-indicator
dense
align="left"
class="text-primary"
>
<q-tab :ripple="false" name="first" label="详细信息" />
<q-tab :ripple="false" name="second" label="审批记录" />
</q-tabs>
<div v-if="tabCheck == 'first'" style="margin: 0 15px">
<div class="backinfoContent">
<div>
<div class="topBaseInfo">
<div class="backinfo_Item">
<span class="role_Line"></span>基本信息
</div>
<div class="row backInfo_One">
<div class="col-6">
<span class="backInfo_Title">试卷名称:</span>
<span class="backOtherInfo"
>{{ setingObj.DataObj.PaperName }}
<q-btn
size="xs"
text-color="primary"
label="查看详情"
style="margin-left: 10px"
@click="goExamPaper"
flat
/></span>
</div>
<div class="col-6">
<span class="backInfo_Title">申请人:</span>
<span class="backOtherInfo">{{
setingObj.CreateByName
}}</span>
</div>
</div>
<div class="row backInfo_One">
<div class="col-12">
<span class="backInfo_Title">申请时间:</span>
<span class="backOtherInfo">{{ setingObj.CreateTime }}</span>
</div>
</div>
</div>
<div v-if="showType == 2">
<div
style="
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 20px;
"
>
<div>审批意见</div>
<div>
<q-radio
v-model="changeBillMsg.AuditStatus"
:val="2"
label="通过"
/>
<q-radio
v-model="changeBillMsg.AuditStatus"
:val="3"
label="驳回"
/>
</div>
</div>
<q-input
filled
stack-label
:dense="false"
v-model="changeBillMsg.Description"
type="textarea"
label="审批意见"
/>
</div>
<div style="margin-top: 20px">
<div class="row">
<div class="col-6" style="display: flex; align-items: top">
<template v-if="tempPeople.length > 0">
<div style="display: inline-block; width: 45px">抄送:</div>
<div
style="
display: inline-block;
margin-left: 5px;
width: 340px;
"
>
<span
class="chaosong_Peo"
v-for="(childItem, cindex) in tempPeople"
>
{{ getName(childItem) }}
</span>
</div>
</template>
</div>
<div
class="col-6"
style="
justify-content: flex-end;
display: flex;
align-items: center;
"
>
<i
class="iconfont icon-aite"
style="
font-size: 20px;
margin: 7px 20px 0 0;
cursor: pointer;
"
v-if="showType == 2"
>
<q-popup-proxy>
<q-banner>
<div style="width: 350px">
<div style="margin: 10px 0 15px 0">抄送</div>
<q-select
class="col-6 q-pb-lg q-pr-lg"
multiple
clearable
filled
stack-label
use-input
option-value="Id"
option-label="EmployeeName"
v-model="tempPeople"
ref="ManagerId"
:options="EmployeeList"
label="选择人员"
:dense="false"
emit-value
map-options
@filter="filterFn"
>
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">
未找到相关数据
</q-item-section>
</q-item>
</template>
</q-select>
</div>
</q-banner>
</q-popup-proxy>
</i>
<q-btn class="q-mr-md" label="关闭" @click="closeBackInfo" />
<q-btn
v-if="showType == 2"
color="accent q-px-md"
label="确认"
@click="saveBackClassInfo()"
/>
</div>
</div>
</div>
</div>
</div>
</div>
<div v-if="tabCheck == 'second'">
 <flowinfoForm
:seting-obj="setingObj"
:showType="showType"
@close="closeShenheForm"
@success="refreshPage"
>
</flowinfoForm>
</div>
</q-card>
<div
class="dialog-out-close"
@click="closeShenheForm"
style="
height: 40px !important;
border-top-left-radius: 4px !important;
border-bottom-left-radius: 4px !important;
"
>
<q-icon name="iconfont icon-jujue1" size="26px" />
</div>
<div
v-if="picIsShow"
class="_show_img_box"
@click="(picIsShow = false), (picObj = [])"
>
<div
style="
position: absolute;
width: 800px;
height: 600px;
left: 50%;
top: 50%;
margin-left: -400px;
transform: translateY(-50%);
"
>
<el-carousel
:initial-index="initialIndex"
height="600px"
:interval="5000"
trigger="click"
>
<el-carousel-item
style="height: 600px; overflow: auto"
v-for="(item, index) in picObj"
:key="index"
>
<img :src="item" style="" />
</el-carousel-item>
</el-carousel>
</div>
</div>
</q-dialog>
</template>
<script>
import flowinfoForm from "../sale/flowinfo-form";
import { saveBackBillAduit } from "../../api/sale/bill";
import { queryEmployee } from "../../api/users/user";
export default {
props: {
setingObj: {
type: Object,
default: null,
},
showType: {
type: Number,
default: 1,
},
},
components: {
flowinfoForm,
},
data() {
return {
persistent: true,
tabCheck: "first", //默认选第一个
loading: false,
changeBillMsg: {
Id: 0,
Description: "", //审批意见
AuditStatus: 2, //审核状态
SpecialNode: 0, //是否特殊节点
RecipientIds: "", //抄送人
},
classPriceObj: {}, //课程价格信息
EmployeeList: [],
AllemployeeList: [],
tempPeople: [], //抄送人数组
changeTitle: "组卷审批",
dataList: [],
picIsShow: false,
picObj: [],
initialIndex: 0,
};
},
computed: {
fj() {
let arr = [];
let fjlist = this.setingObj.ReceiptFileList;
fjlist.map((item) => {
let suffix = item.split(".")[item.split(".").length - 1].toUpperCase();
if ("DOCX|DOC|XLSX|XLS|PPT|PPTX|PDF|TXT".indexOf(suffix) != "-1") {
let obj = {
url: item,
type: 1,
suffix: suffix,
};
arr.push(obj);
} else if ("GIF|JPG|JPEG|PNG|BMP|WEBP".indexOf(suffix) != "-1") {
let obj = {
url: item,
type: 2,
suffix: suffix,
};
arr.push(obj);
} else if ("ZIP|RAR|7Z|TAR".indexOf(suffix) != "-1") {
let obj = {
url: item,
type: 3,
suffix: suffix,
};
arr.push(obj);
} else if (
"MP4|3GP|AVI|MOV|WMV|RMVB|MKV|M4V|FLV".indexOf(suffix) != "-1"
) {
let obj = {
url: item,
type: 4,
suffix: suffix,
};
arr.push(obj);
} else {
let obj = {
url: item,
type: 5,
suffix: suffix,
};
arr.push(obj);
}
});
return arr;
},
},
created() {
this.getEmployee();
},
mounted() {
this.changeBillMsg.Id = this.setingObj.Id;
this.changeBillMsg.SpecialNode = this.setingObj.SpecialNode;
},
methods: {
closeBackInfo() {
this.persistent = false;
this.$emit("close");
},
//退课单据审核
saveBackClassInfo() {
var str = "";
if (this.tempPeople && this.tempPeople.length > 0) {
this.tempPeople.forEach((item) => {
str += "," + item;
});
}
if (str && str != "") {
str = str.substr(1);
}
this.changeBillMsg.RecipientIds = str;
if (this.changeBillMsg.AuditStatus == 3) {
if (
this.changeBillMsg.Description == "" ||
!this.changeBillMsg.Description
) {
this.$q.notify({
type: "negative",
message: "请填写驳回理由",
position: "top",
timeout: 2000,
});
return;
}
this.$q
.dialog({
title: "提示信息",
message: "确定要驳回吗?",
cancel: true,
persistent: true,
ok: "确定",
cancel: "取消",
})
.onOk(() => {
saveBackBillAduit(this.changeBillMsg).then((res) => {
if (res.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "审核成功!",
position: "top",
});
//调用父页面成功方法
this.$emit("success");
this.$emit("close");
}
});
})
.onCancel(() => {});
} else {
saveBackBillAduit(this.changeBillMsg).then((res) => {
if (res.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "审核成功!",
position: "top",
});
//调用父页面成功方法
this.$emit("success");
this.$emit("close");
}
});
}
},
//获取员工列表
getEmployee() {
var qMsg = {
EmployeeName: "",
};
queryEmployee(qMsg).then((res) => {
if (res.Code == 1) {
var jsonData = res.Data;
if (jsonData && jsonData.length > 0) {
this.AllemployeeList = JSON.parse(JSON.stringify(jsonData));
this.EmployeeList = JSON.parse(JSON.stringify(jsonData));
}
}
});
},
//筛选员工
filterFn(val, update) {
update(() => {
if (val === "") {
this.EmployeeList = JSON.parse(JSON.stringify(this.AllemployeeList));
} else {
const needle = val.toLowerCase();
this.EmployeeList = this.AllemployeeList.filter(
(v) => v.EmployeeName.toLowerCase().indexOf(needle) > -1
);
}
});
},
//获取员工姓名
getName(id) {
let str = "";
this.EmployeeList.forEach((x) => {
if (id == x.Id) {
str = x.EmployeeName;
}
});
return str;
},
//跳转到班级管理
goExamPaper() {
this.OpenNewUrl("/exam/paperInfo", {
Id: this.setingObj.DataObj.PaperId,
});
},
refreshPage() {
this.persistent = false;
this.$emit("success");
},
closeShenheForm() {
this.persistent = false;
this.$emit("close");
},
},
};
</script>
<!--组卷-->
<style>
.examCreat_Top {
width: 100%;
height: 30px;
line-height: 30px;
padding: 0 10px;
margin-bottom: 20px;
border-bottom: 1px solid #ddd;
}
.examTi_List {
border: 1px solid #ddd;
margin-bottom: 20px;
}
.examCreat_Top i:hover {
color: red;
cursor: pointer;
}
.setCt {
margin-bottom: 12px;
}
.setCt:after {
content: "020";
display: block;
height: 0;
clear: both;
visibility: hidden;
}
.papPub_Left {
display: inline-block;
width: 104px;
line-height: 34px;
}
.f1 {
float: left;
}
.pcomRow {
align-items: center;
}
.selectClass {
width: 1026px;
border: 1px dashed #e1e1e5;
padding-top: 12px;
border-radius: 4px;
padding: 12px 4px 0 4px;
margin-top: 5px;
}
.selectClass span {
display: inline-block;
background: #f2f5fa;
padding: 0 10px;
height: 26px;
line-height: 26px;
border-radius: 14px;
color: #181e33;
margin-left: 10px;
margin-bottom: 12px;
position: relative;
font-size: 12px;
cursor: pointer;
}
.selectClass span i {
position: absolute;
right: -8px;
top: -10px;
display: none;
color: gray;
cursor: pointer;
}
.selectClass span:hover i {
display: block;
}
.paper_QuesDes {
font-size: 12px;
color: #a8a8b3;
display: block;
margin: 0 0 15px 28px;
}
#paper_Publish {
padding-left: 60px !important;
}
#paper_Publish .edui-editor {
z-index: 99 !important;
}
</style>
<template>
<div class="page-body" id="paper_Publish">
<div style="margin: 5px 0 10px 0; font-size: 20px">考试详情</div>
<div class="setCt">
<span class="papPub_Left f1">发放对象</span>
<div class="f1" style="margin-top: 5px">
<!-- <q-btn color="accent" size="sm" @click="showClassStu" class="q-mr-md" label="选择学员"  /><br /> -->
<div
class="selectClass"
v-if="postMsg.StudentList && postMsg.StudentList.length > 0"
>
<span
v-for="(item, index) in postMsg.StudentList"
:key="index"
style="padding-left: 5px"
>{{ item.GuestName }}
<i
class="iconfont icon-shanchu1"
@click="delStudentName(index)"
></i>
</span>
</div>
</div>
</div>
<div class="setCt">
<span class="papPub_Left f1">发放时间</span>
<div class="f1">
<q-input
filled
v-model="postMsg.ExamStartTime"
style="width: 308px"
mask="####-##-## ##:##:##"
label="开始时间"
ref="StartTime"
disable
:rules="[(val) => !!val || '请选择开始时间']"
>
<template v-slot:append>
<q-icon name="event" class="cursor-pointer">
<q-popup-proxy
ref="qDateProxy"
transition-show="scale"
transition-hide="scale"
>
<div class="q-gutter-md row items-start">
<q-date
v-model="postMsg.ExamStartTime"
mask="YYYY-MM-DD HH:mm:ss"
></q-date>
<q-time
v-model="postMsg.ExamStartTime"
format24h
mask="YYYY-MM-DD HH:mm:ss"
/>
</div>
<q-btn
v-close-popup
label="关闭"
color="primary"
flat
style="float: right"
/>
</q-popup-proxy>
</q-icon>
</template>
</q-input>
</div>
</div>
<div class="setCt">
<span class="papPub_Left f1">结束时间</span>
<div class="f1">
<q-input
filled
v-model="postMsg.ExamEndTime"
style="width: 308px"
mask="####-##-## ##:##:##"
label="结束时间"
ref="ExamEndTime"
disable
:rules="[(val) => !!val || '请选择结束时间']"
>
<template v-slot:append>
<q-icon name="event" class="cursor-pointer">
<q-popup-proxy
ref="qDateProxy2"
transition-show="scale"
transition-hide="scale"
>
<div class="q-gutter-md row items-start">
<q-date
v-model="postMsg.ExamEndTime"
mask="YYYY-MM-DD HH:mm:ss"
></q-date>
<q-time
v-model="postMsg.ExamEndTime"
format24h
mask="YYYY-MM-DD HH:mm:ss"
/>
</div>
<q-btn
v-close-popup
label="关闭"
color="primary"
flat
style="float: right"
/>
</q-popup-proxy>
</q-icon>
</template>
</q-input>
</div>
</div>
<div class="setCt">
<span class="papPub_Left f1">考试限时</span>
<div class="f1">
<q-input
filled
bottom-slots
maxlength="10"
style="width: 308px"
v-model="postMsg.ExamTimes"
label="考试限时"
:dense="false"
disable
>
<template v-slot:append>
<span style="font-size: 12px">分钟</span>
</template>
</q-input>
</div>
</div>
<div class="setCt">
<span class="papPub_Left f1">限时提交</span>
<div class="f1">
<q-input
filled
bottom-slots
maxlength="10"
style="width: 308px"
v-model="postMsg.SubmitTimes"
label="限时提交"
:dense="false"
disable
>
<template v-slot:append>
<span style="font-size: 12px">分钟内不允许提交</span>
</template>
</q-input>
</div>
</div>
<div class="setCt">
<span class="papPub_Left f1">限时进入</span>
<div class="f1">
<q-input
filled
bottom-slots
maxlength="10"
v-model="postMsg.EnterTimes"
label="限时进入"
:dense="false"
disable
>
<template v-slot:append>
<span style="font-size: 12px">分钟后不允许参加考试</span>
</template>
</q-input>
</div>
</div>
<div class="setCt">
<span class="papPub_Left f1">防作弊设置</span>
<div class="f1">
<q-checkbox
size="xs"
v-model="postMsg.IsQuestionRandom"
:true-value="1"
:false-value="0"
label="题目乱序"
disable
/>
<div class="paper_QuesDes">学生接收到的题目显示顺序不同</div>
<q-checkbox
size="xs"
v-model="postMsg.IsOptionRandom"
:true-value="1"
:false-value="0"
label="选项乱序"
disable
/>
<div class="paper_QuesDes">学生接收到的题目选项顺序不同</div>
<q-checkbox
size="xs"
v-model="postMsg.IsLeaveAnswer"
:true-value="1"
:false-value="0"
label="学生离开作答页面"
disable
/>
<template>
<span style="position: relative; top: 2px">
&nbsp;<el-input
style="width: 80px"
size="small"
v-model="postMsg.LeaveTimes"
@keyup.native="checkInteger(postMsg, 'LeaveTimes')"
maxlength="5"
disabled
></el-input>
&nbsp;次,系统强制收卷
</span>
</template>
<div class="paper_QuesDes">
系统强制收卷后,教师重新发放试卷,学生可以继续作答
</div>
<div style="margin-bottom: 15px">
<q-checkbox
size="xs"
v-model="postMsg.IsDisableMultiTerminal"
:true-value="1"
:false-value="0"
label="禁止学生多终端考试"
disable
/>
</div>
<q-checkbox
size="xs"
v-model="postMsg.IsExamType"
:true-value="1"
:false-value="0"
label="只允许"
disable
/>
<template>
<span style="position: relative; top: 2px">
&nbsp;<el-select
style="width: 80px"
size="small"
v-model="postMsg.ExamTypeValue"
disabled
>
<el-option :value="1" label="App"></el-option>
<el-option :value="2" label="PC"></el-option>
</el-select>
&nbsp;考试
</span>
</template>
</div>
</div>
<div class="setCt">
<span class="papPub_Left f1">考试须知</span>
<UeEditor
v-model="postMsg.ExamNotice"
:config="config"
style="margin: 30px 0 0 110px; z-index: 1; width: 1026px"
ref="UE_Title"
disabled
></UeEditor>
</div>
<div style="margin: 20px 0">高级设置</div>
<div class="setCt">
<span class="papPub_Left f1">交卷设置</span>
<q-checkbox
size="xs"
v-model="postMsg.IsAutoSubmit"
:true-value="1"
:false-value="0"
label="考试到达截止时间后自动提交"
disable
/>
</div>
<div class="setCt">
<span class="papPub_Left f1">评分设置</span>
<div class="f1">
<q-checkbox
size="xs"
v-model="postMsg.FillInIsSubject"
:true-value="1"
:false-value="0"
label="填空类型的题目设为主观题"
disable
/>
<div class="paper_QuesDes">
填空题类型的包括填空题、分录题、资料题,设为主观题后需教师手动批阅
</div>
<q-checkbox
size="xs"
v-model="postMsg.FillInIsIgnore"
:true-value="1"
:false-value="0"
label="填空题答案不区分大小写"
disable
/>
<div class="paper_QuesDes">勾选后,英文大写和小写都可以得分</div>
<q-checkbox
size="xs"
v-model="postMsg.IsHalfScore"
:true-value="1"
:false-value="0"
label="多选题未选全给一半分"
disable
/>
<div class="paper_QuesDes">不勾选时全选对才给分</div>
</div>
</div>
<div class="row">
<!-- <q-btn
color="accent"
@click="setPublishExam"
class="q-mr-md"
label="发布考试"
disable
/> -->
</div>
<classstutreeForm
v-if="isShowClassStu"
@close="closeClassStuForm"
@success="getClassStuList"
>
</classstutreeForm>
</div>
</template>
<script>
import UeEditor from "../../components/editor/UeEditor";
import classstutreeForm from "../../components/exam/classstutree-form";
import { savePublishExam, queryExamPublish } from "../../api/teacher/index";
export default {
components: {
classstutreeForm,
UeEditor,
},
meta: {
title: "发布考试",
},
data() {
return {
postMsg: {
Id: 0, //发布编号
PaperId: 0, //试卷编号
PublishType: 1, // 发放类型(1-按班级发放,2-指定学生发放)
ExamStartTime: "2021-08-20 10:00:00", //考试开始时间
ExamEndTime: "2021-08-20 12:00:00", //考试结束时间
ExamTimes: 0, //考试限时
SubmitTimes: 0, //限时提交(多少分钟内不允许提交)
EnterTimes: 0, //限时进入(多少分钟后不允许参加考试)
IsQuestionRandom: 0, //题目乱序(1-是)
IsOptionRandom: 0, //选项乱序(1-是)
IsLeaveAnswer: 0, //学生离开作答页面(1-是)
LeaveTimes: 0, //离开次数
IsDisableMultiTerminal: 0, //是否禁用多终端(1-是)
IsExamType: 0, //是否只允许(App、PC)考试(1-是)
ExamTypeValue: 1, //考试终端类型(1-App,2-PC)
ExamNotice: "", //考试须知
PassScore: 0, //及格分数
IsAutoSubmit: 1, //考试到达截止时间后自动提交(1-是)
FillInIsSubject: 0, //填空类型的题目设为主观题(1-是)
FillInIsIgnore: 0, //填空题答案不区分大小写(1-是)
IsHalfScore: 1, //多选题未选全给一半分(1-是)
StudentList: [],
},
config: {
initialFrameWidth: null,
initialFrameHeight: 80,
},
isShowClassStu: false, //是否显示学员弹窗
};
},
created() {
if (this.$route.query && this.$route.query.PaperId) {
this.postMsg.PaperId = decodeURI(this.$route.query.PaperId);
}
if (this.$route.query && this.$route.query.Id) {
this.postMsg.Id = decodeURI(this.$route.query.Id);
this.getExamInfo();
}
},
mounted() {},
methods: {
//删除发放对象
delStudentName(index) {
this.postMsg.StudentList.splice(index, 1);
},
getExamInfo() {
queryExamPublish({
Id: this.postMsg.Id,
}).then((res) => {
console.log("res", res);
if (res.Code == 1) {
var tempData = res.Data;
if (tempData) {
this.postMsg.Id = tempData.Id;
this.postMsg.PaperId = tempData.PaperId;
this.postMsg.PublishType = tempData.PublishType;
this.postMsg.ExamStartTime = tempData.ExamStartTime;
this.postMsg.ExamEndTime = tempData.ExamEndTime;
this.postMsg.ExamTimes = tempData.ExamTimes;
this.postMsg.SubmitTimes = tempData.SubmitTimes;
this.postMsg.EnterTimes = tempData.EnterTimes;
this.postMsg.IsQuestionRandom = tempData.IsQuestionRandom;
this.postMsg.IsOptionRandom = tempData.IsOptionRandom;
this.postMsg.IsLeaveAnswer = tempData.IsLeaveAnswer;
this.postMsg.LeaveTimes = tempData.LeaveTimes;
this.postMsg.IsDisableMultiTerminal =
tempData.IsDisableMultiTerminal;
this.postMsg.IsExamType = tempData.IsExamType;
this.postMsg.ExamTypeValue = tempData.ExamTypeValue;
this.postMsg.ExamNotice = tempData.ExamNotice;
this.postMsg.PassScore = tempData.PassScore;
this.postMsg.IsAutoSubmit = tempData.IsAutoSubmit;
this.postMsg.FillInIsSubject = tempData.FillInIsSubject;
this.postMsg.FillInIsIgnore = tempData.FillInIsIgnore;
this.postMsg.IsHalfScore = tempData.IsHalfScore;
if (tempData.StudentList && tempData.StudentList.length > 0) {
this.postMsg.StudentList = tempData.StudentList;
}
}
}
});
},
//显示班级学员弹窗
showClassStu() {
this.isShowClassStu = true;
},
//关闭班级学员弹窗
closeClassStuForm() {
this.isShowClassStu = false;
},
//获取选中的需要列表
getClassStuList(array) {
if (array && array.length > 0) {
array.forEach((item) => {
this.postMsg.StudentList.push({
GuestId: item.GuestId,
ClassId: item.ClassId,
OrderId: item.OrderId,
CourseId: item.CourseId,
GuestName: item.Name,
});
});
}
this.isShowClassStu = false;
},
//发布考试
setPublishExam() {
savePublishExam(this.postMsg).then((res) => {
if (res.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "操作成功!",
position: "top",
});
this.$router.push({
path: "/exam/examlist",
query: {},
});
} else {
this.$q.notify({
type: "negative",
position: "top",
message: `操作失败!`,
});
}
});
},
},
};
</script>
...@@ -154,14 +154,14 @@ ...@@ -154,14 +154,14 @@
<span v-if="baseObj.IsOpenExamApply === 0"></span> <span v-if="baseObj.IsOpenExamApply === 0"></span>
</div> </div>
</div> </div>
<div class="Period_Spreate"> <div class="Period_Spreate" v-if="baseObj.IsOpenZuJuan === 1">
<div class="Period-rule-title">组卷审核人</div> <div class="Period-rule-title">组卷审核人</div>
<div> <div>
{{ baseObj.ZuJuanReviewerName }} {{ baseObj.ZuJuanReviewerName }}
</div> </div>
</div> </div>
</div> </div>
<div class="Period-rules"> <div class="Period-rules" v-if="baseObj.IsOpenExamApply === 1">
<div class="Period_Spreate"> <div class="Period_Spreate">
<div class="Period-rule-title">考试申请审核人</div> <div class="Period-rule-title">考试申请审核人</div>
<div>{{ baseObj.ExamApplyReviewerName }}</div> <div>{{ baseObj.ExamApplyReviewerName }}</div>
...@@ -193,7 +193,7 @@ ...@@ -193,7 +193,7 @@
></el-switch> ></el-switch>
</div> </div>
<div class="examConfig_title"> <div class="examConfig_title">
是否开启组卷审批 是否开启自动阅卷
<el-switch <el-switch
style="margin-left: 10px" style="margin-left: 10px"
v-model="addMsg.IsOpenAutoMarking" v-model="addMsg.IsOpenAutoMarking"
...@@ -204,7 +204,7 @@ ...@@ -204,7 +204,7 @@
></el-switch> ></el-switch>
</div> </div>
<div class="examConfig_title"> <div class="examConfig_title">
是否开启组卷审批 是否开启考试申请
<el-switch <el-switch
style="margin-left: 10px" style="margin-left: 10px"
v-model="addMsg.IsOpenExamApply" v-model="addMsg.IsOpenExamApply"
...@@ -215,7 +215,7 @@ ...@@ -215,7 +215,7 @@
></el-switch> ></el-switch>
</div> </div>
<div> <div v-if="baseObj.IsOpenZuJuan === 1">
<q-select <q-select
filled filled
stack-label stack-label
...@@ -241,7 +241,7 @@ ...@@ -241,7 +241,7 @@
</template> </template>
</q-select> </q-select>
</div> </div>
<div> <div v-if="baseObj.IsOpenExamApply === 1">
<q-select <q-select
filled filled
stack-label stack-label
......
...@@ -275,6 +275,22 @@ ...@@ -275,6 +275,22 @@
@close="closeBillForm" @close="closeBillForm"
@success="refreshPage" @success="refreshPage"
></leaveBillForm> ></leaveBillForm>
<!-- 组卷审批 -->
<zujuanBillForm
v-if="isShowZujuanBillForm"
:seting-obj="billObj"
:showType="showType"
@close="closeBillForm"
@success="refreshPage"
></zujuanBillForm>
<!-- 考试申请 -->
<examBillForm
v-if="isShowExamBillForm"
:seting-obj="billObj"
:showType="showType"
@close="closeBillForm"
@success="refreshPage"
></examBillForm>
</div> </div>
</div> </div>
</template> </template>
...@@ -292,6 +308,8 @@ import createbackbillForm from "../../components/sale/createbackbill-form"; ...@@ -292,6 +308,8 @@ import createbackbillForm from "../../components/sale/createbackbill-form";
import ordertransForm from "../../components/sale/ordertrans-form"; import ordertransForm from "../../components/sale/ordertrans-form";
import temporaryClassForm from "../../components/sale/temporaryClassbill-form"; import temporaryClassForm from "../../components/sale/temporaryClassbill-form";
import leaveBillForm from "../../components/sale/leavebill-form.vue"; import leaveBillForm from "../../components/sale/leavebill-form.vue";
import zujuanBillForm from "../../components/sale/zujuanbill-form.vue";
import examBillForm from "../../components/sale/exambill-form.vue";
export default { export default {
meta: { meta: {
title: "业务单据", title: "业务单据",
...@@ -304,6 +322,8 @@ export default { ...@@ -304,6 +322,8 @@ export default {
ordertransForm, ordertransForm,
temporaryClassForm, temporaryClassForm,
leaveBillForm, leaveBillForm,
zujuanBillForm,
examBillForm,
}, },
data() { data() {
return { return {
...@@ -395,6 +415,8 @@ export default { ...@@ -395,6 +415,8 @@ export default {
isShowClassTrans: false, //是否显示订单转班详情 isShowClassTrans: false, //是否显示订单转班详情
isShowTemporaryClass: false, //是否显示临时上课邀请订单详情 isShowTemporaryClass: false, //是否显示临时上课邀请订单详情
isShowLeaveBillForm: false, //是否显示请假申请单详情 isShowLeaveBillForm: false, //是否显示请假申请单详情
isShowZujuanBillForm: false, //是否显示组卷申请单详情
isShowExamBillForm: false, //是否显示考试申请详情
}; };
}, },
created() { created() {
...@@ -443,6 +465,8 @@ export default { ...@@ -443,6 +465,8 @@ export default {
this.isShowClassTrans = false; this.isShowClassTrans = false;
this.isShowTemporaryClass = false; this.isShowTemporaryClass = false;
this.isShowLeaveBillForm = false; this.isShowLeaveBillForm = false;
this.isShowZujuanBillForm = false;
this.isShowExamBillForm = false;
this.billObj = {}; this.billObj = {};
}, },
//显示表单 //显示表单
...@@ -471,6 +495,14 @@ export default { ...@@ -471,6 +495,14 @@ export default {
else if (item.ReceiptType == 7) { else if (item.ReceiptType == 7) {
this.isShowLeaveBillForm = true; this.isShowLeaveBillForm = true;
} }
//组卷
else if (item.ReceiptType == 8) {
this.isShowZujuanBillForm = true;
}
//考试申请
else if (item.ReceiptType == 9) {
this.isShowExamBillForm = true;
}
this.showType = type; this.showType = type;
this.billObj = item; this.billObj = item;
}, },
...@@ -515,6 +547,8 @@ export default { ...@@ -515,6 +547,8 @@ export default {
this.isShowStopBillForm = false; this.isShowStopBillForm = false;
this.isShowClassTrans = false; this.isShowClassTrans = false;
this.isShowLeaveBillForm = false; this.isShowLeaveBillForm = false;
this.isShowZujuanBillForm = false;
this.isShowExamBillForm = false;
this.billObj = {}; this.billObj = {};
this.getStuBackBill(); this.getStuBackBill();
}, },
......
...@@ -1072,6 +1072,11 @@ const routes = [{ ...@@ -1072,6 +1072,11 @@ const routes = [{
component: () => component: () =>
import("pages/exam/paperPublish") import("pages/exam/paperPublish")
}, },
{
path: "/exam/paperPublishReadonly", //试卷发布考试-只读
component: () =>
import("pages/exam/paperPublishReadonly")
},
{ {
path: "/exam/examineeManager", //试卷-考生管理 path: "/exam/examineeManager", //试卷-考生管理
component: () => component: () =>
......
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