Commit 14c92ea1 authored by Mac's avatar Mac

1

parent e90d621d
...@@ -73,6 +73,27 @@ ...@@ -73,6 +73,27 @@
</el-input> </el-input>
<el-button v-else class="button-new-tag" size="small" @click="showInput">+ 标签</el-button> <el-button v-else class="button-new-tag" size="small" @click="showInput">+ 标签</el-button>
</el-form-item> </el-form-item>
<el-form-item label="教师擅长课程" size="small">
<el-tag
:key="tag"
v-for="tag in dynamicTags2"
closable
:disable-transitions="false"
@close="handleClose2(tag)">
{{tag}}
</el-tag>
<el-input
class="input-new-tag"
v-if="inputVisible2"
v-model="inputValue2"
ref="saveTagInput2"
size="small"
@keyup.enter.native="handleInputConfirm2"
@blur="handleInputConfirm2"
>
</el-input>
<el-button v-else class="button-new-tag" size="small" @click="showInput2">+ 标签</el-button>
</el-form-item>
<el-form-item label="简介"> <el-form-item label="简介">
<UE style="width:750px;" :defaultMsg="defaultMsg" :config="config" :IsMultiple="true" ref="ue"></UE> <UE style="width:750px;" :defaultMsg="defaultMsg" :config="config" :IsMultiple="true" ref="ue"></UE>
</el-form-item> </el-form-item>
...@@ -112,13 +133,17 @@ ...@@ -112,13 +133,17 @@
WorkYears:'', WorkYears:'',
TeacherStatus:2, TeacherStatus:2,
LableNameList:'', LableNameList:'',
GoodCourseList:'',
Nationality:'',//老师国籍 Nationality:'',//老师国籍
ForeignersUrl:'',//国家图片 ForeignersUrl:'',//国家图片
}, },
loadingPeople:false, loadingPeople:false,
dynamicTags: [], dynamicTags: [],
dynamicTags2: [],
inputVisible: false, inputVisible: false,
inputValue: '', inputValue: '',
inputVisible2: false,
inputValue2: '',
defaultMsg: "", defaultMsg: "",
config: { config: {
initialFrameWidth: null, initialFrameWidth: null,
...@@ -203,6 +228,11 @@ ...@@ -203,6 +228,11 @@
return false return false
} }
this.addMsg.LableNameList = this.dynamicTags this.addMsg.LableNameList = this.dynamicTags
if(this.dynamicTags2.length=='' ||this.dynamicTags2.length==0){
this.Error('请填写教师擅长课程')
return false
}
this.addMsg.GoodCourseList = this.dynamicTags2
let content = this.$refs.ue.getUEContent(); let content = this.$refs.ue.getUEContent();
this.addMsg.Introduction = content; this.addMsg.Introduction = content;
...@@ -226,6 +256,9 @@ ...@@ -226,6 +256,9 @@
handleClose(tag) { handleClose(tag) {
this.dynamicTags.splice(this.dynamicTags.indexOf(tag), 1); this.dynamicTags.splice(this.dynamicTags.indexOf(tag), 1);
}, },
handleClose2(tag) {
this.dynamicTags2.splice(this.dynamicTags2.indexOf(tag), 1);
},
showInput() { showInput() {
this.inputVisible = true; this.inputVisible = true;
...@@ -233,6 +266,12 @@ ...@@ -233,6 +266,12 @@
this.$refs.saveTagInput.$refs.input.focus(); this.$refs.saveTagInput.$refs.input.focus();
}); });
}, },
showInput2() {
this.inputVisible2 = true;
this.$nextTick(_ => {
this.$refs.saveTagInput2.$refs.input.focus();
});
},
handleInputConfirm() { handleInputConfirm() {
let inputValue = this.inputValue; let inputValue = this.inputValue;
...@@ -242,6 +281,14 @@ ...@@ -242,6 +281,14 @@
this.inputVisible = false; this.inputVisible = false;
this.inputValue = ''; this.inputValue = '';
}, },
handleInputConfirm2() {
let inputValue = this.inputValue2;
if (inputValue) {
this.dynamicTags2.push(inputValue);
}
this.inputVisible2 = false;
this.inputValue2 = '';
},
getData(ID) { getData(ID) {
...@@ -256,7 +303,9 @@ ...@@ -256,7 +303,9 @@
} }
if( this.addMsg.LableNameList!=null){ if( this.addMsg.LableNameList!=null){
this.dynamicTags = this.addMsg.LableNameList this.dynamicTags = this.addMsg.LableNameList
}
if(this.addMsg.GoodCourseList!=null){
this.dynamicTags2 = this.addMsg.GoodCourseList
} }
if(this.addMsg.UserId==0){ if(this.addMsg.UserId==0){
this.addMsg.UserId='' this.addMsg.UserId=''
......
...@@ -23,8 +23,12 @@ ...@@ -23,8 +23,12 @@
</div> </div>
</el-form-item> </el-form-item>
<el-form-item label="活动对象" class="is-required" >
<el-radio v-model="msg.ActiveObject" label="1">分销商 </el-radio>
<el-radio v-model="msg.ActiveObject" label="2">所有用户</el-radio>
</el-form-item>
<el-form-item label="分销等级"> <el-form-item label="分销等级">
<el-select style="width:636px;" v-model="msg.Tier" placeholder="请选择"> <el-select v-model="msg.Tier" placeholder="请选择">
<el-option label="全部" :value="0"></el-option> <el-option label="全部" :value="0"></el-option>
<el-option label="一级分销" :value="1"></el-option> <el-option label="一级分销" :value="1"></el-option>
<el-option label="二级分销" :value="2"></el-option> <el-option label="二级分销" :value="2"></el-option>
...@@ -33,7 +37,7 @@ ...@@ -33,7 +37,7 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="活动类型"> <el-form-item label="活动类型">
<el-select style="width:636px;" v-model="msg.Type" placeholder="请选择"> <el-select v-model="msg.Type" placeholder="请选择">
<el-option label="订单数量" :value="1"></el-option> <el-option label="订单数量" :value="1"></el-option>
<el-option label="订单金额" :value="2"></el-option> <el-option label="订单金额" :value="2"></el-option>
<el-option label="商品数量" :value="3"></el-option> <el-option label="商品数量" :value="3"></el-option>
...@@ -58,16 +62,7 @@ ...@@ -58,16 +62,7 @@
<template slot="append"></template> <template slot="append"></template>
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item label="验证码长度" class="is-required" >
<el-select style="width:636px;" v-model="msg.CodeLength" placeholder="请选择">
<el-option label="4位" :value="4"></el-option>
<el-option label="6位" :value="6"></el-option>
<el-option label="8位" :value="8"></el-option>
<el-option label="10位" :value="10"></el-option>
</el-select>
</el-form-item>
<el-form-item label="奖品名称" class="is-required" prop="PrizeName"> <el-form-item label="奖品名称" class="is-required" prop="PrizeName">
<el-input v-model="msg.PrizeName" /> <el-input v-model="msg.PrizeName" />
</el-form-item> </el-form-item>
...@@ -80,6 +75,16 @@ ...@@ -80,6 +75,16 @@
<img v-else :src="msg.PrizeImage" alt=""> <img v-else :src="msg.PrizeImage" alt="">
</div> </div>
</el-form-item> </el-form-item>
<el-form-item label="验证码长度" class="is-required" >
<el-select v-model="msg.CodeLength" placeholder="请选择">
<el-option label="4位" :value="4"></el-option>
<el-option label="6位" :value="6"></el-option>
<el-option label="8位" :value="8"></el-option>
<el-option label="10位" :value="10"></el-option>
</el-select>
</el-form-item>
<el-form-item label="有效期范围" class="is-required" prop="value"> <el-form-item label="有效期范围" class="is-required" prop="value">
<el-date-picker @input="daterangeChange" style="padding: 3px 10px;width: 450px;height: 32px" <el-date-picker @input="daterangeChange" style="padding: 3px 10px;width: 450px;height: 32px"
v-model.trim="msg.value" type="daterange" range-separator="至" start-placeholder="开始日期" v-model.trim="msg.value" type="daterange" range-separator="至" start-placeholder="开始日期"
...@@ -231,7 +236,8 @@ ...@@ -231,7 +236,8 @@
OrderMoney:0, OrderMoney:0,
GoodsNum:0, GoodsNum:0,
PrizeName:'', PrizeName:'',
PrizeImage:'' PrizeImage:'',
ActiveObject:1,
}, },
checkedkeys: [], //默认选中的 checkedkeys: [], //默认选中的
...@@ -351,6 +357,8 @@ ...@@ -351,6 +357,8 @@
this.msg.value.push(res.data.data.StartTime) this.msg.value.push(res.data.data.StartTime)
this.msg.value.push(res.data.data.EndTime) this.msg.value.push(res.data.data.EndTime)
this.msg.Way = res.data.data.Way.toString() this.msg.Way = res.data.data.Way.toString()
this.msg.ActiveObject = res.data.data.ActiveObject.toString()
if (res.data.data.RangeType == 1) { if (res.data.data.RangeType == 1) {
let ProductList = res.data.data.RangeList; let ProductList = res.data.data.RangeList;
......
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