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

This commit is contained in:
yuping
2022-12-13 09:55:31 +08:00
31 changed files with 399 additions and 87 deletions

1
.gitignore vendored
View File

@@ -25,3 +25,4 @@ fe-manage.iml
package-lock.json package-lock.json
src/api/config.js src/api/config.js
src/api/config.js src/api/config.js
src/api/config.js

View File

@@ -44,7 +44,7 @@ export default defineComponent({
const store = useStore(); const store = useStore();
const isLogin = ref(false); const isLogin = ref(false);
// console.log("router", router.getRoutes(), route); // console.log("router", router.getRoutes(), route);
console.log("版本0.9.10------------"); console.log("版本0.9.12------------");
const routes = computed(() => { const routes = computed(() => {
return router.getRoutes().filter((e) => e.meta?.isLink); return router.getRoutes().filter((e) => e.meta?.isLink);
}); });

View File

@@ -2,7 +2,7 @@
* @Author: lixg lixg@dongwu-inc.com * @Author: lixg lixg@dongwu-inc.com
* @Date: 2022-11-21 14:32:52 * @Date: 2022-11-21 14:32:52
* @LastEditors: lixg lixg@dongwu-inc.com * @LastEditors: lixg lixg@dongwu-inc.com
* @LastEditTime: 2022-12-11 18:17:05 * @LastEditTime: 2022-12-13 09:24:16
* @FilePath: /fe-manage/src/api/config.js * @FilePath: /fe-manage/src/api/config.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */
@@ -56,7 +56,7 @@ http.interceptors.response.use(
return response; return response;
} else { } else {
if (code === 1000) { if (code === 1000) {
// window.open("https://u-pre.boe.com/web/", '_self'); window.open("https://u-pre.boe.com/web/", '_self');
// window.open("http://111.231.196.214:12013/manage/login", '_self'); // window.open("http://111.231.196.214:12013/manage/login", '_self');
} }
console.log("api %o", msg); console.log("api %o", msg);

View File

@@ -7,7 +7,7 @@ export const list = (obj) => http.post('/admin/offcourse/listToBeReviewed', obj)
//获取待审核项目列表 //获取待审核项目列表
export const projlist = (obj) => http.post('/admin/project/list', obj) export const projlist = (obj) => http.post('/admin/project/list', obj)
//获取待审核项目列表 //获取项目审核日志
export const auditlist = (obj) => http.post('/admin/project/auditlist', obj) export const auditlist = (obj) => http.post('/admin/project/auditlist', obj)
//获取已审核项目列表 //获取已审核项目列表

View File

@@ -70,7 +70,7 @@ export default {
href: "/leveladd", href: "/leveladd",
}, },
{ {
name: "关卡", name: "管理",
}, },
]; ];
} }

View File

