|
@@ -981,7 +981,7 @@
|
|
|
item1.type == 13 ||
|
|
|
item1.type == 7
|
|
|
" :placeholder="item1.name" @click.stop="
|
|
|
- checkChpater2($event, index1 )
|
|
|
+ checkChpater3($event, index1, item1)
|
|
|
" style="
|
|
|
border: none;
|
|
|
outline: none;
|
|
@@ -1027,7 +1027,7 @@
|
|
|
<div class="chapter_upload_ic">
|
|
|
<div class="chapter_upload_noSee" v-if="item1.type == 12"></div>
|
|
|
<div class="chapter_upload_ic_check" v-if="item1.type == 3" @click.stop="
|
|
|
- checkChpater3($event, index1 )
|
|
|
+ checkChpater3($event, index1, item1)
|
|
|
">
|
|
|
<div></div>
|
|
|
</div>
|
|
@@ -5487,6 +5487,146 @@
|
|
|
<el-input v-model="testJson.testTitle" placeholder="请输入标题" style="width: 400px"></el-input>
|
|
|
</div> -->
|
|
|
<div class="a_addBox" style="height: 100%">
|
|
|
+ <div style="flex-wrap: wrap; position:relative;margin:10px 0;">
|
|
|
+ <button class="c_pub_button_confirm2" @click="addImg($event)" style="margin: 0px;">
|
|
|
+ 上传补充资料
|
|
|
+ <input type="file" accept=".docx,.doc,.ppt,.pptx,.md,.txt,.pdf" style="display: none" v-if="inputShow" @change="
|
|
|
+ beforeUploadInfo2(
|
|
|
+ $event,
|
|
|
+ 17
|
|
|
+ )
|
|
|
+ " />
|
|
|
+ </button>
|
|
|
+ <div style="margin-top: 10px;width:100%" v-if="xuanzeInfoData.length">
|
|
|
+ <div class="add_chapters_box add_c_none" v-if="
|
|
|
+ xuanzeInfoData &&
|
|
|
+ xuanzeInfoData.length == 0
|
|
|
+ ">
|
|
|
+ <img src="../../../assets/icon/new/c_none.png" alt /><span>暂时还没有内容,快去添加吧</span>
|
|
|
+ </div>
|
|
|
+ <div v-else class="add_chapters_box" style="display: flex; flex-direction: column">
|
|
|
+ <div class="chapter_upload" v-for="(item1, index1) in xuanzeInfoData" :key="item1.id" @click="
|
|
|
+ getChapterData(
|
|
|
+ $event,
|
|
|
+ index1,
|
|
|
+ item1.type
|
|
|
+ )
|
|
|
+ " >
|
|
|
+ <div class="chapter_upload_o" style="
|
|
|
+ position: relative;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ ">
|
|
|
+ <div class="chapter_upload_l" style="padding: 1px 0 0 10px">
|
|
|
+ <div v-if="item1.type == 2" class="chapter_upload_l_i2"></div>
|
|
|
+ <div v-if="item1.type == 3" class="chapter_upload_l_i3" style="margin-left: 1px">
|
|
|
+ </div>
|
|
|
+ <div v-if="item1.type == 6" class="chapter_upload_l_i6" style="margin-left: 1px">
|
|
|
+ </div>
|
|
|
+ <!-- <div v-if="item1.type == 7" class="chapter_upload_l_i8" style="margin-left: 1px"></div> -->
|
|
|
+ <div v-if="item1.type == 8" class="chapter_upload_l_i8" style="margin-left: 1px">
|
|
|
+ </div>
|
|
|
+ <div v-if="item1.type == 14" class="chapter_upload_l_i14" style="margin-left: 1px">
|
|
|
+ </div>
|
|
|
+ <div v-if="item1.type == 12" class="chapter_upload_l_i12" style="margin-left: 1px">
|
|
|
+ </div>
|
|
|
+ <div v-if="item1.type == 13" class="chapter_upload_l_i13" style="margin-left: 1px">
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="chapter_upload_n">
|
|
|
+ <input readonly="true" v-if="
|
|
|
+ item1.type == 2 ||
|
|
|
+ item1.type == 3 ||
|
|
|
+ item1.type == 12 ||
|
|
|
+ item1.type == 13 ||
|
|
|
+ item1.type == 7
|
|
|
+ " :placeholder="item1.name" @click.stop="
|
|
|
+ checkChpater3($event, index1, item1)
|
|
|
+ " style="
|
|
|
+ border: none;
|
|
|
+ outline: none;
|
|
|
+ width: 80%;
|
|
|
+ minwidth: 215px;
|
|
|
+ z-index: 99;
|
|
|
+ font-size: 14px;
|
|
|
+ white-space: nowrap;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+ " />
|
|
|
+ <input :placeholder="item1.name" v-if="item1.type == 6" style="
|
|
|
+ border: none;
|
|
|
+ outline: none;
|
|
|
+ width: 80%;
|
|
|
+ white-space: nowrap;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+ " readonly="true" @click="
|
|
|
+ selectAttText(index1)
|
|
|
+ " />
|
|
|
+ <input :placeholder="item1.title ? item1.title : '链接'
|
|
|
+ " v-if="item1.type == 8" style="
|
|
|
+ border: none;
|
|
|
+ outline: none;
|
|
|
+ width: 80%;
|
|
|
+ white-space: nowrap;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+ " readonly="true" @click="selectLine(index1)" />
|
|
|
+ <input :placeholder="item1.title ? item1.title : '链接'
|
|
|
+ " v-if="item1.type == 14" style="
|
|
|
+ border: none;
|
|
|
+ outline: none;
|
|
|
+ width: 80%;
|
|
|
+ white-space: nowrap;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+ " readonly="true" @click="
|
|
|
+ openUpdateSource(index1)
|
|
|
+ " />
|
|
|
+ </div>
|
|
|
+ <div class="chapter_upload_ic">
|
|
|
+ <div class="chapter_upload_noSee" v-if="item1.type == 12"></div>
|
|
|
+ <div class="chapter_upload_ic_check" v-if="item1.type == 3" @click.stop="
|
|
|
+ checkChpater3($event, index1, item1)
|
|
|
+ ">
|
|
|
+ <div></div>
|
|
|
+ </div>
|
|
|
+ <div class="chapter_upload_ic_r" @click.stop="
|
|
|
+ deletexuanzeInfoData(
|
|
|
+ $event,
|
|
|
+ index1
|
|
|
+ )
|
|
|
+ ">
|
|
|
+ <div></div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div v-if="
|
|
|
+ xuanzeinfoproVisible
|
|
|
+ " class="mask">
|
|
|
+ <div class="progressBox">
|
|
|
+ <div class="lbox">
|
|
|
+ <img src="../../../assets/loading.gif" />上传中,请稍后
|
|
|
+ </div>
|
|
|
+ <div style="margin-bottom: 10px">
|
|
|
+ <span>{{
|
|
|
+ xuanzeinfoisFinishSize
|
|
|
+ }}M</span>
|
|
|
+ /
|
|
|
+ <span>{{
|
|
|
+ xuanzeinfoisAllSize
|
|
|
+ }}M</span>
|
|
|
+ </div>
|
|
|
+ <el-progress :text-inside="true" :stroke-width="20" :percentage="xuanzeinfoprogress
|
|
|
+ ? xuanzeinfoprogress
|
|
|
+ : 0
|
|
|
+ " style="width: 80%"></el-progress>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
<div style="
|
|
|
font-size: 16px;
|
|
|
color: #c7c7c7;
|
|
@@ -6996,6 +7136,11 @@ export default {
|
|
|
mubiaoinfoisFinishSize: 0,
|
|
|
mubiaoinfoisAllSize: 0,
|
|
|
mubiaoinfoprogress: 0,
|
|
|
+ xuanzeInfoData: [],
|
|
|
+ xuanzeinfoproVisible: false,
|
|
|
+ xuanzeinfoisFinishSize: 0,
|
|
|
+ xuanzeinfoisAllSize: 0,
|
|
|
+ xuanzeinfoprogress: 0,
|
|
|
};
|
|
|
},
|
|
|
directives: {
|
|
@@ -9350,11 +9495,16 @@ export default {
|
|
|
_this.teacherinfoproVisible = true;
|
|
|
_this.teacherinfoisFinishSize = 0;
|
|
|
_this.teacherinfoisAllSize = (file.size / 1024 / 1024).toFixed(2);
|
|
|
- }else if(type == 16){
|
|
|
+ }else if(type == 16){
|
|
|
_this.mubiaoinfoprogress = 0;
|
|
|
_this.mubiaoinfoproVisible = true;
|
|
|
_this.mubiaoinfoisFinishSize = 0;
|
|
|
_this.mubiaoinfoisAllSize = (file.size / 1024 / 1024).toFixed(2);
|
|
|
+ }else if(type == 17){
|
|
|
+ _this.xuanzeinfoprogress = 0;
|
|
|
+ _this.xuanzeinfoproVisible = true;
|
|
|
+ _this.xuanzeinfoisFinishSize = 0;
|
|
|
+ _this.xuanzeinfoisAllSize = (file.size / 1024 / 1024).toFixed(2);
|
|
|
}else{
|
|
|
_this.infoprogress = 0;
|
|
|
_this.infoproVisible = true;
|
|
@@ -9391,6 +9541,9 @@ export default {
|
|
|
}else if(type == 16){
|
|
|
_this.mubiaoinfoprogress = parseInt((evt.loaded / evt.total) * 100);
|
|
|
_this.mubiaoinfoisFinishSize = (evt.loaded / 1024 / 1024).toFixed(2);
|
|
|
+ }else if(type == 17){
|
|
|
+ _this.xuanzeinfoprogress = parseInt((evt.loaded / evt.total) * 100);
|
|
|
+ _this.xuanzeinfoisFinishSize = (evt.loaded / 1024 / 1024).toFixed(2);
|
|
|
}else {
|
|
|
_this.infoprogress = parseInt((evt.loaded / evt.total) * 100);
|
|
|
_this.infoisFinishSize = (evt.loaded / 1024 / 1024).toFixed(2);
|
|
@@ -9405,6 +9558,9 @@ export default {
|
|
|
}else if(type == 16){
|
|
|
_this.mubiaoinfoprogress = 100;
|
|
|
_this.mubiaoinfoisFinishSize = _this.mubiaoinfoisAllSize;
|
|
|
+ }else if(type == 17){
|
|
|
+ _this.xuanzeinfoprogress = 100;
|
|
|
+ _this.xuanzeinfoisFinishSize = _this.xuanzeinfoisAllSize;
|
|
|
}else {
|
|
|
_this.infoprogress = 100;
|
|
|
_this.infoisFinishSize = _this.infoisAllSize;
|
|
@@ -9418,6 +9574,8 @@ export default {
|
|
|
_this.teacherinfoproVisible = false;
|
|
|
}else if(type == 16){
|
|
|
_this.mubiaoinfoproVisible = false;
|
|
|
+ }else if(type == 17){
|
|
|
+ _this.xuanzeinfoproVisible = false;
|
|
|
}else{
|
|
|
_this.infoproVisible = false;
|
|
|
}
|
|
@@ -9433,6 +9591,8 @@ export default {
|
|
|
_this.teacherinfoproVisible = false;
|
|
|
}else if(type == 16){
|
|
|
_this.mubiaoinfoproVisible = false;
|
|
|
+ }else if(type == 17){
|
|
|
+ _this.xuanzeinfoproVisible = false;
|
|
|
}else{
|
|
|
_this.infoproVisible = false;
|
|
|
}
|
|
@@ -9606,6 +9766,14 @@ export default {
|
|
|
type: _type,
|
|
|
fileid: fileid == 1 ? '' : fileid,
|
|
|
});
|
|
|
+ }else if (type == 17) {
|
|
|
+ _this.xuanzeInfoData.push({
|
|
|
+ name: file.name,
|
|
|
+ url: data.Location,
|
|
|
+ uid: file.uid,
|
|
|
+ type: _type,
|
|
|
+ fileid: fileid == 1 ? '' : fileid,
|
|
|
+ });
|
|
|
}
|
|
|
console.log(data.Location);
|
|
|
console.log(fileid);
|
|
@@ -10325,6 +10493,25 @@ export default {
|
|
|
return;
|
|
|
});
|
|
|
},
|
|
|
+ deletexuanzeInfoData(e, ic) {
|
|
|
+ e.stopPropagation();
|
|
|
+ let _this = this;
|
|
|
+ _this
|
|
|
+ .$confirm("确定删除此项?", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning",
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ _this.xuanzeInfoData.splice(
|
|
|
+ ic,
|
|
|
+ 1
|
|
|
+ );
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ return;
|
|
|
+ });
|
|
|
+ },
|
|
|
deleteCankaoInfoData(e, ic) {
|
|
|
e.stopPropagation();
|
|
|
let _this = this;
|
|
@@ -10463,8 +10650,8 @@ export default {
|
|
|
}
|
|
|
|
|
|
},
|
|
|
- checkChpater3(e, ic){
|
|
|
- let type = this.mubiaoInfoData[ic].type
|
|
|
+ checkChpater3(e, ic, item){
|
|
|
+ let type = item.type
|
|
|
if(type == 3){
|
|
|
var fileA = [
|
|
|
"DOC",
|
|
@@ -10484,7 +10671,7 @@ export default {
|
|
|
"XLSX",
|
|
|
"XLS"
|
|
|
];
|
|
|
- let url = this.mubiaoInfoData[ic].url
|
|
|
+ let url = item.url
|
|
|
if (
|
|
|
fileA.indexOf(
|
|
|
url.split(".")[
|
|
@@ -10761,6 +10948,7 @@ export default {
|
|
|
targetCourseText: this.targetCourseText,
|
|
|
cankaoInfoData: this.cankaoInfoData,
|
|
|
mubiaoInfoData: this.mubiaoInfoData,
|
|
|
+ xuanzeInfoData: this.xuanzeInfoData,
|
|
|
infoData2: this.infoData2,
|
|
|
isuseT: this.isuseT,
|
|
|
mode: this.mode,
|
|
@@ -11027,6 +11215,7 @@ export default {
|
|
|
targetCourseText: this.targetCourseText,
|
|
|
cankaoInfoData: this.cankaoInfoData,
|
|
|
mubiaoInfoData: this.mubiaoInfoData,
|
|
|
+ xuanzeInfoData: this.xuanzeInfoData,
|
|
|
infoData2: this.infoData2,
|
|
|
isuseT: this.isuseT,
|
|
|
mode: this.mode,
|
|
@@ -13139,6 +13328,7 @@ export default {
|
|
|
this.targetCourseText = JSON.parse(res.data[0][0].setting).targetCourseText ? JSON.parse(res.data[0][0].setting).targetCourseText : "";
|
|
|
this.cankaoInfoData = JSON.parse(res.data[0][0].setting).cankaoInfoData ? JSON.parse(res.data[0][0].setting).cankaoInfoData : [];
|
|
|
this.mubiaoInfoData = JSON.parse(res.data[0][0].setting).mubiaoInfoData ? JSON.parse(res.data[0][0].setting).mubiaoInfoData : [];
|
|
|
+ this.xuanzeInfoData = JSON.parse(res.data[0][0].setting).xuanzeInfoData ? JSON.parse(res.data[0][0].setting).xuanzeInfoData : [];
|
|
|
this.infoData2 = JSON.parse(res.data[0][0].setting).infoData2 ? JSON.parse(res.data[0][0].setting).infoData2 : [];
|
|
|
this.isuseT = JSON.parse(res.data[0][0].setting).isuseT ? JSON.parse(res.data[0][0].setting).isuseT : JSON.parse(res.data[0][0].setting).isuseT === false ? false : false;
|
|
|
this.mode = JSON.parse(res.data[0][0].setting).mode ? JSON.parse(res.data[0][0].setting).mode : 1;
|
|
@@ -13279,6 +13469,7 @@ export default {
|
|
|
this.targetCourseText = JSON.parse(res.data[0][0].setting).targetCourseText ? JSON.parse(res.data[0][0].setting).targetCourseText : "";
|
|
|
this.cankaoInfoData = JSON.parse(res.data[0][0].setting).cankaoInfoData ? JSON.parse(res.data[0][0].setting).cankaoInfoData : [];
|
|
|
this.mubiaoInfoData = JSON.parse(res.data[0][0].setting).mubiaoInfoData ? JSON.parse(res.data[0][0].setting).mubiaoInfoData : [];
|
|
|
+ this.xuanzeInfoData = JSON.parse(res.data[0][0].setting).xuanzeInfoData ? JSON.parse(res.data[0][0].setting).xuanzeInfoData : [];
|
|
|
this.infoData2 = JSON.parse(res.data[0][0].setting).infoData2 ? JSON.parse(res.data[0][0].setting).infoData2 : [];
|
|
|
this.isuseT = JSON.parse(res.data[0][0].setting).isuseT ? JSON.parse(res.data[0][0].setting).isuseT : JSON.parse(res.data[0][0].setting).isuseT === false ? false : false;
|
|
|
this.mode = JSON.parse(res.data[0][0].setting).mode ? JSON.parse(res.data[0][0].setting).mode : 1;
|
|
@@ -17683,6 +17874,14 @@ ${_this.unitJson[0].chapterInfo[0].taskJson[task].taskDetail3.replaceAll('#','')
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ if (_this.xuanzeInfoData.length) {
|
|
|
+ for (var i = 0; i < _this.xuanzeInfoData.length; i++) {
|
|
|
+ if(_this.xuanzeInfoData[i].fileid){
|
|
|
+ fileid.push(_this.xuanzeInfoData[i].fileid)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
let sub = []
|
|
|
let mclass = []
|
|
|
if (this.courseTypeId.length) {
|