Merge remote-tracking branch 'origin/develop' into develop

This commit is contained in:
yuping
2022-12-06 16:57:24 +08:00
13 changed files with 617 additions and 776 deletions

View File

@@ -51,12 +51,12 @@
<div class="qrmbtn" @click="downloadQr(200)">
<div class="btntext">200*200</div>
</div>
<div class="qrmbtn" @click="downloadQr(200)">
<!-- <div class="qrmbtn" @click="downloadQr(200)">
<div class="btntext">400*400</div>
</div>
<div class="qrmbtn" @click="downloadQr(200)">
<div class="btntext">800*800</div>
</div>
</div> -->
</div>
</div>
</div>

View File

@@ -47,13 +47,13 @@
<div class="main_table">
<a-table
v-if="edit"
v-if="edit"
class="ant-table-striped"
:row-class-name="
(_record, index) => (index % 2 === 1 ? 'table-striped' : null)
"
:row-selection="{
type:'radio',
type: 'radio',
selectedRowKeys: selectedRowKeys,
onChange: onSelectChange,
}"
@@ -63,7 +63,7 @@
:pagination="false"
/>
<a-table
v-else
v-else
class="ant-table-striped"
:row-class-name="
(_record, index) => (index % 2 === 1 ? 'table-striped' : null)
@@ -79,7 +79,7 @@
/>
<div class="pa">
<a-pagination
v-if="tableDataTotal>10"
v-if="tableDataTotal > 10"
showSizeChanger="true"
showQuickJumper="true"
hideOnSinglePage="true"
@@ -216,7 +216,7 @@ export default {
state.apiTaskList = selectedRows;
};
const handelChangePage = (page, pageSize) => {
state.selectedRowKeys = []
state.selectedRowKeys = [];
state.currentPage = page;
state.pageSize = pageSize;
getAllCaseText();
@@ -224,7 +224,7 @@ export default {
const getTableDate = (tableData) => {
let data = tableData;
let array = [];
data.map((value, index) => {
data.map((value, index) => {
let obj = {
key: index,
authorId: value.authorId,
@@ -251,15 +251,20 @@ export default {
isTop: "",
})
.then((res) => {
console.log('案例列表',res)
if (res.status === 200) {
state.selectedRowKeys=[0]
for(let i=0;i<res.data.data.length;i++){
if(Number(res.data.data[i].casesId) == props.EditCaseId){
state.selectedRowKeys = [i]
console.log("案例列表", res);
if (res.data.code === 200) {
// state.selectedRowKeys = [0];
for (let i = 0; i < res.data.data.list.length; i++) {
console.log(
"res.data.data.list[i].casesId",
res.data.data.list[i].casesId,
props.EditCaseId
);
if (Number(res.data.data.list[i].casesId) == props.EditCaseId) {
state.selectedRowKeys = [i];
}
}
getTableDate(res.data.data);
getTableDate(res.data.data.list);
}
})
.catch(() => {});
@@ -334,25 +339,25 @@ export default {
}
};
//搜索案例列表
const searchList = ()=> {
if(state.inputV1 !== ''){
getAllCaseText()
}else {
resetCase()
const searchList = () => {
if (state.inputV1 !== "") {
getAllCaseText();
} else {
resetCase();
}
}
};
//重置案例信息
const resetCase = () => {
state.inputV1 = ""
state.selectedRowKeys=[]
state.currentPage = 1
state.inputV1 = "";
state.selectedRowKeys = [];
state.currentPage = 1;
getAllCaseText();
};
onMounted(()=>{
onMounted(() => {
// let cookie =
// "eyJ0eXBlIjoidG9rZW4iLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwOlwvXC91LmJvZS5jb20iLCJpYXQiOjE2Njk0MjgwNTAsImV4cCI6MTY2OTQzNTI1MCwiR2l2ZW5OYW1lIjoiYm9ldSIsInVzZXJJZCI6IjZCMDQ5RkFGLUMzMTQtN0NDRi0wRDI4LTBEMjNGNEM0MjUzMSIsInVJZCI6Ijk2NTM0MjAyNzQ5NzYwNzE2OCIsInBlcm1pc3Npb24iOiIifQ==.9ea5ce6d4cd43c2c17f21a293e4dc0d362c2a404b9d50fae5c49fed5a238fb1a";
// setCookie("token", cookie, 10);
})
});
return {
...toRefs(state),
afterVisibleChange,

View File

@@ -1,18 +1,18 @@
<template>
<a-drawer
:visible="addtestVisible"
class="drawerStyle addtestDrawer"
width="80%"
placement="right"
@after-visible-change="afterVisibleChange"
:visible="addtestVisible"
class="drawerStyle addtestDrawer"
width="80%"
placement="right"
@after-visible-change="afterVisibleChange"
>
<div class="drawerMain">
<div class="header">
<div class="headerTitle">{{ edit ? "编辑" : "添加" }}考试</div>
<img
style="width: 29px; height: 29px; cursor: pointer"
src="../../assets/images/basicinfo/close.png"
@click="closeDrawer2"
style="width: 29px; height: 29px; cursor: pointer"
src="../../assets/images/basicinfo/close.png"
@click="closeDrawer2"
/>
</div>
<!-- 2022-11-30注释 后面放开 修改div的padding-topL:32 -->
@@ -34,127 +34,130 @@
</button> -->
</div>
<a-form
v-if="isOuter == 1"
ref="formRef"
name="custom-validation"
:model="formState"
:rules="rules"
v-bind="layout"
@finish="handleFinish"
@validate="handleValidate"
@finishFailed="handleFinishFailed"
v-if="isOuter == 1"
ref="formRef"
name="custom-validation"
:model="formState"
:rules="rules"
v-bind="layout"
@finish="handleFinish"
@validate="handleValidate"
@finishFailed="handleFinishFailed"
>
<div class="contentMain">
<div class="main_left">
<div class="main_item">
<div class="btnbox">
<div class="sign" style="margin-bottom:24px">
<img
<div class="sign" style="margin-bottom: 24px">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
/>
</div>
<a-form-item
has-feedback
label="考试名称"
name="examinationName"
has-feedback
label="考试名称"
name="examinationName"
>
<a-input
v-model:value="formState.examinationName"
style="width: 424px; height: 32px; margin-left: 35px"
autocomplete="off"
placeholder="请输入考试名称"
show-count :maxlength="20"
v-model:value="formState.examinationName"
style="width: 424px; height: 32px; margin-left: 35px"
autocomplete="off"
placeholder="请输入考试名称"
show-count
:maxlength="20"
/>
</a-form-item>
</div>
</div>
<div class="main_item2">
<a-form-item
has-feedback
label="考试说明"
name="examinationExplain"
has-feedback
label="考试说明"
name="examinationExplain"
>
<div class="textarea">
<a-textarea
v-model:value="formState.examinationExplain"
placeholder="请输入考试说明"
allow-clear
:rows="6"
style="margin-left: 35px"
show-count :maxlength="200"
v-model:value="formState.examinationExplain"
placeholder="请输入考试说明"
allow-clear
:rows="6"
style="margin-left: 35px"
show-count
:maxlength="200"
/>
</div>
</a-form-item>
</div>
<div class="main_item">
<div class="btnbox">
<div class="sign" style="margin-bottom:24px">
<img
<div class="sign" style="margin-bottom: 24px">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
/>
</div>
<a-form-item has-feedback label="选择考试" name="choosedTest">
<a-button
type="primary"
style="width: 100px; margin-left: 35px"
class="outer"
@click.prevent
@click="selectTest()"
type="primary"
style="width: 100px; margin-left: 35px"
class="outer"
@click.prevent
@click="selectTest()"
>
选择考试
</a-button>
<a-tag v-if="paperName != ''" closable color="processing" @close="delTag">
<span style="font-size:14px;line-height: 33px;">{{paperName}}</span>
<a-tag
v-if="paperName != ''"
closable
color="processing"
@close="delTag"
>
<span style="font-size: 14px; line-height: 33px">{{
paperName
}}</span>
</a-tag>
</a-form-item>
</div>
</div>
<div class="main_item">
<div class="btnbox">
<div class="sign" style="margin-bottom:24px">
<img
<div class="sign" style="margin-bottom: 24px">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
/>
</div>
<a-form-item has-feedback label="考试时间" name="choosedTime">
<a-range-picker
v-model:value="formState.choosedTime"
format="YYYY-MM-DD"
style="width: 424px; margin-left: 35px"
:placeholder="[' 开始时间', ' 结束时间']"
v-model:value="formState.choosedTime"
format="YYYY-MM-DD"
style="width: 424px; margin-left: 35px"
:placeholder="[' 开始时间', ' 结束时间']"
/>
</a-form-item>
</div>
</div>
<div class="main_item">
<div class="btnbox">
<div class="sign" style="margin-bottom:24px">
<img
<div class="sign" style="margin-bottom: 24px">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
/>
</div>
<a-form-item
has-feedback
label="考试时长"
name="examinationDuration"
has-feedback
label="考试时长"
name="examinationDuration"
>
<a-input
v-model:value="formState.examinationDuration"
type="number"
style="width: 388px; height: 32px; margin-left: 35px"
v-model:value="formState.examinationDuration"
type="number"
style="width: 388px; height: 32px; margin-left: 35px"
/>
</a-form-item>
<span style="transform: translateY(-50%)">分钟</span>
@@ -164,16 +167,16 @@
<div class="btnbox">
<span style="margin-right: 43px">考试限制</span>
<a-form-item
has-feedback
label="允许重复考试"
name="examinationLimit"
has-feedback
label="允许重复考试"
name="examinationLimit"
>
<a-input-number
:min="-1"
:precision="0"
type="number"
v-model:value="formState.examinationLimit"
style="
:min="-1"
:precision="0"
type="number"
v-model:value="formState.examinationLimit"
style="
width: 88px;
height: 32px;
border-radius: 8px;
@@ -182,7 +185,7 @@
/>
<span style="margin-left: 8px"></span>
<span style="margin-left: 24px; color: #999999"
>-1表示无限制</span
>-1表示无限制</span
>
</a-form-item>
</div>
@@ -191,23 +194,21 @@
<div class="btnbox">
<a-form-item has-feedback label="显示答案" name="showAnswers">
<a-radio-group
style="margin-left: 35px; margin-right: 12px"
v-model:value="formState.showAnswers"
style="margin-left: 35px; margin-right: 12px"
v-model:value="formState.showAnswers"
>
<a-radio
v-model:checked="checked"
:value="1"
@click="cloradio1"
>允许查看
</a-radio
>
v-model:checked="checked"
:value="1"
@click="cloradio1"
>允许查看
</a-radio>
<a-radio
v-model:checked="checked"
:value="2"
@click="cloradio1"
>不允许查看
</a-radio
>
v-model:checked="checked"
:value="2"
@click="cloradio1"
>不允许查看
</a-radio>
</a-radio-group>
</a-form-item>
</div>
@@ -216,23 +217,21 @@
<div class="btnbox">
<a-form-item has-feedback label="显示解析" name="showAnalysis">
<a-radio-group
style="margin-left: 35px; margin-right: 12px"
v-model:value="formState.showAnalysis"
style="margin-left: 35px; margin-right: 12px"
v-model:value="formState.showAnalysis"
>
<a-radio
v-model:checked="checked"
:value="1"
@click="cloradio2"
>允许查看
</a-radio
>
v-model:checked="checked"
:value="1"
@click="cloradio2"
>允许查看
</a-radio>
<a-radio
v-model:checked="checked"
:value="2"
@click="cloradio2"
>不允许查看
</a-radio
>
v-model:checked="checked"
:value="2"
@click="cloradio2"
>不允许查看
</a-radio>
</a-radio-group>
</a-form-item>
</div>
@@ -241,23 +240,21 @@
<div class="btnbox">
<a-form-item has-feedback label="评分模式" name="scoringModel">
<a-radio-group
style="margin-left: 35px; margin-right: 12px"
v-model:value="formState.scoringModel"
style="margin-left: 35px; margin-right: 12px"
v-model:value="formState.scoringModel"
>
<a-radio
v-model:checked="checked"
:value="1"
@click="cloradio3"
>最高一次
</a-radio
>
v-model:checked="checked"
:value="1"
@click="cloradio3"
>最高一次
</a-radio>
<a-radio
v-model:checked="checked"
:value="2"
@click="cloradio3"
>最后一次
</a-radio
>
v-model:checked="checked"
:value="2"
@click="cloradio3"
>最后一次
</a-radio>
</a-radio-group>
</a-form-item>
</div>
@@ -266,9 +263,9 @@
<div class="btnbox">
<a-form-item has-feedback label="及格线" name="passLine">
<a-input
v-model:value="formState.passLine"
type="number"
style="width: 88px; height: 32px; margin-left: 35px"
v-model:value="formState.passLine"
type="number"
style="width: 88px; height: 32px; margin-left: 35px"
/>
</a-form-item>
<span style="margin-left: 8px"></span>
@@ -277,35 +274,38 @@
<div class="main_item">
<div class="btnbox">
<a-form-item
has-feedback
label="作业要求"
name="questionArrangement"
has-feedback
label="作业要求"
name="questionArrangement"
>
<a-radio-group
style="margin-right: 12px"
v-model:value="formState.questionArrangement"
style="margin-right: 12px"
v-model:value="formState.questionArrangement"
>
<a-radio
v-model:checked="checked"
:value="1"
@click="cloradio4"
>试题乱序
</a-radio
>
v-model:checked="checked"
:value="1"
@click="cloradio4"
>试题乱序
</a-radio>
<a-radio
v-model:checked="checked"
:value="2"
@click="cloradio4"
>试题排
</a-radio
>
v-model:checked="checked"
:value="2"
@click="cloradio4"
>选项乱
</a-radio>
<a-radio
v-model:checked="checked"
:value="3"
@click="cloradio4"
>全部乱序
</a-radio
>
v-model:checked="checked"
:value="3"
@click="cloradio4"
>全部乱序
</a-radio>
<a-radio
v-model:checked="checked"
:value="4"
@click="cloradio4"
>不乱序
</a-radio>
</a-radio-group>
</a-form-item>
</div>
@@ -318,31 +318,32 @@
</div>
</a-form>
<a-form
v-else
ref="formRef"
name="custom-validation"
:model="formState"
:rules="rules"
v-bind="layout"
@finish="handleFinish"
@validate="handleValidate"
@finishFailed="handleFinishFailed"
v-else
ref="formRef"
name="custom-validation"
:model="formState"
:rules="rules"
v-bind="layout"
@finish="handleFinish"
@validate="handleValidate"
@finishFailed="handleFinishFailed"
>
<div class="contentMain">
<div class="main_left">
<div class="main_item">
<div class="btnbox">
<a-form-item
has-feedback
label="考试名称"
name="examinationName"
has-feedback
label="考试名称"
name="examinationName"
>
<a-input
v-model:value="formState.examinationName"
style="width: 424px; height: 32px; margin-left: 35px"
autocomplete="off"
placeholder="请输入考试名称"
show-count :maxlength="20"
v-model:value="formState.examinationName"
style="width: 424px; height: 32px; margin-left: 35px"
autocomplete="off"
placeholder="请输入考试名称"
show-count
:maxlength="20"
/>
</a-form-item>
</div>
@@ -350,16 +351,17 @@
<div class="main_item">
<div class="btnbox">
<a-form-item
has-feedback
label="数据来源"
name="examinationName"
has-feedback
label="数据来源"
name="examinationName"
>
<a-input
v-model:value="请输入数据来源"
style="width: 424px; height: 32px; margin-left: 35px"
autocomplete="off"
placeholder="数据来源"
show-count :maxlength="20"
v-model:value="请输入数据来源"
style="width: 424px; height: 32px; margin-left: 35px"
autocomplete="off"
placeholder="数据来源"
show-count
:maxlength="20"
/>
</a-form-item>
</div>
@@ -367,18 +369,19 @@
<div class="main_item2">
<a-form-item
has-feedback
label="考试说明"
name="examinationExplain"
has-feedback
label="考试说明"
name="examinationExplain"
>
<div class="textarea">
<a-textarea
v-model:value="formState.examinationExplain"
placeholder="请输入考试说明"
allow-clear
:rows="6"
style="margin-left: 35px"
show-count :maxlength="200"
v-model:value="formState.examinationExplain"
placeholder="请输入考试说明"
allow-clear
:rows="6"
style="margin-left: 35px"
show-count
:maxlength="200"
/>
</div>
</a-form-item>
@@ -393,23 +396,23 @@
</div>
<!-- 加载动画 -->
<div class="aeLoading" :style="{ display: addLoading ? 'flex' : 'none' }">
<a-spin :spinning="addLoading" tip="添加中..."/>
<a-spin :spinning="addLoading" tip="添加中..." />
</div>
<!-- 选择考试抽屉 -->
<s-test v-model:STvisible="STvisible" @getSTData="getData"/>
<s-test v-model:STvisible="STvisible" @getSTData="getData" />
</a-drawer>
</template>
<script>
import {reactive, ref, toRefs} from "vue";
import {message} from "ant-design-vue";
import { reactive, ref, toRefs } from "vue";
import { message } from "ant-design-vue";
import {
createExamination,
queryExaminationDetailById,
updateExamination,
} from "@/api/indexExam";
import STest from "./SelectTest.vue";
import {ProjectEditTask, RouterEditTask} from "@/api/indexTask";
import {addTempTask} from "../../api/indexTaskadd";
import { ProjectEditTask, RouterEditTask } from "@/api/indexTask";
import { addTempTask } from "../../api/indexTaskadd";
import dayjs from "dayjs";
export default {
@@ -470,7 +473,7 @@ export default {
type: Number,
default: null,
},
testName:{
testName: {
type: String,
default: null,
},
@@ -499,12 +502,12 @@ export default {
paperName: "", //试卷名称 子组件传过来给考试抽屉选择试卷后框框用
id: "",
testName: "",
TestName:"",
testObj:{
name:"",
paperId:"",
choosedTime:"",
duration:""
TestName: "",
testObj: {
name: "",
paperId: "",
choosedTime: "",
duration: "",
},
choosedTestList: [
{
@@ -529,7 +532,7 @@ export default {
updateTest();
};
const handleFinishFailed = () => {
// message.error("handleFinishFailed");
// message.error("handleFinishFailed");
};
const resetForm = () => {
formRef.value.resetFields();
@@ -542,12 +545,12 @@ export default {
console.log(args);
};
const closeDrawer = () => {
console.log('closeDrawer')
console.log("closeDrawer");
formState.choosedTime = "";
ctx.emit("update:addtestVisible", false);
ctx.emit("update:edit", false);
ctx.emit("update:EditTestId", state.EditTestId);
ctx.emit("update:testName", state.testName);
ctx.emit("update:testName", state.testName);
console.log("formState.testName", state.testName);
localStorage.setItem("stageId", props.chooseStageId);
localStorage.setItem("chapterId", props.isactive);
@@ -560,7 +563,7 @@ export default {
resetForm();
};
const afterVisibleChange = () => {
console.log('props', props)
console.log("props", props);
if (props.addtestVisible && props.edit) {
// 该页面显示同时 edit为true 时,发送查询请求,
queryTest();
@@ -575,45 +578,45 @@ export default {
};
const queryTest = () => {
// state.addLoading = true;
queryExaminationDetailById({examinationId: props.EditTestId})
.then((res) => {
formState.examinationName = res.data.data.examinationName;
formState.workRequirement = res.data.data.workRequirement;
formState.examinationDuration = res.data.data.examinationDuration;
formState.examinationLimit =
Number(res.data.data.examinationLimit) || -1;
formState.passLine = res.data.data.passLine;
formState.examinationExplain = res.data.data.examinationExplain;
formState.questionArrangement =
Number(res.data.data.questionArrangement) || 1;
formState.scoringModel = Number(res.data.data.scoringModel) || 1;
formState.showAnalysis = Number(res.data.data.showAnalysis) || 1;
formState.showAnswers = Number(res.data.data.showAnswers) || 1;
formState.papaerName = res.data.data.examinationTestName;
state.paperName = res.data.data.examinationTestName;
if (
res.data.data.examinationEndTime &&
res.data.data.examinationStartTime
) {
formState.choosedTime = [
dayjs(res.data.data.examinationStartTime, "YYYY-MM-DD"),
dayjs(res.data.data.examinationEndTime, "YYYY-MM-DD"),
];
state.addLoading = false;
} else {
formState.choosedTime = [];
}
})
.catch(() => {
//message.error(`查询失败`);
});
queryExaminationDetailById({ examinationId: props.EditTestId })
.then((res) => {
formState.examinationName = res.data.data.examinationName;
formState.workRequirement = res.data.data.workRequirement;
formState.examinationDuration = res.data.data.examinationDuration;
formState.examinationLimit =
Number(res.data.data.examinationLimit) || -1;
formState.passLine = res.data.data.passLine;
formState.examinationExplain = res.data.data.examinationExplain;
formState.questionArrangement =
Number(res.data.data.questionArrangement) || 1;
formState.scoringModel = Number(res.data.data.scoringModel) || 1;
formState.showAnalysis = Number(res.data.data.showAnalysis) || 1;
formState.showAnswers = Number(res.data.data.showAnswers) || 1;
formState.papaerName = res.data.data.examinationTestName;
state.paperName = res.data.data.examinationTestName;
if (
res.data.data.examinationEndTime &&
res.data.data.examinationStartTime
) {
formState.choosedTime = [
dayjs(res.data.data.examinationStartTime, "YYYY-MM-DD"),
dayjs(res.data.data.examinationEndTime, "YYYY-MM-DD"),
];
state.addLoading = false;
} else {
formState.choosedTime = [];
}
})
.catch(() => {
//message.error(`查询失败`);
});
};
const updateTest = () => {
//state.addLoading = true;updateTask
let obj = {
examinationDuration: formState.examinationDuration,
examinationEndTime: dayjs(formState.choosedTime[1]).format(
"YYYY-MM-DD"
"YYYY-MM-DD"
),
examinationExplain: formState.examinationExplain,
examinationId: props.edit ? props.EditTestId : 0,
@@ -622,7 +625,7 @@ export default {
examinationPaperId: 0,
// examinationPaperName: formState.choosedTest,
examinationStartTime: dayjs(formState.choosedTime[0]).format(
"YYYY-MM-DD"
"YYYY-MM-DD"
),
passLine: formState.passLine,
questionArrangement: formState.questionArrangement,
@@ -632,7 +635,7 @@ export default {
examinationTestId: state.paperId,
examinationTestName: state.paperName,
};
if (!formState.examinationName) {
message.destroy();
return message.warning("请输入考试名称");
@@ -649,29 +652,29 @@ export default {
message.destroy();
return message.warning("请输入考试时长");
}
if (props.edit) {
// 编辑任务
updateExamination(obj)
.then(async (res) => {
await updateTask(res);
closeDrawer();
})
.catch(() => {
message.destroy();
message.error(`编辑失败`);
});
.then(async (res) => {
await updateTask(res);
closeDrawer();
})
.catch(() => {
message.destroy();
message.error(`编辑失败`);
});
} else {
// 创建任务
createExamination(obj)
.then(async (res) => {
await updateTask(res);
closeDrawer();
})
.catch(() => {
message.destroy();
message.error(`创建失败`);
});
.then(async (res) => {
await updateTask(res);
closeDrawer();
})
.catch(() => {
message.destroy();
message.error(`创建失败`);
});
}
};
const updateTask = (res) => {
@@ -690,15 +693,15 @@ export default {
type: 5,
};
RouterEditTask(editObj1)
.then(() => {
//message.success(`${props.edit ? "编辑" : "新增"}关卡任务成功`);
ctx.emit("changeData", false);
state.addLoading = false;
closeDrawer();
})
.catch(() => {
//message.error(`${props.edit ? "编辑" : "新增"}关卡任务失败`);
});
.then(() => {
//message.success(`${props.edit ? "编辑" : "新增"}关卡任务成功`);
ctx.emit("changeData", false);
state.addLoading = false;
closeDrawer();
})
.catch(() => {
//message.error(`${props.edit ? "编辑" : "新增"}关卡任务失败`);
});
} else if (props.isLevel == 2) {
let editObj = {
courseId: res.data.data.examinationId,
@@ -711,13 +714,13 @@ export default {
};
// 新增编辑或新增项目
ProjectEditTask(editObj)
.then(() => {
//message.success(`${props.EditTestId ? "编辑" : "新增"}阶段任务成功`);
ctx.emit("changeData", false);
})
.catch(() => {
//message.error(`${props.EditTestId ? "编辑" : "新增"}阶段任务失败`);
});
.then(() => {
//message.success(`${props.EditTestId ? "编辑" : "新增"}阶段任务成功`);
ctx.emit("changeData", false);
})
.catch(() => {
//message.error(`${props.EditTestId ? "编辑" : "新增"}阶段任务失败`);
});
} else if (props.isLevel == 3) {
addTempTask({
courseId: res.data.data.examinationId,
@@ -728,13 +731,13 @@ export default {
stageId: props.chooseStageId || 0,
type: 5,
})
.then(() => {
//message.success( `${props.EditTestId ? "编辑" : "新增"}阶段任务成功`);
ctx.emit("changeData", false);
})
.catch(() => {
//message.error(`${props.EditTestId ? "编辑" : "新增"}阶段任务失败`);
});
.then(() => {
//message.success( `${props.EditTestId ? "编辑" : "新增"}阶段任务成功`);
ctx.emit("changeData", false);
})
.catch(() => {
//message.error(`${props.EditTestId ? "编辑" : "新增"}阶段任务失败`);
});
}
}
};
@@ -761,12 +764,10 @@ export default {
const changeOuter = (value) => {
state.isOuter = value;
};
const chooseTest = () => {
};
const chooseTest = () => {};
const closeTag = (removedTag) => {
const tags = state.choosedTestList.filter(
(item) => item.key != removedTag
(item) => item.key != removedTag
);
state.choosedTestList = tags;
};
@@ -795,7 +796,7 @@ export default {
formRef,
delTag,
// layout,
updateTest,
queryTest,
changeOuter,

View File

@@ -12,28 +12,33 @@
</div>
<template v-if="noticeChecked">
<p>公告内容</p>
<!-- 文本 -->
<div
v-if="!editOn"
style="height: 120px; border: 1px solid rgb(217, 217, 217"
>
{{ noticeContent }}
</div>
<a-textarea
v-if="editOn"
v-model:value="noticeContent"
:maxlength="150"
placeholder="公告信息最多输入150个字"
style="margin-top: -10px; height: 120px"
/>
<!-- 按钮 -->
<div v-if="!editOn" class="btn-content">
<a-button type="primary" @click="handleEdit">编辑</a-button>
</div>
<div v-if="editOn" class="btn-content">
<a-button class="cancel" @click="handleCancel">取消</a-button>
<a-button type="primary" @click="pubNotice" class="sure">发布</a-button>
</div>
<!-- 预览 -->
<template v-if="!editOn">
<div style="height: 120px; border: 1px solid rgb(217, 217, 217">
{{ noticeContent }}
</div>
<div class="btn-content">
<a-button type="primary" @click="handleEdit">编辑</a-button>
</div>
</template>
<!-- 编辑 -->
<template v-if="editOn">
<div style="height: 120px; border: 1px solid rgb(217, 217, 217">
{{ noticeContent }}
</div>
<a-textarea
v-model:value="noticeContent"
:maxlength="150"
placeholder="公告信息最多输入150个字"
style="margin-top: -10px; height: 120px"
/>
<div class="btn-content">
<a-button class="cancel" @click="handleCancel">取消</a-button>
<a-button type="primary" @click="pubNotice" class="sure">
发布
</a-button>
</div>
</template>
</template>
</div>
</template>s

View File

@@ -388,7 +388,11 @@
<img
class="i_upload_img"
v-if="feng_mian_1"
:src="feng_mian_1"
:src="
feng_mian_1.indexOf(',') > -1
? feng_mian_1.split(',')[0]
: feng_mian_1
"
alt="avatar"
/>
<!-- <a-upload
@@ -672,7 +676,7 @@
:mode="mode"
/>
<Editor
style="height: 300px; overflow-y: hidden"
style="height: 250px; overflow-y: hidden"
v-model="valueHtml"
:defaultConfig="editorConfig"
:mode="mode"
@@ -826,7 +830,11 @@
<img
class="i_upload_img"
v-if="feng_mian_2"
:src="feng_mian_2"
:src="
feng_mian_2.indexOf(',') > -1
? feng_mian_2.split(',')[0]
: feng_mian_2
"
alt="avatar"
/>
<!-- <a-upload
@@ -1109,7 +1117,7 @@
:mode="mode"
/>
<Editor
style="height: 500px; overflow-y: hidden"
style="height: 250px; overflow-y: hidden"
v-model="valueHtml"
:defaultConfig="editorConfig"
:mode="mode"
@@ -2170,6 +2178,7 @@
</div>
<div class="b_input">
<a-input
maxlength="30"
v-model:value="xjkkinputV1"
style="width: 440px; height: 40px; border-radius: 8px"
placeholder="请输入开课名称"
@@ -2942,9 +2951,12 @@
<div class="close_exit" @click="delete_exit1"></div>
</div>
<div class="body">
<div :style="{ display: del_hs ? 'block' : 'none' }">
<div :style="{ display: del_hs && !del_hs_stu ? 'block' : 'none' }">
<span>您确定要删除此课程吗</span>
</div>
<div :style="{ display: del_hs && del_hs_stu ? 'block' : 'none' }">
<span>您确定要删除此学员吗</span>
</div>
<div :style="{ display: copy_hs ? 'block' : 'none' }">
<span>您确定要复制此课程吗</span>
</div>
@@ -3339,7 +3351,7 @@ const columns6 = [
title: "序号",
dataIndex: "num",
key: "num",
width: "8%",
width: "6%",
align: "center",
customRender: ({ index }) => {
//{ text, record, index, column }
@@ -3350,8 +3362,9 @@ const columns6 = [
title: "课程名称",
dataIndex: "organization",
key: "organization",
width: "10%",
width: "25%",
align: "center",
ellipsis: true,
customRender: ({ text }) => {
return text ? text : "-";
},
@@ -3360,8 +3373,9 @@ const columns6 = [
title: "场地",
dataIndex: "address",
key: "saddress",
width: "10%",
width: "25%",
align: "center",
ellipsis: true,
customRender: ({ text }) => {
return text ? text : "-";
},
@@ -3370,7 +3384,7 @@ const columns6 = [
title: "开始时间",
dataIndex: "starttime",
key: "starttime",
width: "18%",
width: "12%",
align: "center",
customRender: ({ text }) => {
return text ? getdateToTime(text * 1000) : "-";
@@ -3380,7 +3394,7 @@ const columns6 = [
title: "创建时间",
dataIndex: "createtime",
key: "createtime",
width: "18%",
width: "12%",
align: "center",
customRender: ({ text }) => {
return text ? getdateToTime(text * 1000) : "-";
@@ -3388,7 +3402,7 @@ const columns6 = [
},
{
title: "操作",
width: "30%",
width: "20%",
dataIndex: "operation",
key: "operation",
align: "center",
@@ -3712,6 +3726,7 @@ export default defineComponent({
rejectstudy_hs: false,
delete_hs: false,
del_hs: false,
del_hs_stu: false,
copy_hs: false,
nouse_hs: false,
// 二维码标题状态
@@ -4009,7 +4024,7 @@ export default defineComponent({
state.imgList.splice(index, 1);
};
const handleDel2 = (index) => {
state.fileList.splice(index, 1);
state.filesList.splice(index, 1);
};
// 渲染列表1操作
@@ -4110,6 +4125,7 @@ export default defineComponent({
state.delete_hs = true;
state.del_hs = true;
state.del_hs_stu = true;
};
const handlJoinStu = (itm) => {
console.log(itm);
@@ -4270,7 +4286,7 @@ export default defineComponent({
let newArr = [];
arr.forEach((item) => {
newArr.push({
value: item.dictValue,
value: item.dictValue + "," + item.dictCode,
label: item.dictName,
});
});
@@ -4650,6 +4666,8 @@ export default defineComponent({
};
const handleCancelStu = () => {
state.cstm_hs = false;
state.filesList = [];
state.kk_eidt = false;
state.xjkkradioV1 = "";
state.completeType = "";
@@ -4829,6 +4847,7 @@ export default defineComponent({
const delete_exit1 = () => {
state.delete_hs = false;
state.del_hs = false;
state.del_hs_stu = false;
state.copy_hs = false;
state.nouse_hs = false;
state.rg_hs = false;
@@ -5190,8 +5209,6 @@ export default defineComponent({
};
const handleLook = async (itm, type) => {
// state.isEdit = 0;
// console.log(45555);
// console.log(itm);
if (type === "1") {
return;
}
@@ -5205,42 +5222,6 @@ export default defineComponent({
state.lookCourseModal = true;
item.attach = item.attach == "" ? [] : item.attach.split(",");
state.faceDetailObj = item;
// // heroImg.value.src = item.picUrl;
// // valueHtmlRef.value = item.outline;
// // attachMap.value = item.attach == "" ? [] : item.attach.split(",");
// console.log("res222222222");
// console.log(item);
// console.log(state.lookCourseModal);
// state.qdms_inputV1 = item.name;
// state.imageUrl = item.picUrl;
// state.qdms_inputV2 = item.targetUser;
// state.qdms_inputV3 = item.meaning;
// state.fen_lei = String(item.categoryId);
// state.chang_jin = String(item.sceneId);
// state.tags_val = item.tips ? item.tips.split(",") : [];
// //state.qdms_inputV5 = item.teacherId;
// state.teacher = item.teacher;
// state.teacherId = item.teacherId;
// state.qdms_inputV6 = item.intro;
// state.member = { value: item.teacherId, name: item.teacher };
// if (item.attach == "") {
// state.imgList = [];
// } else {
// if (item.attach.indexOf(",")) {
// const arr = item.attach.split(",");
// arr.forEach((item) => {
// state.imgList.push({ img: item });
// });
// } else {
// state.imgList = [{ img: item.attach }];
// }
// }
// valueHtml.value = item.outline;
// state.lookMs = true;
};
// const handleTea = async () => {
// console.log("item22224444");
@@ -5387,12 +5368,13 @@ export default defineComponent({
console.log(file);
fileUp(formData).then((res) => {
if (res.data.code === 200) {
state.filesList.push({
img: res.data.data,
name: file.name,
size: file.size,
});
console.log(state.filesList);
// state.filesList.push({
// img: res.data.data,
// name: file.name,
// size: file.size,
// });
// console.log(state.filesList);
state.filesList = [res.data.data];
// state.hasImgName = res.data.data;
}
});
@@ -7193,6 +7175,7 @@ export default defineComponent({
}
.fotarea {
width: calc(100% - 150px);
position: relative;
.fuwenben {

View File

@@ -59,7 +59,11 @@
<span style="margin-right: 14px">封面图</span>
</div>
<img
:src="detail.picUrl"
:src="
detail.picUrl.indexOf(',') > -1
? detail.picUrl.split(',')[0]
: detail.picUrl
"
alt="img"
style="width: 100px; height: 100px"
/>
@@ -648,7 +652,7 @@ export default defineComponent({
}
.fotarea {
width: calc(100% - 100px);
width: calc(100% - 150px);
position: relative;
.fuwenben {

View File

@@ -59,6 +59,45 @@
</div>
</div>
</div>
<!-- 审核日志弹窗 -->
<a-modal
v-model:visible="projAuditModal"
:footer="null"
:closable="closeBack"
wrapClassName="projAuditModal"
centered="true"
>
<div class="delete">
<div class="del_header"></div>
<div class="del_main">
<div class="header">
<div class="icon"></div>
<span>审核记录</span>
<!-- <div class="close_exit" @click="closeProjAuditModal"></div> -->
</div>
<div class="body">
<a-table
style="width: 90%"
:columns="columnsAudit"
:data-source="tableDataAudit"
:loading="tableDataTotalAudit === -1 ? true : false"
expandRowByClick="true"
:scroll="{ y: 150 }"
@expand="expandTable"
:pagination="false"
/>
</div>
<div class="del_btnbox">
<div class="del_btn btn1" @click="closeProjAuditModal">
<div class="btnText">取消</div>
</div>
<div class="del_btn btn2" @click="closeProjAuditModal">
<div class="btnText">确定</div>
</div>
</div>
</div>
</div>
</a-modal>
</div>
</template>
<script>
@@ -132,15 +171,19 @@ export default {
key: "msg",
align: "center",
},
// {
// title: "操作",
// dataIndex: "opt",
// key: "opt",
// align: "center",
// customRender: () => {
// return <div style="color:#387DF7">审核日志</div>;
// },
// },
{
title: "操作",
dataIndex: "opt",
key: "opt",
align: "center",
customRender: (value) => {
return <div
style="color:#387DF7;cursor:pointer;"
onClick={() => {
showProjAuditModal(value.record.auditList);
}}>审核日志</div>;
},
},
],
tableData1: [
// {
@@ -154,6 +197,9 @@ export default {
// msg: "-",
// },
],
//审核记录的数据
tableDataAudit: [],
projAuditModal: false,
});
const getList = () => {
let objn = {
@@ -227,12 +273,25 @@ export default {
//获取分类列表
state.calssifyList = (await getDictList("faceclassClass")).map(e => ({ label: e.dictName, value: e.dictCode }))
});
// 显示审核
const showProjAuditModal = (data) => {
state.tableDataAudit = data
state.projAuditModal = true;
};
const closeProjAuditModal = () => {
state.projAuditModal = false;
};
return {
...toRefs(state),
getList,
setTableData,
reset,
changePagination,
showProjAuditModal,
closeProjAuditModal
};
},
};

View File

@@ -141,304 +141,11 @@
</div>
</a-modal>
<!-- 预览弹窗 -->
<a-modal
v-model:visible="lookCourseModal"
title="Title"
@ok="handlePush"
:footer="null"
:closable="false"
wrapClassName="modalStyle lookCourseModal"
width="80%"
<SeeModal
:visible="lookCourseModal"
:detail="faceDetailObj"
@cancel="ft_exit"
>
<div class="modalHeader">
<div class="headerLeft">
<img
style="width: 17px; height: 18px; margin-right: 8px"
src="../../assets/images/basicinfo/add.png"
/>
<span class="headerLeftText">预览</span>
</div>
<div style="margin-right: 57px; cursor: pointer">
<img
@click="ft_exit"
style="width: 22px; height: 22px"
src="../../assets/images/basicinfo/close22.png"
/>
</div>
</div>
<div class="modalMain">
<div class="faceteach">
<div class="ft_main">
<div class="m_body">
<div class="mb_left">
<div class="mbl_items">
<div class="item_nam">
<div class="asterisk_icon">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
<span style="margin-right: 14px">课程名称</span>
</div>
<div class="item_inp">
<div class="i1_input">
{{ faceDetailObj !== null ? faceDetailObj.name : "" }}
</div>
</div>
</div>
<div class="i2_cz">
<div class="i2_top">
<div
class="i2_right"
@click="hideShow"
style="cursor: pointer"
>
<div class="b_icon"></div>
</div>
</div>
</div>
<div class="mbl_items2">
<div class="item_nam">
<div class="asterisk_icon">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
<span style="margin-right: 14px">封面图</span>
</div>
<img
ref="heroImg"
alt=""
style="width: 100px; height: 100px"
/>
<!-- <div class="item_inp"></div> -->
</div>
<div class="mbl_items">
<div class="item_nam">
<div class="asterisk_icon">
<img
style="width: 10px; height: 10px"
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
<span style="margin-right: 14px">目标人群</span>
</div>
<div class="item_inp">
<div class="i1_input">
{{
faceDetailObj !== null ? faceDetailObj.targetUser : ""
}}
</div>
</div>
</div>
<div class="mbl_items">
<div class="item_nam">
<span style="margin-right: 14px">课程价值</span>
</div>
<div class="item_inp">
<div class="i1_input">
{{ faceDetailObj !== null ? faceDetailObj.meaning : "" }}
</div>
</div>
</div>
<!-- <div class="mbl_items">
<div class="item_nam">
<div class="asterisk_icon">
<img src="@/assets/images/coursewareManage/asterisk.png" alt="" />
</div>
<span style="margin-right: 14px">资源归属</span>
</div>
<div class="item_inp">
<div class="select i6_input">{{ faceDetailObj !== null ? faceDetailObj.projectId : "" }}</div>
</div>
</div> -->
<div class="mbl_items">
<div class="item_nam">
<div class="asterisk_icon">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
<span style="margin-right: 14px">内容分类</span>
</div>
<div class="item_inp">
<!-- <div class="select i6_input">{{ faceDetailObj !== null ? faceDetailObj.categoryId : "" }}</div> -->
<div class="select i6_input">
{{
faceDetailObj !== null
? contentList11.find(
(e) => e.dictCode == faceDetailObj.categoryId
)?.dictValue
: ""
}}
</div>
</div>
</div>
<div class="mbl_items">
<div class="item_nam">
<span style="margin-right: 14px">场景</span>
</div>
<div class="item_inp">
<!-- <div class="select i7_input">{{ faceDetailObj !== null ? faceDetailObj.sceneId : "" }}</div> -->
<div class="select i7_input">
{{
faceDetailObj !== null
? sceneist11.find(
(e) => e.dictCode == faceDetailObj.sceneId
)?.dictValue
: ""
}}
</div>
</div>
</div>
<div class="mbl_items">
<div class="item_nam">
<span style="margin-right: 14px">内容标签</span>
</div>
<div class="item_inp">
{{ faceDetailObj !== null ? faceDetailObj.tips : "" }}
</div>
</div>
</div>
<div class="mb_right">
<div class="mbl_items">
<div class="item_nam">
<div class="asterisk_icon">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt="asterisk"
/>
</div>
<span style="margin-right: 14px">授课教师</span>
</div>
<div class="item_inp">
<div class="i1_input">
{{ faceDetailObj !== null ? faceDetailObj.teacher : "" }}
</div>
</div>
</div>
<div class="mbl_items2">
<div class="item_nam">
<span style="margin-right: 14px">课程简介</span>
</div>
<div class="item_inp">
<div class="i10_textarea">
{{ faceDetailObj !== null ? faceDetailObj.intro : "" }}
</div>
</div>
</div>
<div class="mbl_items">
<div v-if="attachMap.length > 0" class="item_nam">
<span style="margin-right: 10px">附件</span>
</div>
<div
class="item_inp"
v-for="(value, index) in attachMap"
:key="index"
>
<a>
{{
[
"附件一",
"附件二",
"附件三",
"附件四",
"附件五",
"附件六",
][index]
}}
</a>
<a style="margin-left: 120px" :src="value" :href="value"
>查看</a
>
<!-- <a-upload multiple :show-upload-list="false" :before-upload="beforeUpload2">
<div class="accessory" style="cursor: pointer">
<div class="accessory_icon">
<img src="@/assets/images/coursewareManage/enclosure.png" alt="enclosure" />
</div>
<span style="color: #4ea6ff">添加附件</span>
</div>
</a-upload>
<span>
支持.pdf,.ppt,.pptx,.doc,.docx,.xls,.xlsx,.jpg,.jpeg,.png,.gif,.zip
</span> -->
</div>
</div>
<div class="mbl_items12">
<div
class="i12_box1"
v-for="(item, index) in imgList"
:key="index"
>
<div class="file_img">
<img :src="item.img" />
</div>
<div class="file_detail">
<div class="file_name">
<span style="color: #6f6f6f">{{ item.name }}</span>
</div>
<div class="file_updata">
<div class="updatabox">
<div class="updatacolor"></div>
<div class="updataxq">上传完成</div>
</div>
<div class="upjd">
<span style="margin: auto 5px">100%</span>
</div>
</div>
</div>
<div class="file_operation">
<div class="fobox">
<span style="color: #4ea6ff" @click="handleDel(index)">
删除
</span>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="m_footer">
<div class="fotnam">
<span>课程大纲</span>
</div>
<div class="fotarea">
<div style="border: 1px solid #ccc">
<!-- <Toolbar style="border-bottom: 1px solid #ccc;width:900px;height: 300px;" :defaultConfig="toolbarConfig"
:mode="mode" /> -->
<Editor
@focus="onEditorFocus"
style="
border-bottom: 1px solid #ccc;
width: 900px;
height: 300px;
"
v-model="valueHtml"
:defaultConfig="editorConfig"
:mode="mode"
@onCreated="handleCreated"
/>
</div>
</div>
</div>
<div class="m_btn">
<div class="btn btn5" @click="ft_exit">
<div class="btnText">取消</div>
</div>
<div class="btn btn6" @click="handlePush">
<div class="btnText">确定</div>
</div>
</div>
</div>
</div>
</div>
</a-modal>
/>
<!-- 审核在线课 -->
<a-modal
@@ -462,15 +169,14 @@
import { reactive, toRefs, onMounted, ref } from "vue";
import { list, courseAuditView, courseDetail } from "../../api/indexAudit";
import { message } from "ant-design-vue";
import { Editor } from "@wangeditor/editor-for-vue";
import SeeModal from "../courselibrary/components/seeModal.vue";
import { iframeUrl } from "../../api/method";
import * as api1 from "@/api/index1";
export default {
name: "CoursereViewedN",
components: {
Editor,
// Toolbar,
SeeModal,
},
setup() {
const state = reactive({
@@ -576,7 +282,6 @@ export default {
&nbsp;
<span
onClick={() => {
state.lookCourseModal = true;
getFaceDetail(value.record.offId);
console.log(value.record);
}}
@@ -652,7 +357,10 @@ export default {
.then((res) => {
console.log("获取面授详情信息成功", res);
let result = res.data.data;
state.lookCourseModal = true;
result.attach = result.attach == "" ? [] : result.attach.split(",");
state.faceDetailObj = result;
heroImg.value.src = result.picUrl;
valueHtml.value = result.outline;
attachMap.value = result.attach == "" ? [] : result.attach.split(",");
@@ -705,15 +413,10 @@ export default {
};
// 预览弹框 开启和关闭
const ft_exit = () => {
state.lookCourseModal = false;
};
const handlePush = () => {
state.lookCourseModal = false;
};
const setFaceData = (tableData) => {
if (!tableData || !tableData.length) {
state.tableData1 = [];
@@ -832,7 +535,6 @@ export default {
closeCourAuditModal,
sureCourAuditModal,
ft_exit,
handlePush,
getFaceDetail,
heroImg,
valueHtml,

View File

@@ -201,7 +201,7 @@ export default {
dataIndex: "status",
key: "status",
align: "center",
customRender: ({record: {status}}) => <div>{{2: '审核通过', 3: '审核拒绝'}[status]}</div>,
customRender: ({record: {status}}) => <div>{status==-2?'未通过':'已通过'}</div>,
},
{
title: "创建人",
@@ -531,7 +531,7 @@ export default {
.tmplh_btn {
display: flex;
// margin-left: 38px;
margin-top: 32px;
margin-top: 52px;
.btn {
padding: 0px 26px 0px 26px;

View File

@@ -200,6 +200,7 @@
'background-image': 'url(' + item.dictValue + ')',
display: index >= 5 ? 'none' : 'flex',
}"
style="background-size: 100% 100%"
></div>
<div
@click="showLearnBgMore"
@@ -1056,6 +1057,7 @@ export default {
array.push(obj);
});
state.tableData = array;
console.log(array,tableData)
};
const tableDataFunc = () => {
@@ -1720,7 +1722,7 @@ export default {
getLearnPath();
if (store.state.pathmapPic.length > 0) {
console.log("store.state.pathmapPic", store.state.pathmapPic);
state.imgData = [store.state.pathmapPic[0]];
state.imgData = store.state.pathmapPic;
}
});
//添加权限

View File

@@ -905,9 +905,7 @@
<div class="close_exit" @click="closedeleteAll"></div>
</div>
<div class="body">
<span
>请确认是否批量删除{{ deleteType === 1 ? "任务" : "学员" }}</span
>
<span>请确认是否批量删除任务</span>
</div>
<div class="del_btnbox">
<div class="del_btn btn1" @click="closedeleteAll">
@@ -1630,7 +1628,7 @@ export default {
state.gqxy_hs = !state.gqxy_hs;
};
const showDeleteALLModal = (type) => {
if (state.selectRow.length === 0){
if (state.selectRow.length === 0) {
message.destroy();
return message.warning("请选择要删除的任务");
}
@@ -1744,6 +1742,7 @@ export default {
.then((res) => {
console.log(res);
state.deleteAll = false;
// state.deleteType = null;
message.destroy();
state.selectRow = []; //选择行
state.selectAll = 0; //0未选择1全选2部分选择

View File

@@ -5,11 +5,11 @@
<div class="leftmain">
<div class="tit">
阶段
<!-- <img-->
<!-- src="../../assets/images/projectadd/right.png"-->
<!-- style="margin-left: 10px; cursor: pointer"-->
<!-- @click="showCancel"-->
<!-- />-->
<!-- <img-->
<!-- src="../../assets/images/projectadd/right.png"-->
<!-- style="margin-left: 10px; cursor: pointer"-->
<!-- @click="showCancel"-->
<!-- />-->
</div>
<div class="btn btn3" @click="showModal()" style="margin-left: 19px">
<div class="search"></div>
@@ -140,7 +140,9 @@
<!-- <img class="img2" src="../../assets/images/projectadd/keep.png" />
<div class="pub">保存</div>
<div class="line"></div> -->
<router-link to="/taskpage">
<router-link
:to="{ path: `/taskpage`, query: { projectId: projectId } }"
>
<div style="display: flex">
<img
class="img2"
@@ -874,10 +876,10 @@
</div>
<div class="del_btnbox">
<div class="del_btn btn1" @click="closeCancel">
<div class="btnText" >取消</div>
<div class="btnText">取消</div>
</div>
<div class="del_btn btn2" @click="showModal">
<div class="btnText" >确定</div>
<div class="btnText">确定</div>
</div>
</div>
</div>
@@ -907,7 +909,7 @@
<div class="btnText">取消</div>
</div>
<div class="del_btn btn2" @click="showModal1">
<div class="btnText" >确定</div>
<div class="btnText">确定</div>
</div>
</div>
</div>

View File

@@ -32,11 +32,51 @@
<div
class="pub"
style="width: 28px"
v-if="action == 0"
v-if="action == 2"
@click="showProjectPub"
>
{{ act }}
</div>
<div
class="pub"
style="width: 56px"
v-if="action == 0"
@click="submitExamine"
>
{{ act }}
</div>
<!-- 项目提交审核弹窗 -->
<a-modal
v-model:visible="reviewModal"
:footer="null"
:closable="false"
wrapClassName="CopyModal"
centered="true"
>
<div class="delete">
<div class="del_header"></div>
<div class="del_main">
<div class="header">
<div class="icon"></div>
<span>提示</span>
<div class="close_exit" @click="closeReviewModal"></div>
</div>
<div class="body">
<span>您确定要提交审核吗</span>
<div class="back"></div>
</div>
<div class="del_btnbox">
<div class="del_btn btn1" @click="closeReviewModal">
<div class="btnText">取消</div>
</div>
<div class="del_btn btn2" @click="recallReviewProject">
<div class="btnText">确定</div>
</div>
</div>
</div>
</div>
</a-modal>
<!-- 已结束的显示 -->
<!-- <div class="pub" style="width: 28px" v-if="action == -1">
{{ act }}
@@ -1087,11 +1127,11 @@
><span style="color: #333333">BOEU实施</span></a-radio
>
</div>
</div>
</div>
<div class="set_content" v-if="isPass">
<div class="setc_name"><span>审核意见:</span></div>
<div class="setc_main">
<span style="color: #333333">{{passInfo}}</span>
<span style="color: #333333">{{ passInfo }}</span>
</div>
</div>
</div>
@@ -1106,7 +1146,10 @@
<div class="box"></div>
<div class="onetitle">上传共享文档</div>
<div class="oneedi">
<a-switch v-model:checked="docChecked" @change="checkedClose"></a-switch>
<a-switch
v-model:checked="docChecked"
@change="checkedClose"
></a-switch>
</div>
</div>
<div class="btnbox" style="margin: 20px">
@@ -1768,6 +1811,7 @@ import NoticeHis from "../../components/drawers/NoticeHis";
import TaskImpStu from "../../components/drawers/TaskFaceIn";
import { storage } from "../../api/storage";
import * as api from "../../api/index1";
import * as apis from "../../api/index";
import * as apiproj from "../../api/index";
import {
getProjStu,
@@ -2435,9 +2479,9 @@ export default {
authClassify: 3,
addAuthList: [],
switchopen: true,
isPass:false, // 是否审核未通过
passInfo:null, // 审核未通过原因说明
isPass: false, // 是否审核未通过
passInfo: null, // 审核未通过原因说明
reviewModal: false,
});
const levelList = reactive({
@@ -2511,10 +2555,10 @@ export default {
let leng = res.data.data.stageList.length;
if (leng > 0) {
let taskarr = res.data.data.stageList;
console.log('11-22-33',taskarr)
if(taskarr.length==1){
if(taskarr[0].stageId == '0'){
taskarr[0].name = '无阶段任务'
console.log("11-22-33", taskarr);
if (taskarr.length == 1) {
if (taskarr[0].stageId == "0") {
taskarr[0].name = "无阶段任务";
}
}
state.taskSyllabus = taskarr;
@@ -2809,6 +2853,35 @@ export default {
};
};
// 提交审核
const submitExamine = () => {
state.reviewModal = true;
};
const recallReviewProject = () => {
let obj = {
projectId: state.projectId,
type: 3,
};
console.log("提交审核obj", obj);
apis
.handleProject(obj)
.then((res) => {
console.log("提交成功", res);
message.destroy();
message.success("提交成功");
state.reviewModal = false;
getTaskInfo();
})
.catch((err) => {
console.log("提交失败", err);
});
};
//关闭提交审核弹窗
const closeReviewModal = () => {
state.reviewModal = false;
};
//学员管理列表操作
// const studentData = () => {
// let arr = state.tabledata;
@@ -3370,13 +3443,13 @@ export default {
console.log("get task", res.data.data);
if (res.data.code === 200) {
// 判断当前审核是否通过
if(res.data.data.projectAuditLogDtoList!==null){
console.log('审核信息是什么',res.data.data.projectAuditLogDtoList)
let dataset = res.data.data.projectAuditLogDtoList
for(let i=0;i<dataset.length;i++){
if(dataset[i].status==-5){
state.isPass = true
state.passInfo = dataset[i].description
if (res.data.data.projectAuditLogDtoList !== null) {
console.log("审核信息是什么", res.data.data.projectAuditLogDtoList);
let dataset = res.data.data.projectAuditLogDtoList;
for (let i = 0; i < dataset.length; i++) {
if (dataset[i].status == -5) {
state.isPass = true;
state.passInfo = dataset[i].description;
}
// isPass passInfo
}
@@ -3411,9 +3484,9 @@ export default {
state.type = info.type;
state.category = info.category;
state.noticeFlag = info.noticeFlag;
state.switchopen = info.attachSwitch==1?true:false
state.docChecked = info.attachSwitch==1?true:false;
state.switchopen = info.attachSwitch == 1 ? true : false;
state.docChecked = info.attachSwitch == 1 ? true : false;
// state.attach = info.attach;
// state.templateId = info.templateId;
state.sourceBelong = info.sourceBelongName;
@@ -3483,11 +3556,13 @@ export default {
// projectGroupId: 0,
projectId: state.projectId,
};
console.log("小组创建obj", obj);
editGroup(obj)
.then((res) => {
console.log("小组创建成功", res);
message.success("小组创建成功");
getGroup();
getStu();
})
.catch((err) => {
console.log("小组创建失败", err);
@@ -3569,40 +3644,39 @@ export default {
};
//end---------项目概览
// 设置上传图片开关
const checkedClose = (data, a) => {
// 设置上传图片开关
const checkedClose = (data, a) => {
console.log(data, a);
state.docChecked = data;
state.switchopen = data
state.switchopen = data;
// 更新开关状态
editProj({
attachSwitch:state.switchopen?1:-1,
boeFlag: state.boeFlag,
category: state.category,
courseSyncFlag: state.courseSyncFlag,
level: state.tlevel,
manager: state.manager,
managerId: state.managerId,
name: state.name,
notice: state.notice,
noticeFlag: state.noticeFlag,
parentId: state.parentId,
picUrl: state.picUrl,
projectId: Number(state.projectId),
remark: state.remark,
sourceBelongId: Number(state.tsourceBelong),
status: state.status,
systemId: state.tsystemId,
templateId: state.templateId || 0,
type: state.type,
attachSwitch: state.switchopen ? 1 : -1,
boeFlag: state.boeFlag,
category: state.category,
courseSyncFlag: state.courseSyncFlag,
level: state.tlevel,
manager: state.manager,
managerId: state.managerId,
name: state.name,
notice: state.notice,
noticeFlag: state.noticeFlag,
parentId: state.parentId,
picUrl: state.picUrl,
projectId: Number(state.projectId),
remark: state.remark,
sourceBelongId: Number(state.tsourceBelong),
status: state.status,
systemId: state.tsystemId,
templateId: state.templateId || 0,
type: state.type,
})
.then((res) => {
console.log("上传成功", res);
})
.then((res) => {
console.log("上传成功", res);
})
.catch((err) => {
console.log("上传失败了", err);
});
.catch((err) => {
console.log("上传失败了", err);
});
};
const handleChange = ({ file, fileList }) => {
@@ -3615,7 +3689,7 @@ export default {
let str = JSON.stringify(list);
console.log("str", str);
//要编辑项目
console.log('编辑的项目信息',{
console.log("编辑的项目信息", {
attach: str,
// beginTime: state.tstartTime.slice(0, 10),
boeFlag: state.boeFlag,
@@ -3637,9 +3711,9 @@ export default {
systemId: state.tsystemId,
templateId: state.templateId || 0,
type: state.type,
})
});
editProj({
attachSwitch:state.switchopen?1:-1,
attachSwitch: state.switchopen ? 1 : -1,
attach: str,
boeFlag: state.boeFlag,
category: state.category,
@@ -3715,8 +3789,10 @@ export default {
}).then((res) => {
state.action = res.data.data.projectInfo.status;
state.act =
state.action == 0
state.action == 2
? "发布"
: state.action == 0
? "提交审核"
: state.action == 1
? "撤回"
: state.action == -1
@@ -4028,7 +4104,10 @@ export default {
deFile,
toDate,
routered,
checkedClose
checkedClose,
submitExamine,
closeReviewModal,
recallReviewProject,
};
},
};