|
|
@@ -217,10 +217,13 @@
|
|
|
<el-radio v-model="form.addType" :label="0">平均</el-radio>
|
|
|
<el-radio v-model="form.addType" :label="1">意向</el-radio>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="加微等待时间" prop="addWxTime" >
|
|
|
+ <el-input style="width:240px" v-model="form.addWxTime" placeholder="加微等待时间"/>
|
|
|
+ </el-form-item>
|
|
|
<el-form-item label="分配账号">
|
|
|
<el-button @click="addQwUser">添加</el-button>
|
|
|
<el-row :gutter="24" v-for="(item, index) in form.qwUser" style="margin-top: 5px">
|
|
|
- <el-col :span="5">
|
|
|
+ <el-col :span="5" v-if="form.addType == 1">
|
|
|
<el-select v-model="item.intention" placeholder="意向等级" filterable clearable>
|
|
|
<el-option v-for="item in levelList" :label="item.dictLabel" :value="item.dictValue"/>
|
|
|
</el-select>
|
|
|
@@ -233,6 +236,11 @@
|
|
|
<el-option v-for="item in wxDialogList" :label="item.name" :value="item.id"/>
|
|
|
</el-select>
|
|
|
</el-col>
|
|
|
+ <el-col :span="5">
|
|
|
+ <el-select v-model="item.smsTempId" placeholder="短信模板" filterable>
|
|
|
+ <el-option v-for="item in smsTempList" :label="item.title" :value="item.tempId"/>
|
|
|
+ </el-select>
|
|
|
+ </el-col>
|
|
|
<el-col :span="3">
|
|
|
<el-button type="danger" icon="el-icon-delete" circle @click="removeQwUser(index)"></el-button>
|
|
|
</el-col>
|
|
|
@@ -346,7 +354,8 @@ import {
|
|
|
companyUserList,
|
|
|
wxList,
|
|
|
taskRun,
|
|
|
- getTypes
|
|
|
+ getTypes,
|
|
|
+ getSmsTempList
|
|
|
} from "@/api/company/companyVoiceRobotic";
|
|
|
import draggable from 'vuedraggable'
|
|
|
import { listAll } from '@/api/company/wxDialog';
|
|
|
@@ -452,7 +461,8 @@ export default {
|
|
|
},
|
|
|
},
|
|
|
// 表单校验
|
|
|
- rules: {}
|
|
|
+ rules: {},
|
|
|
+ smsTempList:[]
|
|
|
};
|
|
|
},
|
|
|
created() {
|
|
|
@@ -470,8 +480,17 @@ export default {
|
|
|
this.levelList = e.data;
|
|
|
})
|
|
|
this.getList();
|
|
|
+ this.getSmsTempDropList();
|
|
|
},
|
|
|
methods: {
|
|
|
+ getSmsTempDropList(){
|
|
|
+ getSmsTempList().then(res=>{
|
|
|
+ this.smsTempList = res.data;
|
|
|
+ console.log(this.smsTempList);
|
|
|
+ }).catch(res=>{
|
|
|
+ console.log(res);
|
|
|
+ })
|
|
|
+ },
|
|
|
/** 查询机器人外呼任务列表 */
|
|
|
getList() {
|
|
|
this.loading = true;
|
|
|
@@ -570,9 +589,17 @@ export default {
|
|
|
}
|
|
|
let list = [];
|
|
|
this.form.qwUser.forEach(l => {
|
|
|
- list = list.concat(l.companyUserId.map(e => {return {intention: l.intention, companyUserId: e,wxDialogId: l.wxDialogId}}))
|
|
|
+ list = list.concat(l.companyUserId.map(e => {return {intention: l.intention, companyUserId: e,wxDialogId: l.wxDialogId,smsTempId:l.smsTempId}}))
|
|
|
})
|
|
|
this.form.qwUserList = list;
|
|
|
+ console.log(this.form);
|
|
|
+ if(this.form.addType != 0 ){
|
|
|
+ let firstTask = taskFlowList[0];
|
|
|
+ if(firstTask.key != "cellPhone"){
|
|
|
+ this.msgError("【意向】加微方式下,任务流程第一步必须为外呼!");
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ }
|
|
|
if(!this.form.qwUserList || this.form.qwUserList.length == 0){
|
|
|
this.msgError("请选者加微方案");
|
|
|
return;
|