Commit b69b167d authored by zhengke's avatar zhengke

修改

parent b2ea2388
...@@ -198,6 +198,12 @@ ...@@ -198,6 +198,12 @@
<el-button slot="append"></el-button> <el-button slot="append"></el-button>
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item label="已售数量">
<el-input v-model="addMsg.SalesNum" type="number" min="1" size="small" placeholder="请输入内容"
class="input-with-select">
<el-button slot="append"></el-button>
</el-input>
</el-form-item>
<el-form-item label="关联讲师"> <el-form-item label="关联讲师">
<template v-if="addMsg.TeacherList.length>0"> <template v-if="addMsg.TeacherList.length>0">
<el-tag v-for="(item,index) in addMsg.TeacherList" closable size="small" <el-tag v-for="(item,index) in addMsg.TeacherList" closable size="small"
...@@ -213,7 +219,7 @@ ...@@ -213,7 +219,7 @@
<el-card style="margin-top:20px" shadow="never"> <el-card style="margin-top:20px" shadow="never">
<div slot="header" class="clearfix" style="display:flex;justify-content:space-between;align-items:center;"> <div slot="header" class="clearfix" style="display:flex;justify-content:space-between;align-items:center;">
<span>课程信息</span> <span>课程信息</span>
<el-button @click="courseDialog=true,isReplace=0" size="small">添加课程</el-button> <el-button @click="courseDialog=true,isShowEditBtn=true" size="small">添加课程</el-button>
</div> </div>
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
...@@ -263,7 +269,7 @@ ...@@ -263,7 +269,7 @@
</div> </div>
</div> </div>
<div> <div>
<img @click="updateCourse(subItem,index)" style="width:32px;height:32px" <img @click="updateCourse(subItem,index),isReplace=index,isShowEditBtn=false" style="width:32px;height:32px"
src="../../assets/img/userman/edit.png" alt=""> src="../../assets/img/userman/edit.png" alt="">
<img @click="deleteCourse(index)" style="width:32px;height:32px;margin:0 10px" <img @click="deleteCourse(index)" style="width:32px;height:32px;margin:0 10px"
src="../../assets/img/userman/del.png" alt=""> src="../../assets/img/userman/del.png" alt="">
...@@ -655,7 +661,10 @@ ...@@ -655,7 +661,10 @@
</el-switch> </el-switch>
</el-form-item> </el-form-item>
<el-form-item label="试看"> <el-form-item label="试看">
<el-input v-model="courseMsg.Number" @keyup.native="checkInteger(courseMsg,'Number')" size="small"></el-input> <el-input v-model="courseMsg.Number" @keyup.native="checkInteger(courseMsg,'Number')" size="small">
<template slot="append"></template>
</el-input>
<div style="color:red;">设置为0表示不限制试看</div>
</el-form-item> </el-form-item>
<el-form-item label="缓存"> <el-form-item label="缓存">
<el-switch v-model="courseMsg.IsCache" active-color="#409EFF" :active-value="1" :inactive-value="2"> <el-switch v-model="courseMsg.IsCache" active-color="#409EFF" :active-value="1" :inactive-value="2">
...@@ -678,7 +687,7 @@ ...@@ -678,7 +687,7 @@
</el-form> </el-form>
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
<el-button size="small" @click="courseDialog = false">取 消</el-button> <el-button size="small" @click="courseDialog = false">取 消</el-button>
<el-button size="small" @click="getCourseList" v-if="isReplace==0" type="primary">确 定</el-button> <el-button size="small" @click="getCourseList" v-if="isShowEditBtn" type="primary">确 定</el-button>
<el-button size="small" @click="resetCourse" v-else type="primary">确 定</el-button> <el-button size="small" @click="resetCourse" v-else type="primary">确 定</el-button>
</span> </span>
</el-dialog> </el-dialog>
...@@ -779,6 +788,7 @@ ...@@ -779,6 +788,7 @@
MemberPriceTreeList: [], MemberPriceTreeList: [],
TeacherList: [], //教师 TeacherList: [], //教师
CourseList: [], //课程 CourseList: [], //课程
SalesNum:0 //已售数量
}, },
predefineColors: [ predefineColors: [
'#000000', '#000000',
...@@ -906,9 +916,9 @@ ...@@ -906,9 +916,9 @@
SortName: '', //章节排序名称 SortName: '', //章节排序名称
Name: '', //名称 Name: '', //名称
Type: 1, //类型 Type: 1, //类型
IsTrySee: 1, //试看 1可以 2不可以 IsTrySee: 2, //试看 1可以 2不可以
Number: 1, //试看 视频秒/word pdf页 Number: 1, //试看 视频秒/word pdf页
IsCache: 1, //缓存 1可以 2不可以 IsCache: 2, //缓存 1可以 2不可以
FilePath: '', //附件路径 FilePath: '', //附件路径
PathType: 1, //文件存储类型 1腾讯云 2阿里云 PathType: 1, //文件存储类型 1腾讯云 2阿里云
VideoImage: '', //视频图片地址 VideoImage: '', //视频图片地址
...@@ -920,6 +930,7 @@ ...@@ -920,6 +930,7 @@
isReplace: 0, //是否替换 isReplace: 0, //是否替换
videoDivState:false, //视频预览 videoDivState:false, //视频预览
thisVideoAddress:"", thisVideoAddress:"",
isShowEditBtn:true,
}; };
}, },
created() { created() {
...@@ -1219,7 +1230,7 @@ ...@@ -1219,7 +1230,7 @@
} }
} }
if (this.courseMsg.Type == 4) { if (this.courseMsg.Type == 4) {
if (type != 'ppt') { if (type != 'ppt' && type != 'pptx') {
this.Error('请选择ppt文件'); this.Error('请选择ppt文件');
} else { } else {
this.courseMsg.FilePath = msg.url this.courseMsg.FilePath = msg.url
...@@ -1402,9 +1413,13 @@ ...@@ -1402,9 +1413,13 @@
ico: "" ico: ""
} }
} else { } else {
let MarketingLogo = JSON.parse(this.addMsg.MarketingLogo) // var tempObj = this.addMsg.MarketingLogo.substring(1, this.addMsg.MarketingLogo.length-1);
let obj = MarketingLogo // var reg=/\\|\//g;
this.addMsg.MarketingLogo = obj // var cc = "'"+tempObj.replace(reg,"")+"'";
// var bb = eval("("+cc+")");
// var kk = JSON.parse(bb);
// this.addMsg.MarketingLogo=kk;
this.addMsg.MarketingLogo=JSON.parse(this.addMsg.MarketingLogo);
} }
this.getSuggestPrice(); this.getSuggestPrice();
this.getFXDGradeList2(); this.getFXDGradeList2();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment