Commit d6a8f869 by wuwx Committed by chenwq

修改首页设置-在线客服样式逻辑

1 parent 180800f4
......@@ -80,8 +80,8 @@
</div>
</div>
<div class="approval" slot="cardHolder">
<el-radio :disabled="routeInfo.receivedStock" v-model="editForm.cardHolder" :label="1">否</el-radio>
<el-radio :disabled="routeInfo.receivedStock" v-model="editForm.cardHolder" :label="2">是</el-radio>
<el-radio :disabled="routeInfo.addOrEdit == 'edit'" v-model="editForm.cardHolder" :label="1">否</el-radio>
<el-radio :disabled="routeInfo.addOrEdit == 'edit'" v-model="editForm.cardHolder" :label="2">是</el-radio>
<p class="cardHolder-tip">(根据手机号将礼包中的优惠券直接发放到小程序对应账户的卡包中)</p>
<phoneArea :phones="phones" :phoneLists="phoneLists" ref="phoneArea" placeholder="请输入领取手机号,多个手机号以换行隔开" />
</div>
......
......@@ -120,13 +120,25 @@
<el-checkbox v-for="(item, index) in baseData.clueList" :label="item.confId" :key="index">{{ item.confName }}</el-checkbox>
</el-checkbox-group>
</div>
<template slot="customerServerSuffix" slot-scope="scope">
<!-- <template slot="customerServerSuffix" slot-scope="scope">
<el-button v-show="!scope.scope.optionList.length" type="text"></el-button>
<p style="color: #5850ff" @click="handleNoServer">请在首页-跟进专员模块里添加类型为“在线客服”的跟进专员</p>
</template>
</template> -->
<!-- <div slot="serviceTable" :style="{ 'margin-left': labelWidth, width: `calc(100% - ${labelWidth} )` }">
<GLTable v-show="editForm.customerServerUserId" :hasPage="false" :tableParams="tableParams" :tableData="customerServerList"></GLTable>
</div> -->
<div class="approval" slot="customerServerUserId">
<el-radio v-model="editForm.customerServer" :label="1">
<el-select style="width: 320px" v-model="editForm.customerServerUserId" :disabled="editForm.customerServer == 2" :clearable="true" :placeholder="'请选择在线客服'" :no-data-text="'无数据'" @change="selectAddAttr">
<el-option v-for="value in baseData.consultantList" :key="value.userOneid" :label="value.staffName" :value="value.userOneid"></el-option>
</el-select>
</el-radio>
<el-button v-show="!baseData.consultantList.length" type="text"></el-button>
<p style="color: #5850ff;margin-left: 22px;" @click="handleNoServer">请在首页-跟进专员模块里添加类型为“在线客服”的跟进专员</p>
<el-radio v-model="editForm.customerServer" v-if="!showGh" :label="2">
<el-input style="width: 320px" placeholder="请输入链接" :disabled="editForm.customerServer == 1" v-model="editForm.customerServerUserId" clearable></el-input>
</el-radio>
</div>
</glsx-combi-form>
</div>
</div>
......@@ -206,6 +218,7 @@ export default {
userInfo: {},
// 查看大图
isImgVisible: false,
showGh:false,
dialogObj: {
url: '',
uploadType: 'img'
......@@ -261,6 +274,7 @@ export default {
bannerList: [],
configureStore: 1,
merchantList: [],
customerServer: 1
},
bannerItem: {
bannerImg: '',
......@@ -359,37 +373,43 @@ export default {
title: '在线客服',
editFormData: [
{
label: '在线客服',
name: 'customerServerUserId',
type: 'select',
optionList: [],
optionId: 'userOneid',
optionLabel: 'staffName',
optionsName: 'consultantList',
suffixSlot: 'customerServerSuffix',
isClear: true,
changeAttr: (value, targetItem) => {
var tempObj = {
customerServerName: '',
customerServerUserTitle: ''
}
this.customerServerList = []
this.editForm.customerServerId = ''
this.editForm.customerServerName = ''
this.editForm.customerServerUserTitle = ''
if (value) {
tempObj = this.baseData.consultantList.find(item => item.userOneid == value)
this.editForm.customerServerId = tempObj.id
this.editForm.customerServerName = tempObj.staffName
this.editForm.customerServerUserTitle = tempObj.staffTitle
this.customerServerList.push({
customerServerName: tempObj.staffName,
customerServerUserTitle: tempObj.staffTitle
})
}
}
label: '在线客服',
name: '',
addHtml: 'customerServerUserId'
}
// {
// label: '在线客服',
// name: 'customerServerUserId',
// type: 'select',
// optionList: [],
// optionId: 'userOneid',
// optionLabel: 'staffName',
// optionsName: 'consultantList',
// suffixSlot: 'customerServerSuffix',
// isClear: true,
// changeAttr: (value, targetItem) => {
// var tempObj = {
// customerServerName: '',
// customerServerUserTitle: ''
// }
// this.customerServerList = []
// this.editForm.customerServerId = ''
// this.editForm.customerServerName = ''
// this.editForm.customerServerUserTitle = ''
// if (value) {
// tempObj = this.baseData.consultantList.find(item => item.userOneid == value)
// this.editForm.customerServerId = tempObj.id
// this.editForm.customerServerName = tempObj.staffName
// this.editForm.customerServerUserTitle = tempObj.staffTitle
// this.customerServerList.push({
// customerServerName: tempObj.staffName,
// customerServerUserTitle: tempObj.staffTitle
// })
// }
// }
// }
// {
// label: '',
// addHtml: 'serviceTable'
// }
......@@ -429,9 +449,31 @@ export default {
let idxx = this.externalFormList[idx].editFormData.findIndex(item => item.name == 'configureStore')
this.externalFormList[idx].editFormData[idxx].isHide = true
}
let href = window.location.host
this.showGh = href.indexOf('cgacar') != -1
},
methods: {
selectAddAttr(value){
var tempObj = {
customerServerName: '',
customerServerUserTitle: ''
}
this.customerServerList = []
this.editForm.customerServerId = ''
this.editForm.customerServerName = ''
this.editForm.customerServerUserTitle = ''
if (value) {
tempObj = this.baseData.consultantList.find(item => item.userOneid == value)
this.editForm.customerServerId = tempObj.id
this.editForm.customerServerName = tempObj.staffName
this.editForm.customerServerUserTitle = tempObj.staffTitle
this.customerServerList.push({
customerServerName: tempObj.staffName,
customerServerUserTitle: tempObj.staffTitle
})
}
},
getInfo() {
this.$apis.homeSet.getHomeInfoListApi({}).then(res => {
// console.log(res)
......
......@@ -198,7 +198,7 @@
</el-radio-group>
</template>
<template slot="serviceDescHtml">
<el-input type="textarea" v-model="editForm.serviceDesc" style="width: 320px" placeholder="请输入商品描述" :autosize="{ minRows: 2, maxRows: 4 }" maxlength="30" :disabled="isDisabled" />
<el-input type="textarea" v-model="editForm.serviceDesc" style="width: 320px" placeholder="请输入服务说明" :autosize="{ minRows: 2, maxRows: 4 }" maxlength="30" :disabled="isDisabled" />
</template>
<div slot="selectMerchant" slot-scope="scope" class="select-merchant">
<div>
......
......@@ -355,7 +355,7 @@ export default {
},
// 删除
del(row) {
this.secondConfirm('删除', '确定删除此活动?', 'proManage', 'deleteGoodsApi', { id: row.id })
this.secondConfirm('删除', '确定删除此商品?', 'proManage', 'deleteGoodsApi', { id: row.id })
},
handleShare(row) {
this.$apis.proManage.getProShareApi({ id: row.id }).then(res => {
......
......@@ -437,7 +437,7 @@ export default {
},
// 删除
del(row) {
this.secondConfirm('删除', '确定删除此活动?', 'proManage', 'deleteGoodsApi', { id: row.id })
this.secondConfirm('删除', '确定删除此商品?', 'proManage', 'deleteGoodsApi', { id: row.id })
},
dwonVisibleChange() {
this.$refs.downRef && this.$refs.downRef.clearValidate()
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!