@@ -203,6 +203,7 @@
</div> --> </div> -->
</div> </div>
</div> </div>
<!--
<div class="main_item"> <div class="main_item">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px">完成标准设置</span> <span style="margin-right: 3px">完成标准设置</span>
@@ -211,14 +212,15 @@
<a-radio-group v-model:value="radioV1"> <a-radio-group v-model:value="radioV1">
<a-radio v-model:checked="checked" :value="1" @click="cloradio1" <a-radio v-model:checked="checked" :value="1" @click="cloradio1"
>仅签到 >仅签到
</a-radio> </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
> --> >
</a-radio-group> </a-radio-group>
</div> </div>
</div> </div>-->
<div class="main_item" style="height:40px;"> <div class="main_item" style="height:40px;">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px"></span> <span style="margin-right: 3px"></span>
@@ -383,6 +385,10 @@ export default {
}; };
const updateTask = async (res) => { const updateTask = async (res) => {
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
await RouterEditTask({ await RouterEditTask({
chapterId: props.isactive, chapterId: props.isactive,
courseId: res.data.data.activityId, courseId: res.data.data.activityId,

View File

@@ -275,6 +275,10 @@ export default {
}; };
const updateTask = () => { const updateTask = () => {
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
for (let i = 0; i < state.apiTaskList.length; i++) { for (let i = 0; i < state.apiTaskList.length; i++) {
RouterEditTask({ RouterEditTask({
chapterId: props.isactive, chapterId: props.isactive,

View File

@@ -191,6 +191,10 @@ export default {
} }
}; };
const updateTask = async (res) => { const updateTask = async (res) => {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
if (props.isLevel == 1) { if (props.isLevel == 1) {
await RouterEditTask({ await RouterEditTask({
chapterId: props.isactive, chapterId: props.isactive,

View File

@@ -177,6 +177,10 @@ export default {
}; };
//向关卡或阶段渲染 //向关卡或阶段渲染
const updateTask = async (value) => { const updateTask = async (value) => {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
if (props.isLevel == 1) { if (props.isLevel == 1) {
await RouterEditTask({ await RouterEditTask({
chapterId: props.isactive, chapterId: props.isactive,
@@ -249,8 +253,8 @@ export default {
state.description = res.data.data.evaluationExplain; state.description = res.data.data.evaluationExplain;
}) })
.catch((err) => { .catch((err) => {
message.destroy() //message.destroy()
message.error("获取测量平信息失败"); // message.error("获取测量平信息失败");
console.log(err, "erererrerererererer"); console.log(err, "erererrerererererer");
}); });
} }

View File

@@ -27,7 +27,7 @@
alt="" alt=""
/> />
</div> </div>
<span style="margin-right: 3px">课程任务名称</span> <span style="margin-right: 3px">任务名称</span>
</div> </div>
<div class="btnbox"> <div class="btnbox">
<a-input <a-input
@@ -100,8 +100,8 @@
</div> </div>
<span style="margin-right: 3px">面授时间</span> <span style="margin-right: 3px">面授时间</span>
</div> </div>
<div class="select"> <div class="select" >
<a-range-picker <a-range-picker style="width: 400px;"
show-time show-time
format="YYYY/MM/DD HH:mm" format="YYYY/MM/DD HH:mm"
v-model:value="chooseTime" v-model:value="chooseTime"
@@ -702,6 +702,10 @@ export default {
// 新增编辑或新增项目任务 // 新增编辑或新增项目任务
const updateTask = async (res) => { const updateTask = async (res) => {
console.log("props.isLevel=====", props.isLevel); console.log("props.isLevel=====", props.isLevel);
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
if (props.isLevel == 1) { if (props.isLevel == 1) {
let editObj1 = { let editObj1 = {
chapterId: props.isactive, chapterId: props.isactive,

View File

@@ -394,6 +394,10 @@ export default {
state.EditWorkId = res.data.data.workId; state.EditWorkId = res.data.data.workId;
} else { } else {
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
let editObj1 = { let editObj1 = {
chapterId: props.isactive, chapterId: props.isactive,
courseId: res.data.data.workId, courseId: res.data.data.workId,

View File

@@ -163,6 +163,10 @@ export default {
l_data_id.push(Number(state.assessmentId)) l_data_id.push(Number(state.assessmentId))
console.log("state.assessment",state.assessment,state.assessmentId); console.log("state.assessment",state.assessment,state.assessmentId);
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
IsExistence({ IsExistence({
chapterId: Number(props.isactive), chapterId: Number(props.isactive),
courseTaskId:l_data_id, courseTaskId:l_data_id,

View File

@@ -38,21 +38,26 @@
/> />
</div> </div>
</div> </div>
<div class="main_item2"> <div class="main_item" style="margin-top: -10px">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px">直播说明</span> <div class="asterisk_icon">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
<span style="margin-right: 3px">直播链接</span>
</div> </div>
<div class="textarea"> <div class="btnbox">
<a-textarea <a-input
v-model:value="textV1" v-model:value="inputV4"
placeholder="请输入直播说明" style="width: 400px; height: 40px; border-radius: 8px;"
allow-clear placeholder="请输入直播链接"
show-count :maxlength="100"
:maxlength="200"
:rows="6"
/> />
</div> </div>
</div> </div>
<div class="main_item"> <div class="main_item">
<div class="signbox"> <div class="signbox">
<div class="sign"> <div class="sign">
@@ -148,19 +153,28 @@
</div> </div>
</div> </div>
</div> </div>
<div class="main_item" style="margin-top: -10px"> <div class="main_item2">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px">直播链接</span> <div class="asterisk_icon">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
<span style="margin-right: 3px">直播公告</span>
</div> </div>
<div class="btnbox"> <div class="textarea">
<a-input <a-textarea
v-model:value="inputV4" v-model:value="liveNotice"
style="width: 400px; height: 40px; border-radius: 8px;" placeholder="请输入直播公告"
placeholder="请输入直播链接" allow-clear
:maxlength="100" show-count
:maxlength="200"
:rows="6"
/> />
</div> </div>
</div> </div>
<div class="main_item"> <div class="main_item">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px">回放设置</span> <span style="margin-right: 3px">回放设置</span>
@@ -184,6 +198,8 @@
</div> </div>
</div> </div>
</div> </div>
<div class="main_item2"> <div class="main_item2">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px">直播说明</span> <span style="margin-right: 3px">直播说明</span>
@@ -191,7 +207,7 @@
<div class="textarea"> <div class="textarea">
<a-textarea <a-textarea
v-model:value="textV1" v-model:value="textV1"
placeholder="请输入考试说明" placeholder="请输入直播说明"
allow-clear allow-clear
show-count show-count
:maxlength="200" :maxlength="200"
@@ -270,17 +286,18 @@
</div> --> </div> -->
</div> </div>
</div> </div>
<!--
<div class="main_item"> <div class="main_item">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px">完成标准设置</span> <span style="margin-right: 3px">完成标准设置</span>
</div> </div>
<div class="btnbox"> <div class="btnbox">
<a-radio-group v-model:value="radioV1"> <a-radio-group v-model:value="radioV1">
<a-radio :value="1" @click="cloradio1">仅签到</a-radio> <a-radio :value="1" @click="cloradio1">仅签到</a-radio>-->
<!-- <a-radio :value="2" @click="cloradio1" <!-- <a-radio :value="2" @click="cloradio1"
>签到签退全部完成</a-radio >签到签退全部完成</a-radio
> --> > -->
<!--
</a-radio-group> </a-radio-group>
</div> </div>
</div> </div>
@@ -297,6 +314,8 @@
</a-checkbox> </a-checkbox>
</div> </div>
</div> </div>
-->
<div class="main_item2"> <div class="main_item2">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px">评估</span> <span style="margin-right: 3px">评估</span>
@@ -454,6 +473,7 @@ export default {
switchC1: "", switchC1: "",
checkedC1: false, checkedC1: false,
checkedC2: false, checkedC2: false,
liveNotice :null,
assessmentId: null, assessmentId: null,
obj: {}, //要传的obj数据 obj: {}, //要传的obj数据
assessment: [], //评估信息 assessment: [], //评估信息
@@ -483,6 +503,9 @@ export default {
state.needEval = false; state.needEval = false;
state.switchC2 = false; state.switchC2 = false;
state.assessmentId = null; state.assessmentId = null;
state.liveNotice =null;
state.liveTeacherId=null;
state.memberValue={};
ctx.emit("changeData", false); ctx.emit("changeData", false);
localStorage.setItem("stageId", props.chooseStageId); localStorage.setItem("stageId", props.chooseStageId);
localStorage.setItem("chapterId", props.isactive); localStorage.setItem("chapterId", props.isactive);
@@ -532,7 +555,7 @@ export default {
state.inputV8 = res.data.data.signOutTime; state.inputV8 = res.data.data.signOutTime;
state.textV1 = res.data.data.liveExplain; state.textV1 = res.data.data.liveExplain;
state.radioV1 = Number(res.data.data.standardSettings); state.radioV1 = Number(res.data.data.standardSettings);
//state.= res.data.data state.liveNotice = res.data.data.liveNotice;
state.assessmentId = res.data.data.assessmentId; state.assessmentId = res.data.data.assessmentId;
state.imageUrl = res.data.data.liveCover; state.imageUrl = res.data.data.liveCover;
state.switchC1 = res.data.data.livePlayback === "1" ? true : false; state.switchC1 = res.data.data.livePlayback === "1" ? true : false;
@@ -577,6 +600,10 @@ export default {
}; };
const updateTask = (res) => { const updateTask = (res) => {
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
RouterEditTask({ RouterEditTask({
chapterId: props.isactive, chapterId: props.isactive,
courseId: res.data.data.liveId, courseId: res.data.data.liveId,
@@ -641,6 +668,11 @@ export default {
message.destroy(); message.destroy();
return message.warning("请输入直播名称"); return message.warning("请输入直播名称");
} }
if (!state.inputV4) {
message.destroy();
return message.warning("请输入直播链接");
}
if (!state.time) { if (!state.time) {
message.destroy(); message.destroy();
return message.warning("请输入直播时间"); return message.warning("请输入直播时间");
@@ -657,6 +689,10 @@ export default {
message.destroy(); message.destroy();
return message.warning("请上传封面"); return message.warning("请上传封面");
} }
if (!state.liveNotice) {
message.destroy();
return message.warning("请输入直播公告");
}
const regular = /^[+]{0,1}(\d+)$/; const regular = /^[+]{0,1}(\d+)$/;
if (!regular.test(state.inputV2)) { if (!regular.test(state.inputV2)) {
message.destroy(); message.destroy();
@@ -682,6 +718,7 @@ export default {
liveEndTime: endTime, liveEndTime: endTime,
liveStartTime: startTime, liveStartTime: startTime,
liveExplain: state.textV1, liveExplain: state.textV1,
liveNotice:state.liveNotice,
liveFlag: "", liveFlag: "",
liveId: props.edit ? Number(props.EditLiveId) : 0, liveId: props.edit ? Number(props.EditLiveId) : 0,
liveLink: state.inputV4, liveLink: state.inputV4,

View File

@@ -36,7 +36,7 @@
/> />
<div class="inp_num" style="position: absolute; right: 7px"> <div class="inp_num" style="position: absolute; right: 7px">
<span style="color: #c7cbd2"> <span style="color: #c7cbd2">
{{ inputV1 ? inputV1.length : 0 }}/20
</span> </span>
</div> </div>
</div> </div>
@@ -464,6 +464,10 @@ export default {
const updateTask = () => { const updateTask = () => {
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
console.log("我是要便利的数据2", state.addOnlineList); console.log("我是要便利的数据2", state.addOnlineList);
let l_data = state.addOnlineList; let l_data = state.addOnlineList;
let l_data_id = []; let l_data_id = [];

View File

@@ -551,6 +551,10 @@ export default {
const updateTask = async (res) => { const updateTask = async (res) => {
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
await RouterEditTask({ await RouterEditTask({
chapterId: props.isactive, chapterId: props.isactive,
courseId: res.key, courseId: res.key,

View File

@@ -182,6 +182,10 @@ export default {
}; };
const updateTask = async (res) => { const updateTask = async (res) => {
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
RouterEditTask({ RouterEditTask({
chapterId: props.isactive, chapterId: props.isactive,
courseId: res.data.data.linkId, courseId: res.data.data.linkId,

View File

@@ -570,6 +570,10 @@ export default {
closeDrawer(); closeDrawer();
} else { } else {
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
let editObj1 = { let editObj1 = {
chapterId: props.isactive, chapterId: props.isactive,
duration: res.data.data.examinationDuration, duration: res.data.data.examinationDuration,

View File

@@ -58,6 +58,7 @@
</div> </div>
</div> </div>
</div> </div>
<!--
<div class="main_notice"> <div class="main_notice">
<div class="mntc_left"> <div class="mntc_left">
<div class="notice_icon"></div> <div class="notice_icon"></div>
@@ -101,7 +102,8 @@
</div> </div>
</div> </div>
</div> </div>-->
<div class="main_table"> <div class="main_table">
<a-table <a-table

View File

@@ -105,7 +105,7 @@
<iframe <iframe
id="iframe" id="iframe"
style="width: 100%; height: 100%" style="width: 100%; height: 100%"
:src="iframeUrl + '/exam/tests'" :src="iframeUrl + '/exam/papers'"
name="myframe" name="myframe"
sandbox="allow-forms allow-scripts allow-same-origin allow-popups" sandbox="allow-forms allow-scripts allow-same-origin allow-popups"
></iframe> ></iframe>

View File

@@ -1,10 +1,13 @@
<template> <template>
<a-input <a-input
v-model:value="modelV" v-model:value="modelV"
:placeholder="placeholder" :placeholder="placeholder"
:show-count="showCount" :show-count="showCount"
:maxlength="maxlength" :maxlength="maxlength"
:validate="validate"
@blur="validateProName" @blur="validateProName"
@change="validateProName"
/> />
<div style="color:red;font-size: 10px" v-if="value && !validate">名称重复请重新输入</div> <div style="color:red;font-size: 10px" v-if="value && !validate">名称重复请重新输入</div>
</template> </template>
@@ -18,7 +21,7 @@ const props = defineProps({
}, },
validate: { validate: {
type: Boolean, type: Boolean,
default: true default:true
}, },
id: { id: {
type: String, type: String,
@@ -55,9 +58,52 @@ watch(modelV, () => {
}) })
function validateProName() { function validateProName() {
emit('update:finished', false);
props.value && validateName({name: props.value, type: props.type, id: props.id}).then(res => { props.value && validateName({name: props.value, type: props.type, id: props.id}).then(res => {
emit('update:validate', res.data.data !== 1) emit('update:validate', res.data.data !== 1)
emit('update:finished', true);
}) })
} }
</script> </script>
<style lang="scss">
.in{
.ant-input-affix-wrapper {
position: relative;
display: inline-block;
width: 99%;
min-width: 0;
padding: 0px 17px;
color: rgba(0, 0, 0, 0.85);
font-size: 14px;
line-height: 1.5715;
background-color: #fff;
background-image: none;
border: 1px solid #d9d9d9;
border-radius: 8px;
transition: all 0.3s;
display: inline-flex;
}
}
.b_input,.i1_input{
.ant-input-affix-wrapper {
position: relative;
display: inline-block;
width: 88%;
min-width: 0;
padding: 8px 17px;
color: rgba(0, 0, 0, 0.85);
font-size: 14px;
line-height: 1.5715;
background-color: #fff;
background-image: none;
border: 1px solid #d9d9d9;
border-radius: 8px;
transition: all 0.3s;
display: inline-flex;
}
}
</style>

View File

@@ -8,7 +8,7 @@
v-model:value="id" v-model:value="id"
style="width: 100%" style="width: 100%"
:dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }"
placeholder="自动带出 可修改" placeholder="请选择归属组织"
allow-clear allow-clear
:tree-data="options" :tree-data="options"
:fieldNames="{ :fieldNames="{

View File

@@ -32,7 +32,7 @@
<div class="btnbox"> <div class="btnbox">
<a-input <a-input
v-model:value="inputV1" v-model:value="inputV1"
style="width: 424px; height: 32px" style="width: 424px; height: 40px; border-radius: 8px;"
placeholder="请输入投票任务名称" placeholder="请输入投票任务名称"
maxlength="20" maxlength="20"
/> />
@@ -102,7 +102,7 @@
</div> </div>
<span style="margin-right: 3px">起止时间</span> <span style="margin-right: 3px">起止时间</span>
</div> </div>
<div class="btnbox"> <div class="select" >
<a-range-picker <a-range-picker
show-time show-time
format="YYYY-MM-DD HH:mm:ss" format="YYYY-MM-DD HH:mm:ss"
@@ -306,6 +306,10 @@ export default {
const updateToTask = (res) => { const updateToTask = (res) => {
console.log("props.isLevel=====", props.isLevel); console.log("props.isLevel=====", props.isLevel);
if (props.isLevel == 1) { if (props.isLevel == 1) {
if(!props.isactive){
message.destroy();
return message.warning("请先选中关卡");
}
RouterEditTask({ RouterEditTask({
chapterId: props.isactive, chapterId: props.isactive,
courseId: res.data.data.voteId, courseId: res.data.data.voteId,
@@ -661,7 +665,29 @@ export default {
} }
} }
} }
.in {
element.style {
border-radius: 8px;
}
.ant-input-affix-wrapper {
position: relative;
display: inline-block;
width: 132%;
/* min-width: 19px; */
padding: 4px 11px;
color: rgba(0, 0, 0, 0.85);
font-size: 14px;
line-height: 1.5715;
background-color: #fff;
background-image: none;
border: 1px solid #d9d9d9;
border-radius: 2px;
transition: all 0.3s;
display: inline-flex;
}
}
.main_item2 { .main_item2 {
display: flex; display: flex;
align-items: flex-start; align-items: flex-start;
@@ -670,7 +696,7 @@ export default {
width: 423px; width: 423px;
.ant-input { .ant-input {
width: 100%; width:355px;
} }
.ant-input-textarea-show-count { .ant-input-textarea-show-count {

View File

@@ -145,6 +145,7 @@
placeholder="请输入课程名称" placeholder="请输入课程名称"
v-model:value="xzinputV1" v-model:value="xzinputV1"
v-model:validate="validate" v-model:validate="validate"
v-model:finished="finished"
:maxlength="20" :maxlength="20"
show-count show-count
:type="2" :type="2"
@@ -306,6 +307,7 @@
<!-- 确定新建面授课弹窗 --> <!-- 确定新建面授课弹窗 -->
<CourseModal <CourseModal
ref="CourseModalRef" ref="CourseModalRef"
v-model:xzinputV1="xzinputV1"
@visibleClose="closeOnlineCoursevisible" @visibleClose="closeOnlineCoursevisible"
/> />
<!-- 查看面授课弹框 start --> <!-- 查看面授课弹框 start -->
@@ -364,6 +366,7 @@
placeholder="请输入课程名称" placeholder="请输入课程名称"
v-model:value="qdms_inputV1" v-model:value="qdms_inputV1"
v-model:validate="validate" v-model:validate="validate"
v-model:finished="finished"
:maxlength="20" :maxlength="20"
show-count show-count
:type="2" :type="2"
@@ -628,8 +631,8 @@
<span style="margin-right: 14px">授课教师</span> <span style="margin-right: 14px">授课教师</span>
</div> </div>
<div class="item_inp"> <div class="item_inp">
<div class="i1_input"> <div class="select" style="width:436px; " >
<ProjectManager <ProjectManager
v-model:value="member.value" v-model:value="member.value"
v-model:name="member.name" v-model:name="member.name"
></ProjectManager> ></ProjectManager>
@@ -2010,18 +2013,20 @@
/> />
</div> </div>
</div> </div>
<!--
<div class="cstm_items"> <div class="cstm_items">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px">完成规则</span> <span style="margin-right: 3px">完成规则</span>
</div> </div>
<div class="b_input"> <div class="b_input">
<!--
<a-checkbox <a-checkbox
v-model:checked="regisCom" v-model:checked="regisCom"
@click="regisCom = !regisCom" @click="regisCom = !regisCom"
> >
<span style="color: #6d7584">报名即完成</span> <span style="color: #6d7584">报名即完成</span>
</a-checkbox> --> </a-checkbox> -->
<!--
<a-checkbox v-model:checked="signCom" @click="signCom = !signCom"> <a-checkbox v-model:checked="signCom" @click="signCom = !signCom">
<span style="color: #6d7584">签到即完成</span> <span style="color: #6d7584">签到即完成</span>
</a-checkbox> </a-checkbox>
@@ -2032,7 +2037,7 @@
<span style="color: #6d7584">请假算完成</span> <span style="color: #6d7584">请假算完成</span>
</a-checkbox> </a-checkbox>
</div> </div>
</div> </div> -->
<div class="cstm_items items_fj"> <div class="cstm_items items_fj">
<div class="signbox"> <div class="signbox">
<span style="margin-right: 3px">附件</span> <span style="margin-right: 3px">附件</span>
@@ -2145,6 +2150,9 @@
</div> </div>
</div> </div>
</div> </div>
<div class="aeLoading" :style="{ display: addLoading ? 'flex' : 'none' }">
<a-spin :spinning="addLoading" tip="" />
</div>
</a-modal> </a-modal>
<!--新建开课页面 --> <!--新建开课页面 -->
<!--开课学员管理页面 --> <!--开课学员管理页面 -->
@@ -2793,6 +2801,7 @@ import {
onBeforeUnmount, onBeforeUnmount,
watch, watch,
} from "vue"; } from "vue";
import * as api from "../../api/indexInvist.js"; import * as api from "../../api/indexInvist.js";
import { message } from "ant-design-vue"; import { message } from "ant-design-vue";
@@ -3547,7 +3556,7 @@ export default defineComponent({
value4: "", value4: "",
//选择线上还是面授 //选择线上还是面授
xzinputV1: "", xzinputV1: "",
valueE1: 2, valueE1: "",
valueE2: "", valueE2: "",
//确定面授 //确定面授
ft_eidt: false, ft_eidt: false,
@@ -3591,7 +3600,7 @@ export default defineComponent({
imageUrl: "", imageUrl: "",
imgList: [], imgList: [],
validate: true, validate:false,
pageSize2: 10, pageSize2: 10,
currentPage2: 0, currentPage2: 0,
@@ -3638,6 +3647,7 @@ export default defineComponent({
codevisible: false, //二维码弹窗 codevisible: false, //二维码弹窗
codeInfo: null, //二维码内容 codeInfo: null, //二维码内容
codeUrl: codeUrl, codeUrl: codeUrl,
finished:false,
// 课程三级分类 // 课程三级分类
options2222: [ options2222: [
{ {
@@ -4540,15 +4550,26 @@ export default defineComponent({
message.destroy(); message.destroy();
return message.warning("请输入必填项"); return message.warning("请输入必填项");
} }
if (!state.validate) {
console.log("state.validate",state.validate);
if(!state.finished){
return;
}
if (!state.validate && state.finished) {
message.destroy(); message.destroy();
return message.warning("路径图名称重复"); return message.warning("该课程名称已存在");
} }
console.log( console.log(
"state.bs_hs && state.valueE1 == 2", "state.bs_hs && state.valueE1 == 2",
state.bs_hs, state.bs_hs,
state.valueE1 == 2 state.valueE1 == 2
); );
if( !state.valueE1 && !state.valueE2){
message.destroy();
return message.warning("请选择课程形式");
}
if (state.valueE1 === 2) { if (state.valueE1 === 2) {
state.of_hs = false; state.of_hs = false;
@@ -4659,7 +4680,7 @@ export default defineComponent({
} }
if (!state.validate) { if (!state.validate) {
message.destroy(); message.destroy();
return message.warning("路径图名称重复"); return message.warning("面授课名称重复");
} }
edit(postData).then((res) => { edit(postData).then((res) => {
if (res.data.code === 200) { if (res.data.code === 200) {
@@ -4713,6 +4734,7 @@ export default defineComponent({
}; };
//保存开课 //保存开课
const handleSureStu = () => { const handleSureStu = () => {
state.addLoading = true;
let startTime, let startTime,
endTime = 0; endTime = 0;
if (state.xjkkinputV3) { if (state.xjkkinputV3) {
@@ -5772,7 +5794,7 @@ export default defineComponent({
} }
.aeLoading { .aeLoading {
z-index: 10000; z-index: 100000;
} }
.courseManage { .courseManage {

View File

@@ -81,7 +81,7 @@
</div> </div>
</div> </div>
</div> </div>
<div v-if="detail.meaning" class="mbl_items"> <div v-if="detail.meaning" class="mbl_items2">
<div class="item_nam"> <div class="item_nam">
<span style="margin-right: 14px">课程价值</span> <span style="margin-right: 14px">课程价值</span>
</div> </div>

View File

@@ -378,6 +378,9 @@
</div> </div>
</div> </div>
</div> </div>
<div class="aeLoading" :style="{ display: addLoading ? 'flex' : 'none' }">
<a-spin :spinning="addLoading" tip="" />
</div>
</a-modal> </a-modal>
</template> </template>
<script> <script>
@@ -390,6 +393,7 @@ import {
// onMounted, // onMounted,
onUnmounted, onUnmounted,
} from "vue"; } from "vue";
import {validateName} from "@/api/index1";
import {message} from "ant-design-vue"; import {message} from "ant-design-vue";
import {edit, detail, handle} from "@/api/indexCourse"; import {edit, detail, handle} from "@/api/indexCourse";
import {fileUp} from "../../api/indexEval"; import {fileUp} from "../../api/indexEval";
@@ -402,6 +406,7 @@ import FJUpload from "@/components/common/FJUpload";
import * as moment from "moment"; import * as moment from "moment";
import * as api2 from "../../api/indexAudit"; import * as api2 from "../../api/indexAudit";
export default defineComponent({ export default defineComponent({
components: { components: {
Editor, Editor,
@@ -410,12 +415,18 @@ export default defineComponent({
NameInput, NameInput,
ProjectManager, ProjectManager,
}, },
props: {
xzinputV1: {
type: String,
default: null,
},
},
setup(props, {expose, emit}) { setup(props, {expose, emit}) {
const state = reactive({ const state = reactive({
hideshow: true, hideshow: true,
ft_eidt: false, ft_eidt: false,
attach: "", attach: "",
validate: true, validate:false,
ft_hs: false, ft_hs: false,
addLoading: false, addLoading: false,
statusJuJue: 0, statusJuJue: 0,
@@ -572,6 +583,7 @@ export default defineComponent({
state.ft_hs = true; state.ft_hs = true;
state.ft_eidt = false; state.ft_eidt = false;
state.qdms_inputV1 = name; state.qdms_inputV1 = name;
console.log(" state.qdms_inputV1 ",state.qdms_inputV1 );
} }
}; };
const visibleClose = () => { const visibleClose = () => {
@@ -763,7 +775,8 @@ export default defineComponent({
}; };
//保存面授课 //保存面授课
const handlePush = (param) => { const handlePush = async (param) => {
let files = ""; let files = "";
if (state.imgList.length) { if (state.imgList.length) {
state.imgList.forEach((item) => { state.imgList.forEach((item) => {
@@ -772,6 +785,15 @@ export default defineComponent({
} }
files = files.slice(0, files.length - 1); files = files.slice(0, files.length - 1);
console.log("filesfiles", files); console.log("filesfiles", files);
const offName = await validateName({name: state.qdms_inputV1, type:2, id:state.offcourseId}).then(res => {
return res.data.data == 1;
});
if(offName){
message.destroy();
return message.warning("课程名称重复,请重新填写");
}
const postData = { const postData = {
offcourseId: state.offcourseId, //不传代表新增 offcourseId: state.offcourseId, //不传代表新增
name: state.qdms_inputV1, name: state.qdms_inputV1,
@@ -794,6 +816,7 @@ export default defineComponent({
postData.targetUser, postData.targetUser,
postData.categoryId, postData.categoryId,
postData.teacherId, postData.teacherId,
postData.picUrl,
]; ];
if (!checkVal(checkList)) { if (!checkVal(checkList)) {
message.destroy(); message.destroy();
@@ -803,9 +826,8 @@ export default defineComponent({
} }
edit(postData).then((res) => { edit(postData).then((res) => {
state.addLoading = false;
if (res.data.code === 200) { if (res.data.code === 200) {
state.addLoading = false;
state.statusTingQi = 1; state.statusTingQi = 1;
if (param === "review") { if (param === "review") {
//新建时点击审核按钮 //新建时点击审核按钮
@@ -815,12 +837,22 @@ export default defineComponent({
message.success("保存成功"); message.success("保存成功");
visibleClose(); visibleClose();
} }
}else if(res.data.code === -1){
message.destroy();
message.success("无此操作权限");
visibleClose();
} }
}); });
}; };
//编辑面授课渲染绑定 //编辑面授课渲染绑定
const handleEditInfo = async (offcourseId) => { const handleEditInfo = async (offcourseId) => {
console.log("jjjaj");
state.validate =true;
state.qdms_inputV1 = "";
const item = await detail({ const item = await detail({
offcourseId: Number(offcourseId), offcourseId: Number(offcourseId),
}).then((res) => { }).then((res) => {
@@ -903,6 +935,9 @@ export default defineComponent({
message.success("已提交审核"); message.success("已提交审核");
state.addLoading = false; state.addLoading = false;
visibleClose(); visibleClose();
}else if(res.data.code === -1){
message.destroy();
message.success("无此操作权限");
} }
}); });
}; };
@@ -1338,5 +1373,8 @@ export default defineComponent({
margin-right: 10px; margin-right: 10px;
border-radius: 8px; border-radius: 8px;
} }
.aeLoading {
z-index: 10000;
}
} }
</style> </style>

View File

@@ -106,12 +106,12 @@
</div> </div>
<div class="body"> <div class="body">
<a-table <a-table
style="width: 90%" style="width:100%"
:columns="columnsAudit" :columns="columnsAudit"
:data-source="tableDataAudit" :data-source="tableDataAudit"
:loading="tableDataTotalAudit === -1 ? true : false" :loading="tableDataTotalAudit === -1 ? true : false"
expandRowByClick="true" expandRowByClick="true"
:scroll="{ y: 150 }" :scroll="{ y: 250 }"
@expand="expandTable" @expand="expandTable"
:pagination="false" :pagination="false"
/> />
@@ -153,6 +153,8 @@ export default {
dataIndex: "createName", dataIndex: "createName",
key: "createName", key: "createName",
align: "center", align: "center",
width:"20%",
ellipsis: true,
}, },
{ {
@@ -160,6 +162,7 @@ export default {
dataIndex: "status", dataIndex: "status",
key: "status", key: "status",
align: "center", align: "center",
width:"20%",
customRender: ({ record: { status } }) => ( customRender: ({ record: { status } }) => (
<div>{{ 2: "审核通过", "-2": "审核拒绝" }[status + ""]}</div> <div>{{ 2: "审核通过", "-2": "审核拒绝" }[status + ""]}</div>
), ),
@@ -170,7 +173,8 @@ export default {
dataIndex: "createTime", dataIndex: "createTime",
key: "createTime", key: "createTime",
align: "center", align: "center",
width: 220, width:"20%",
ellipsis: true,
}, },
{ {
@@ -178,6 +182,8 @@ export default {
dataIndex: "description", dataIndex: "description",
key: "description", key: "description",
align: "center", align: "center",
width:"30%",
ellipsis: true,
}, },
], ],
columns1: [ columns1: [
@@ -192,36 +198,47 @@ export default {
dataIndex: "name", dataIndex: "name",
key: "name", key: "name",
align: "center", align: "center",
width:"20%",
ellipsis: true,
}, },
{ {
title: "类型", title: "类型",
dataIndex: "type", dataIndex: "type",
key: "type", key: "type",
align: "center", align: "center",
width:"10%",
ellipsis: true,
}, },
{ {
title: "内容分类", title: "内容分类",
dataIndex: "content", dataIndex: "content",
key: "content", key: "content",
align: "center" align: "center",
width:"10%",
ellipsis: true,
}, },
{ {
title: "审核状态", title: "审核状态",
dataIndex: "status", dataIndex: "status",
key: "status", key: "status",
align: "center", align: "center",
width:"10%",
}, },
{ {
title: "创建人", title: "创建人",
dataIndex: "creater", dataIndex: "creater",
key: "creater", key: "creater",
align: "center", align: "center",
width:"10%",
ellipsis: true,
}, },
{ {
title: "审核时间", title: "审核时间",
dataIndex: "time", dataIndex: "time",
key: "time", key: "time",
align: "center", align: "center",
width:"10%",
ellipsis: true,
customRender: (time) => { customRender: (time) => {
return <div style="color:#387DF7">{time.record.time}</div>; return <div style="color:#387DF7">{time.record.time}</div>;
}, },
@@ -231,11 +248,14 @@ export default {
dataIndex: "msg", dataIndex: "msg",
key: "msg", key: "msg",
align: "center", align: "center",
ellipsis: true,
width:"20%",
}, },
{ {
title: "操作", title: "操作",
dataIndex: "opt", dataIndex: "opt",
key: "opt", key: "opt",
width:"10%",
align: "center", align: "center",
customRender: (value) => { customRender: (value) => {
return ( return (
@@ -243,7 +263,7 @@ export default {
style="color:#387DF7;cursor:pointer;" style="color:#387DF7;cursor:pointer;"
onClick={() => { onClick={() => {
console.log(value); console.log(value);
showProjAuditModal(value.record.auditLogDtoList.length!==0?value.record.auditLogDtoList.slice(0,1):[]); showProjAuditModal(value.record.auditLogDtoList.length!==0?value.record.auditLogDtoList:[]);
}} }}
> >
审核日志 审核日志
@@ -691,7 +711,7 @@ export default {
.delete { .delete {
z-index: 999; z-index: 999;
width: 816px; width: 816px;
min-height: 420px; min-height: 485px;
background: #ffffff; background: #ffffff;
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21); box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21);
border-radius: 4px; border-radius: 4px;

View File

@@ -14,13 +14,33 @@
<div class="tmplh_inp"> <div class="tmplh_inp">
<div class="inpbox"> <div class="inpbox">
<div class="inpbox1"> <div class="inpbox1">
<!--
<a-select <a-select
v-model:value="valueproj" v-model:value="categoryId"
:options="[ :options="[
{ label: '请选择内容分类', value: '' }, { label: '请选择内容分类', value: '' },
...calssifyList, ...calssifyList,
]" ]"
/> />-->
<a-tree-select
:getPopupContainer="
(triggerNode) => {
return triggerNode.parentNode || document.body;
}
"
v-model:value="categoryId"
show-search
:dropdown-style="{ maxHeight: '400px', overflow: 'auto' }"
placeholder="请选择内容分类"
allow-clear
tree-default-expand-all
:tree-data="options2222"
>
<template #title="{ value: val, title }">
<b v-if="val === '11111'" style="color: #08c">sss</b>
<template v-else>{{ title }}</template>
</template>
</a-tree-select>
</div> </div>
<div class="inpbox1"> <div class="inpbox1">
<a-input <a-input
@@ -193,7 +213,7 @@ export default {
}, },
], ],
calssifyList: [], //分类字典 calssifyList: [], //分类字典
valueproj: "", categoryId: "",
valuecreater: "", valuecreater: "",
valuename: "", valuename: "",
// currentFacePage: 1, // currentFacePage: 1,
@@ -221,24 +241,30 @@ export default {
dataIndex: "name", dataIndex: "name",
key: "name", key: "name",
align: "center", align: "center",
ellipsis: true,
width:"20%",
}, },
{ {
title: "类型", title: "类型",
dataIndex: "type", dataIndex: "type",
key: "type", key: "type",
align: "center", align: "center",
width:"10%",
}, },
{ {
title: "内容分类", title: "内容分类",
dataIndex: "content", dataIndex: "content",
key: "content", key: "content",
align: "center" align: "center",
ellipsis: true,
width:"10%",
}, },
{ {
title: "状态", title: "状态",
dataIndex: "status", dataIndex: "status",
key: "status", key: "status",
align: "center", align: "center",
width:"10%",
}, },
// { // {
// title: "转审", // title: "转审",
@@ -251,12 +277,16 @@ export default {
dataIndex: "creater", dataIndex: "creater",
key: "creater", key: "creater",
align: "center", align: "center",
ellipsis: true,
width:"15%",
}, },
{ {
title: "创建时间", title: "创建时间",
dataIndex: "time", dataIndex: "time",
key: "time", key: "time",
align: "center", align: "center",
ellipsis: true,
width:"15%",
}, },
{ {
@@ -264,6 +294,7 @@ export default {
dataIndex: "opt", dataIndex: "opt",
key: "opt", key: "opt",
align: "center", align: "center",
width:"20%",
customRender: (value) => { customRender: (value) => {
return ( return (
<div> <div>
@@ -457,7 +488,7 @@ export default {
state.loading=true state.loading=true
let objn = { let objn = {
auditStatus: 1, auditStatus: 1,
categoryId: state.valueproj, categoryId: state.categoryId,
createName: state.valuecreater, createName: state.valuecreater,
name: state.valuename, name: state.valuename,
pageNo: state.currentPage, pageNo: state.currentPage,
@@ -526,7 +557,7 @@ export default {
const searchList = () => { const searchList = () => {
let objn = { let objn = {
auditStatus: 1, auditStatus: 1,
categoryId: state.valueproj, categoryId: state.categoryId,
createName: state.valuecreater, createName: state.valuecreater,
name: state.valuename, name: state.valuename,
pageNo: state.currentPage, pageNo: state.currentPage,
@@ -591,7 +622,7 @@ export default {
state.tableData1 = array; state.tableData1 = array;
}; };
const reset = () => { const reset = () => {
state.valueproj = ""; state.categoryId = "";
state.valuecreater = null; state.valuecreater = null;
state.valuename = null; state.valuename = null;
getFaceList(); getFaceList();

View File

@@ -122,12 +122,12 @@
</div> </div>
<div class="body"> <div class="body">
<a-table <a-table
style="width: 90%" style="width: 100%"
:columns="columnsAudit" :columns="columnsAudit"
:data-source="tableDataAudit" :data-source="tableDataAudit"
:loading="tableDataTotalAudit === -1 ? true : false" :loading="tableDataTotalAudit === -1 ? true : false"
expandRowByClick="true" expandRowByClick="true"
:scroll="{ y: 150 }" :scroll="{ y: 250 }"
@expand="expandTable" @expand="expandTable"
:pagination="false" :pagination="false"
/> />
@@ -188,6 +188,8 @@ export default {
dataIndex: "name", dataIndex: "name",
key: "name", key: "name",
align: "center", align: "center",
ellipsis: true,
width:"20%",
}, },
{ {
@@ -195,7 +197,8 @@ export default {
dataIndex: "topName", dataIndex: "topName",
key: "topName", key: "topName",
align: "center", align: "center",
width: "10%", ellipsis: true,
width:"20%",
customRender: ({ record: { gaName, faName, name } }) => ( customRender: ({ record: { gaName, faName, name } }) => (
<div> <div>
{faName {faName
@@ -211,12 +214,16 @@ export default {
dataIndex: "manager", dataIndex: "manager",
key: "manager", key: "manager",
align: "center", align: "center",
ellipsis: true,
width:"10%",
}, },
{ {
title: "审核状态", title: "审核状态",
dataIndex: "status", dataIndex: "status",
key: "status", key: "status",
align: "center", align: "center",
ellipsis: true,
width:"10%",
customRender: ({ record: { status } }) => ( customRender: ({ record: { status } }) => (
<div>{{ '2': "审核通过", "-5": "未通过" }[status + ""] || '审核通过'}</div> <div>{{ '2': "审核通过", "-5": "未通过" }[status + ""] || '审核通过'}</div>
), ),
@@ -226,18 +233,25 @@ export default {
dataIndex: "createName", dataIndex: "createName",
key: "createName", key: "createName",
align: "center", align: "center",
ellipsis: true,
width:"10%",
}, },
{ {
title: "审核时间", title: "审核时间",
dataIndex: "updateTime", dataIndex: "updateTime",
key: "updateTime", key: "updateTime",
align: "center", align: "center",
ellipsis: true,
width:"10%",
}, },
{ {
title: "审核说明", title: "审核说明",
dataIndex: "description", dataIndex: "description",
key: "description", key: "description",
align: "center", align: "center",
ellipsis: true,
width:"20%",
customRender: ({ record: { auditList, description } }) => ( customRender: ({ record: { auditList, description } }) => (
<div> <div>
{auditList.length !== 0 {auditList.length !== 0
@@ -256,12 +270,14 @@ export default {
dataIndex: "opt", dataIndex: "opt",
key: "opt", key: "opt",
align: "center", align: "center",
width:"10%",
customRender: (value) => { customRender: (value) => {
return ( return (
<div> <div>
<span <span
onClick={() => { onClick={() => {
showProjAuditModal(value.record.auditList.length!==0?value.record.auditList.slice(value.record.auditList.length-1):[]); showProjAuditModal(value.record.auditList.length!==0?value.record.auditList:[]);
}} }}
style="cursor:pointer;color:#387DF7" style="cursor:pointer;color:#387DF7"
> >
@@ -413,7 +429,7 @@ export default {
.delete { .delete {
z-index: 999; z-index: 999;
width: 816px; width: 816px;
min-height: 420px; min-height: 510px;
background: #ffffff; background: #ffffff;
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21); box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21);
border-radius: 4px; border-radius: 4px;
@@ -463,7 +479,7 @@ export default {
.body { .body {
width: 100%; width: 100%;
margin: 34px auto 56px auto; margin: 34px auto 41px auto;
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;

View File

@@ -148,6 +148,8 @@ export default {
dataIndex: "name", dataIndex: "name",
key: "name", key: "name",
align: "center", align: "center",
ellipsis: true,
width:"20%",
}, },
// todo 根项目保存 // todo 根项目保存
// { // {
@@ -162,12 +164,16 @@ export default {
dataIndex: "manager", dataIndex: "manager",
key: "manager", key: "manager",
align: "center", align: "center",
ellipsis: true,
width:"10%",
}, },
{ {
title: "审核状态", title: "审核状态",
dataIndex: "status", dataIndex: "status",
key: "status", key: "status",
align: "center", align: "center",
ellipsis: true,
width:"10%",
customRender: () => <div>待审核</div>, customRender: () => <div>待审核</div>,
}, },
{ {
@@ -175,12 +181,16 @@ export default {
dataIndex: "createName", dataIndex: "createName",
key: "createName", key: "createName",
align: "center", align: "center",
ellipsis: true,
width:"10%",
}, },
{ {
title: "创建时间", title: "提交时间",
dataIndex: "processTime", dataIndex: "processTime",
key: "processTime", key: "processTime",
align: "center", align: "center",
ellipsis: true,
width:"10%",
}, },
{ {
@@ -188,6 +198,8 @@ export default {
dataIndex: "opt", dataIndex: "opt",
key: "opt", key: "opt",
align: "center", align: "center",
ellipsis: true,
width:"20%",
customRender: (value) => { customRender: (value) => {
return ( return (
<div> <div>

View File

@@ -277,7 +277,7 @@
/> />
</div> </div>
<div class="inname">路径图名称</div> <div class="inname">路径图名称</div>
<div class="in"> <div class="in" >
<!-- <a-input--> <!-- <a-input-->
<!-- v-model:value="pathName"--> <!-- v-model:value="pathName"-->
<!-- maxlength="20"--> <!-- maxlength="20"-->
@@ -1736,6 +1736,7 @@ export default {
state.searchdate = null; state.searchdate = null;
state.startTime = null; state.startTime = null;
state.endTime = null; state.endTime = null;
state.createUser=null;
getLearnPath(); getLearnPath();
}; };

View File

@@ -4,9 +4,9 @@
<div class="left clearfix"> <div class="left clearfix">
<div class="leftmain"> <div class="leftmain">
<div class="tit" style="margin-left: 18px">关卡</div> <div class="tit" style="margin-left: 18px">关卡</div>
<div class="btn btn3" style="margin-left: 19px"> <div class="btn btn3" @click="showModal()" style="margin-left: 19px">
<div class="search"></div> <div class="search"></div>
<div class="btnText" @click="showModal()">添加关卡</div> <div class="btnText">添加关卡</div>
</div> </div>
<div class="maincon" style="background-color: #fff"> <div class="maincon" style="background-color: #fff">
<!-- <div <!-- <div
@@ -1248,6 +1248,7 @@ export default {
console.log("修改成功", res); console.log("修改成功", res);
message.success("修改成功"); message.success("修改成功");
state.addLoading = false; state.addLoading = false;
localStorage.setItem("chapterId", res.data.data.chapterId);
getDetail(); getDetail();
closeModal(); closeModal();
}) })
@@ -1276,6 +1277,7 @@ export default {
//state.currentPage = 1; //state.currentPage = 1;
// getLearnPath(); // getLearnPath();
state.addLoading = false; state.addLoading = false;
localStorage.setItem("chapterId", res.data.data.chapterId);
getDetail(); getDetail();
closeModal(); closeModal();
}) })
@@ -1303,10 +1305,22 @@ export default {
api api
.deleteChapter(obj) .deleteChapter(obj)
.then((res) => { .then((res) => {
console.log("删除关卡成功", res); if(res.data.code==200){
message.success("删除关卡成功"); console.log("删除关卡成功", res);
closeDeleteChapter(); message.destroy();
getDetail(); message.success("删除关卡成功");
let chapter = localStorage.getItem("chapterId")
if(state.deleteChapterId == chapter){
localStorage.removeItem("chapterId")
}
closeDeleteChapter();
getDetail();
}else if(res.data.code==-1){
message.destroy();
message.success("至少保留一个关卡");
closeDeleteChapter();
}
}) })
.catch((err) => { .catch((err) => {
console.log("删除关卡失败", err); console.log("删除关卡失败", err);
@@ -1448,7 +1462,7 @@ export default {
? JSON.parse(localStorage.getItem("chapterId")) ? JSON.parse(localStorage.getItem("chapterId"))
: null; : null;
console.log("chapter", chapter); console.log("chapter", chapter);
if (chapter) { if (chapter >0) {
dataAssignment(chapter); //用哪个的任务表 dataAssignment(chapter); //用哪个的任务表
state.isactive = chapter; //哪个亮 state.isactive = chapter; //哪个亮
} else { } else {