Commit 5f19314f by 前端

Merge branch 'wuwx_dev_V3.0' into 'develop'

Wuwx dev v3.0

See merge request !363
2 parents 07371469 aa40b06d
...@@ -141,6 +141,15 @@ const createdNameList = params => { ...@@ -141,6 +141,15 @@ const createdNameList = params => {
sign: true sign: true
}) })
} }
const templateDetail = params => {
params.method = `${path}template.detail`
return http({
url: URL,
method: 'POST',
data: params,
sign: true
})
}
export default { export default {
getCard, getCard,
merchant, merchant,
...@@ -155,5 +164,6 @@ export default { ...@@ -155,5 +164,6 @@ export default {
createdNameList, createdNameList,
templateUpdate, templateUpdate,
templateSave, templateSave,
templateDetail,
crowdfundingActivity crowdfundingActivity
} }
...@@ -304,6 +304,7 @@ ...@@ -304,6 +304,7 @@
:isDisabled="item.isDisabled" :isDisabled="item.isDisabled"
@selectProvince="e => handleSelectProvince(e, item)" @selectProvince="e => handleSelectProvince(e, item)"
@selectCity="e => handleSelectCity(e, item)" @selectCity="e => handleSelectCity(e, item)"
:provinceView="item.provinceView"
></Province> ></Province>
<el-input <el-input
style="flex: 1;" style="flex: 1;"
...@@ -565,6 +566,10 @@ export default { ...@@ -565,6 +566,10 @@ export default {
this.formObj[this.targetItem.attrObj.lng] = mapInfo.lnglat[0] this.formObj[this.targetItem.attrObj.lng] = mapInfo.lnglat[0]
// var fullAddress = mapInfo.geocoderAddress.addressComponent || this.formObj[this.targetItem.attrObj.fullAddress] // var fullAddress = mapInfo.geocoderAddress.addressComponent || this.formObj[this.targetItem.attrObj.fullAddress]
var fullAddress = mapInfo.geocoderAddress.addressComponent var fullAddress = mapInfo.geocoderAddress.addressComponent
if (!fullAddress) {
this.dialogMapVisible = false
return
}
var provincecode = mapInfo.geocoderAddress.adcode || this.formObj[this.targetItem.attrObj.provinceCode] var provincecode = mapInfo.geocoderAddress.adcode || this.formObj[this.targetItem.attrObj.provinceCode]
this.formObj[this.targetItem.attrObj.provinceCode] = provincecode this.formObj[this.targetItem.attrObj.provinceCode] = provincecode
// 获取省市 // 获取省市
......
/*
* @Descripttion:
* @version:
* @Author: limin
* @Date: 2021-06-07 14:12:32
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2022-09-26 17:25:16
*/
// 根据环境引入不同配置 process.env.VUE_APP_ENV // 根据环境引入不同配置 process.env.VUE_APP_ENV
// let request = require('@/http/request.js') // let request = require('@/http/request.js')
let cfg = require('./conf.js') let cfg = require('./conf.js')
......
...@@ -309,6 +309,12 @@ export default { ...@@ -309,6 +309,12 @@ export default {
templateUpdateApi: this.$apis.welcomeword.templateUpdate, templateUpdateApi: this.$apis.welcomeword.templateUpdate,
templateSaveApi: this.$apis.welcomeword.templateSave, templateSaveApi: this.$apis.welcomeword.templateSave,
templateDetailApi: this.$apis.welcomeword.templateDetail templateDetailApi: this.$apis.welcomeword.templateDetail
},
{
name: '链接',
type: 'postLink',
funName: 'postLink',
uploadApi: this.$apis.common.pictureUpload
} }
], ],
basicForm: { basicForm: {
...@@ -497,6 +503,9 @@ export default { ...@@ -497,6 +503,9 @@ export default {
params.crowdFunding = true params.crowdFunding = true
} }
item.attContent = JSON.stringify(item.attContent) item.attContent = JSON.stringify(item.attContent)
} else if (item.attType == 4) {
params.crowdFunding = true
item.attContent = JSON.stringify(item.attContent)
} }
return item return item
}) })
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<template v-if="item.attType == 1"> <template v-if="item.attType == 1">
<div class="preview-text text" v-html="item.attContent"></div> <div class="preview-text text" v-html="item.attContent"></div>
</template> </template>
<template v-else-if="item.attType == 7 || item.attType == 4"> <template v-else-if="item.attType == 7">
<div class="preview-activity"> <div class="preview-activity">
<div class="activity-name">{{ item.attContent.marketingName }}</div> <div class="activity-name">{{ item.attContent.marketingName }}</div>
<img v-if="item.attContent.marketingType != 5 && item.attContent.marketingType != 6 && item.attContent.marketingType != 7" class="activity-logo" src="@/assets/guestCustom/activity-logo.png" alt /> <img v-if="item.attContent.marketingType != 5 && item.attContent.marketingType != 6 && item.attContent.marketingType != 7" class="activity-logo" src="@/assets/guestCustom/activity-logo.png" alt />
...@@ -19,6 +19,12 @@ ...@@ -19,6 +19,12 @@
</div> </div>
</div> </div>
</template> </template>
<template v-else-if="item.attType == 4">
<div class="preview-activity">
<div class="activity-name">{{ item.attContent.title }}</div>
<img class="link-logo" src="@/assets/guestCustom/link.png" alt />
</div>
</template>
<template v-else-if="item.attType == 2"> <template v-else-if="item.attType == 2">
<el-image style="width: 100px" :src="item.attContent" fit="contain"></el-image> <el-image style="width: 100px" :src="item.attContent" fit="contain"></el-image>
</template> </template>
...@@ -70,7 +76,7 @@ export default { ...@@ -70,7 +76,7 @@ export default {
val.forEach(item => { val.forEach(item => {
if (item.attType == 1) { if (item.attType == 1) {
const attContent = item.attContent const attContent = item.attContent
const htm = attContent.replace(/\[[\u4E00-\u9FA56]{1,4}]/gi, function (res) { const htm = attContent.replace(/\[[\u4E00-\u9FA56]{1,4}]/gi, function(res) {
let word = res.replace(/\[|\]/gi, '') let word = res.replace(/\[|\]/gi, '')
const list = emoji.flat(Infinity) const list = emoji.flat(Infinity)
let index = parseInt(list.indexOf(word)) + 1 let index = parseInt(list.indexOf(word)) + 1
......
...@@ -152,9 +152,8 @@ ...@@ -152,9 +152,8 @@
<el-option v-for="value in baseData.consultantList" :key="value.userOneid" :label="value.staffName" :value="value.userOneid"></el-option> <el-option v-for="value in baseData.consultantList" :key="value.userOneid" :label="value.staffName" :value="value.userOneid"></el-option>
</el-select> </el-select>
</el-radio> </el-radio>
<el-button v-show="!baseData.consultantList.length" type="text"></el-button> <p style="color: #5850ff;margin-left: 22px;" v-show="!baseData.consultantList.length" @click="handleNoServer">请在首页-跟进专员模块里添加类型为“在线客服”的跟进专员</p>
<p style="color: #5850ff;margin-left: 22px;" @click="handleNoServer">请在首页-跟进专员模块里添加类型为“在线客服”的跟进专员</p> <el-radio v-model="editForm.customerServerType" :label="2" :class="[!baseData.consultantList.length ? '' : 'haveConsultantList']">
<el-radio v-model="editForm.customerServerType" :label="2">
<!-- <el-radio v-model="editForm.customerServerType" v-if="showGh" :label="2"> --> <!-- <el-radio v-model="editForm.customerServerType" v-if="showGh" :label="2"> -->
<el-input placeholder="请输入链接" :disabled="editForm.customerServerType == 1" v-model="editForm.customerServerUrl" clearable @change="handleServerUrlChange"></el-input> <el-input placeholder="请输入链接" :disabled="editForm.customerServerType == 1" v-model="editForm.customerServerUrl" clearable @change="handleServerUrlChange"></el-input>
</el-radio> </el-radio>
...@@ -237,7 +236,6 @@ ...@@ -237,7 +236,6 @@
</relate-store-dialog> </relate-store-dialog>
</div> </div>
</template> </template>
<script> <script>
export default { export default {
name: 'homeSet', name: 'homeSet',
...@@ -494,7 +492,6 @@ export default { ...@@ -494,7 +492,6 @@ export default {
] ]
} }
}, },
mounted() { mounted() {
this.userInfo = this.$globalState.session this.userInfo = this.$globalState.session
this.getInfo() this.getInfo()
...@@ -511,7 +508,6 @@ export default { ...@@ -511,7 +508,6 @@ export default {
// let href = window.location.host // let href = window.location.host
// this.showGh = href.indexOf('cgacar') != -1 // this.showGh = href.indexOf('cgacar') != -1
}, },
methods: { methods: {
handleServerUrlChange(value) { handleServerUrlChange(value) {
this.editForm.customerServerType = value ? 2 : '' this.editForm.customerServerType = value ? 2 : ''
...@@ -933,37 +929,31 @@ export default { ...@@ -933,37 +929,31 @@ export default {
.home-set .home-set-form .item-box .wechat-container{ .home-set .home-set-form .item-box .wechat-container{
margin: 0 64px 0 20px !important; margin: 0 64px 0 20px !important;
} }
.home-set .home-set-form .item-box .banner-box{ .home-set .home-set-form .item-box .banner-box{
position: relative; position: relative;
padding-left: 20px; padding-left: 20px;
} }
.home-set .home-set-form .item-box .add-banner-btn { .home-set .home-set-form .item-box .add-banner-btn {
position: absolute; position: absolute;
top: 0; top: 0;
right: 0; right: 0;
z-index: 10; z-index: 10;
} }
.home-set .home-set-form .item-box .home-set-tabs .el-tabs__content{ .home-set .home-set-form .item-box .home-set-tabs .el-tabs__content{
border: 1px solid #E5E5E5; border: 1px solid #E5E5E5;
border-radius: 0 4px 4px 4px; border-radius: 0 4px 4px 4px;
border-top: none; border-top: none;
padding: 20px; padding: 20px;
} }
.home-set .banner-img{ .home-set .banner-img{
display: flex; display: flex;
} }
.home-set .banner-label{ .home-set .banner-label{
flex: 0 134px; flex: 0 134px;
text-align: right; text-align: right;
font-weight: 400; font-weight: 400;
color: #666; color: #666;
} }
.home-set .home-set-form .item-box .home-set-tabs.el-tabs--card>.el-tabs__header .el-tabs__nav{ .home-set .home-set-form .item-box .home-set-tabs.el-tabs--card>.el-tabs__header .el-tabs__nav{
border: none !important; border: none !important;
} }
...@@ -1171,4 +1161,8 @@ export default { ...@@ -1171,4 +1161,8 @@ export default {
width: 800px; width: 800px;
margin-left: 45px; margin-left: 45px;
} }
.haveConsultantList {
display: block;
margin-top: 32px;
}
</style> </style>
\ No newline at end of file \ No newline at end of file
<!-- 众筹分享弹窗 -->
<template>
<GLDialog title="分享" mode="mid" okText="关闭" :visible.sync="isShareVisible" :before-close="handleShareClose" :hasFooter="false">
<div class="share-dialog">
<div>
<img style="width: 220px; height: 310px;" :src="shareForm.posterUrl" />
<el-button style="display: block;margin-top: 12px;margin-left: 65px;" :size="size" type="primary" @click="handleSaveImg(shareForm.posterUrl)">下载海报</el-button>
</div>
<div>
<div class="code">
<div class="activity-code">
<div class="code-img">
<img style="width: 146px; height: 146px;" :src="shareForm.qrCodeUrl" />
</div>
<div>
<p class="code-text">活动二维码</p>
<el-button style="margin-top: 17px;" :size="size" type="primary" @click="handleSaveImg(shareForm.qrCodeUrl, '活动二维码')">下载二维码</el-button>
</div>
</div>
<div class="activity-code" style="margin-top: 14px;">
<div class="code-img">
<img style="width: 146px; height: 146px;" :src="shareForm.staffLoginQrCodeUrl" />
</div>
<div>
<p class="code-text">员工注册码</p>
<el-button style="margin-top: 17px;" :size="size" type="primary" @click="handleSaveImg(shareForm.staffLoginQrCodeUrl, '员工注册码')">下载注册码</el-button>
</div>
</div>
</div>
</div>
</div>
<div class="page-route">
<div>
<span class="share-txt">H5短链接:</span>
<span class="copy" @click="handleSaveTxt(shareForm.linkUrl)">复制</span>
<span class="copy" style="margin-left: 10px;width: 75px;" @click="handleSaveTxt(shareForm.originallinkUrl)">复制群发链接</span>
</div>
<p class="link" style="margin-bottom: 16px;">{{ shareForm.linkUrl }}</p>
<div>
<span class="share-txt">员工注册码链接:</span>
<span class="copy" @click="handleSaveTxt(shareForm.staffLoginLinkUrl)">复制</span>
</div>
<p class="link" style="margin-bottom: 16px;">{{ shareForm.staffLoginLinkUrl }}</p>
<div>
<span class="share-txt">活动ID:</span>
<span class="copy" @click="handleSaveTxt(shareForm.id)">复制</span>
</div>
<p class="link">{{ shareForm.id }}</p>
</div>
</GLDialog>
</template>
<script>
export default {
name: 'crowdFundingShare',
data() {
return {}
},
props: {
isShareVisible: {
type: Boolean,
default: false
},
shareForm: {
type: Object,
default: () => { }
}
},
mounted() { },
methods: {
handleSaveImg(url, downloadTxt = '海报') {
var alink = document.createElement('a')
alink.href = url
alink.setAttribute('target', '_blank')
alink.download = downloadTxt
alink.click()
alink.remove()
},
handleSaveTxt(txt) {
this.$message({
message: '复制成功',
type: 'success',
customClass: 'message-Z-zinde'
})
const input = document.createElement('input')
document.body.appendChild(input)
input.setAttribute('value', txt)
input.select()
document.execCommand('Copy')
document.body.removeChild(input)
},
handleShareClose() {
this.$emit('handleShareClose')
}
}
}
</script>
<style scoped>
.share-dialog {
display: flex;
}
.share-dialog .code {
height: 310px;
border-left: 1px dashed #DCDFE6;
margin-left: 20px;
}
.share-dialog .code .code-img {
width: 146px;
height: 146px;
border: 1px solid #E8E8EA;
margin-left: 20px;
margin-right: 36px;
}
.share-dialog .code .activity-code {
display: flex;
align-items: center;
}
.share-dialog .code .code-text {
font-family: PingFangSC-Regular;
font-size: 14px;
color: #333333;
}
.page-route {
margin-top: 20px;
background: #F4F6FC;
padding: 20px;
}
.page-route .link {
width: 492px;
font-family: PingFangSC-Medium;
font-size: 14px;
color: #5850FF;
line-height: 20px;
}
.page-route .share-txt {
font-family: PingFangSC-Regular;
font-size: 14px;
color: #333333;
}
.page-route .copy {
width: 40px;
height: 20px;
background: #5850FF;
border-radius: 2px;
font-family: PingFangSC-Regular;
font-size: 12px;
color: #FFFFFF;
display: inline-block;
line-height: 20px;
text-align: center;
cursor: pointer;
}
</style>
...@@ -93,17 +93,13 @@ ...@@ -93,17 +93,13 @@
</GLTable> </GLTable>
<!-- 表格区域 end --> <!-- 表格区域 end -->
</div> </div>
<!-- 分享 --> <!-- 众筹分享 -->
<share-dialog <crowdFundingShare :isShareVisible="isShareVisible" :shareForm="shareForm" @handleShareClose="handleShareClose"></crowdFundingShare>
:isShareVisible="isShareVisible"
:shareForm="shareForm"
@handleShareClose="handleShareClose"
></share-dialog>
</div> </div>
</template> </template>
<script> <script>
import shareDialog from '../productGroup/components/shareDialog' import crowdFundingShare from '../productGroup/components/crowdFundingShareDialog.vue'
import * as dayjs from 'dayjs' import * as dayjs from 'dayjs'
import url from '@/assets/empty.png' import url from '@/assets/empty.png'
import { exportFn } from '@/common/constant' import { exportFn } from '@/common/constant'
...@@ -370,7 +366,7 @@ export default { ...@@ -370,7 +366,7 @@ export default {
}, },
components: { components: {
shareDialog crowdFundingShare
}, },
mounted () { mounted () {
...@@ -412,6 +408,9 @@ export default { ...@@ -412,6 +408,9 @@ export default {
fn && fn() fn && fn()
this.handleSearch() this.handleSearch()
} }
if (res.code == '21') {
this.handleSearch()
}
}) })
} }
} }
......
...@@ -635,6 +635,75 @@ ...@@ -635,6 +635,75 @@
</div> </div>
</div> </div>
</div> </div>
<!-- 员工注册链接 -->
<div slot="employeeRegistrationLinkFlag" slot-scope="scope">
<el-radio-group v-model="editForm[scope.scope.name]">
<el-radio v-for="(item, index) in scope.scope.optionList" :key="index" :label="item[scope.scope.optionId]">{{ item[scope.scope.optionLabel] }}</el-radio>
</el-radio-group>
</div>
<template slot="appointmentContacts">
<div class="appointmentContactsClass">
<el-form-item label="姓名:" prop="reservationInstallContactsName" labelWidth="60px">
<el-input v-model="editForm.reservationInstallContactsName" style="width: 432px;display: block;" maxlength="10" placeholder="请输入姓名"></el-input>
</el-form-item>
<el-form-item label="电话:" prop="reservationInstallContactsPhone" labelWidth="60px" class="phoneClass">
<el-input v-model="editForm.reservationInstallContactsPhone" style="width: 432px" maxlength="11" placeholder="请输入电话"></el-input>
</el-form-item>
</div>
</template>
<!-- 战报内容配置 -->
<template slot="reportConfigure">
<div class="reportConfigure-bag">
<el-tabs v-model="reportFlag">
<el-tab-pane label="进行中战报" name="1">
<el-form-item label="产值活动报告:" prop="produceReportSummary" labelWidth="100px">
<el-input v-model="editForm.activityActionReport.produceReportSummary" placeholder="根据以往经验,活动前三天转发效果最好,赶紧督促大家转发起来吧" type="textarea" maxlength="200" show-word-limit style="width:580px;height:79px;" rows="3"></el-input>
</el-form-item>
</el-tab-pane>
<el-tab-pane label="已结束战报" name="2">
<el-form-item label="客户资产分析总结:" prop="customerAssetSummary" labelWidth="140px" style="margin-left: 27px;margin-bottom: 0px;">
<el-input v-model="editForm.activityActionReport.customerAssetSummary" placeholder="请输入" type="textarea" maxlength="200" show-word-limit style="width:580px;height:79px;" rows="3"></el-input>
</el-form-item>
<el-form-item label="触达通道分析总结:" prop="touchPassageSummary" labelWidth="140px" style="margin-left: 27px;margin-top: 10px;">
<el-input v-model="editForm.activityActionReport.touchPassageSummary" placeholder="请输入" type="textarea" maxlength="200" show-word-limit style="width:580px;height:79px;" rows="3"></el-input>
</el-form-item>
<div class="reportConfigureList">
<span class="reportConfigureLabel">标杆门店数据:</span>
<el-form-item label="分享数(次)" prop="signMerchantShareCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantShareCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="浏览数(次)" prop="signMerchantBrowseCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantBrowseCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="访客数(人)" prop="signMerchantVisitorCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantVisitorCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="订单数(单)" prop="signMerchantOrderCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantOrderCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="总产值(万)" prop="signMerchantProduceCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantProduceCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
</el-form-item>
</div>
<div class="reportConfigureList">
<span class="reportConfigureLabel">短信触达数据:</span>
<el-form-item label="目标客户数(人)" prop="noteTouchCustomerCount" labelWidth="100px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchCustomerCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="访客数(人)" prop="noteTouchVisitorCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchVisitorCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="订单数(单)" prop="noteTouchOrderCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchOrderCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="转化率(%)" prop="noteTouchConversionRate" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchConversionRate" style="width: 136px;height:32px;" readonly></el-input>
</el-form-item>
</div>
</el-tab-pane>
</el-tabs>
</div>
</template>
<!-- 直播配置 --> <!-- 直播配置 -->
<div slot="live"> <div slot="live">
<el-switch v-model="editForm.liveFlag"></el-switch> <el-switch v-model="editForm.liveFlag"></el-switch>
...@@ -788,6 +857,7 @@ export default { ...@@ -788,6 +857,7 @@ export default {
goodsId: '', goodsId: '',
limitPurchaseFlag: 1, limitPurchaseFlag: 1,
limitPurchaseNumber: '', limitPurchaseNumber: '',
goodsCategory: '',
// 活动配置 // 活动配置
customerServiceFlag: 1, customerServiceFlag: 1,
customerServiceName: '', customerServiceName: '',
...@@ -825,8 +895,28 @@ export default { ...@@ -825,8 +895,28 @@ export default {
liveFlag: false, liveFlag: false,
liveBroadcastRoomId: '', liveBroadcastRoomId: '',
groupQrCode: '', groupQrCode: '',
floatingMaskDiagram: '' floatingMaskDiagram: '',
}, employeeRegistrationLinkFlag: 2,
reservationInstallContactsName: '',
reservationInstallContactsPhone: '',
targetStock: '',
// 战报内容配置
activityActionReport: {
produceReportSummary: '',
customerAssetSummary: '',
touchPassageSummary: '',
signMerchantShareCount: '',
signMerchantBrowseCount: '',
signMerchantVisitorCount: '',
signMerchantOrderCount: '',
signMerchantProduceCount: '',
noteTouchCustomerCount: '',
noteTouchVisitorCount: '',
noteTouchOrderCount: '',
noteTouchConversionRate: ''
}
},
reportFlag: '1',
//商品列表 //商品列表
tableParams: { tableParams: {
tableOption: true, tableOption: true,
...@@ -867,6 +957,7 @@ export default { ...@@ -867,6 +957,7 @@ export default {
], ],
goodsStock: [{ required: true, message: '请设置活动库存', trigger: 'change' }], goodsStock: [{ required: true, message: '请设置活动库存', trigger: 'change' }],
goodsId: [{ required: true, message: '请选择商品', trigger: ['change', 'blur'] }], goodsId: [{ required: true, message: '请选择商品', trigger: ['change', 'blur'] }],
goodsCategory: [{ required: true, message: '请选择关联产品类目项', trigger: ['change', 'blur'] }],
limitPurchaseFlag: [{ required: true, message: '请选择是否限购', trigger: 'change' }], limitPurchaseFlag: [{ required: true, message: '请选择是否限购', trigger: 'change' }],
limitPurchaseNumber: [ limitPurchaseNumber: [
{ required: false, message: '请输入限购次数', trigger: 'blur' }, { required: false, message: '请输入限购次数', trigger: 'blur' },
...@@ -882,6 +973,7 @@ export default { ...@@ -882,6 +973,7 @@ export default {
], ],
// 活动配置 // 活动配置
customerServicePhone: { required: false, validator: validatorPhone, trigger: 'change' }, customerServicePhone: { required: false, validator: validatorPhone, trigger: 'change' },
reservationInstallContactsPhone: { required: false, validator: validatorPhone, trigger: 'change' },
fictitiousLadderQuantity: [{ required: true, message: '请输入阶梯人数', trigger: 'change' }], fictitiousLadderQuantity: [{ required: true, message: '请输入阶梯人数', trigger: 'change' }],
fictitiousViewQuantity: [ fictitiousViewQuantity: [
{ {
...@@ -978,6 +1070,37 @@ export default { ...@@ -978,6 +1070,37 @@ export default {
addHtml: 'goodsHtml' addHtml: 'goodsHtml'
}, },
{ {
label: '关联产品类目项',
name: 'goodsCategory',
type: 'select',
optionList: [
{
optionId: 1,
optionLabel: '数字化美容'
},
{
optionId: 2,
optionLabel: '座椅通风'
},
{
optionId: 3,
optionLabel: 'AR导航'
},
{
optionId: 4,
optionLabel: '氛围灯'
},
{
optionId: 5,
optionLabel: '360全景导航'
}
],
optionId: 'optionId',
optionLabel: 'optionLabel',
isClear: true,
isHide: true
},
{
label: '规格明细', label: '规格明细',
name: '', name: '',
addHtml: 'specificationsHtml', addHtml: 'specificationsHtml',
...@@ -1205,7 +1328,8 @@ export default { ...@@ -1205,7 +1328,8 @@ export default {
label: '活动地址', label: '活动地址',
name: 'activityAddressDetailName', name: 'activityAddressDetailName',
type: 'map', type: 'map',
isReadonly: true, isReadonly: false,
provinceView: false,
attrObj: { attrObj: {
provinceName: 'activityAddressProvinceName', provinceName: 'activityAddressProvinceName',
provinceCode: 'activityAddressProvinceCode', provinceCode: 'activityAddressProvinceCode',
...@@ -1298,7 +1422,7 @@ export default { ...@@ -1298,7 +1422,7 @@ export default {
addHtml: 'activityMusic' addHtml: 'activityMusic'
}, },
{ {
label: '预估销量/元', label: '预估产值',
name: 'predictVolume', name: 'predictVolume',
type: 'input', type: 'input',
maxlength: 20, maxlength: 20,
...@@ -1366,6 +1490,41 @@ export default { ...@@ -1366,6 +1490,41 @@ export default {
addHtml: 'activityExperienceDTOs' addHtml: 'activityExperienceDTOs'
}, },
{ {
label: '员工注册链接',
name: 'employeeRegistrationLinkFlag',
addHtml: 'employeeRegistrationLinkFlag',
optionId: 'confId',
optionLabel: 'confName',
optionList: [
{
confId: 1,
confName: '关闭'
},
{
confId: 2,
confName: '打开'
}
]
},
{
label: '预约安装联系人',
name: '',
addHtml: 'appointmentContacts'
},
{
label: '存量目标数',
name: 'targetStock',
type: 'input',
placeholder: '100',
tips: '用于战报的存量目标数展示'
},
{
label: '战报内容配置',
name: '',
addHtml: 'reportConfigure',
tips: '可自定义战报内容'
},
{
label: '直播配置', label: '直播配置',
name: 'live', name: 'live',
addHtml: 'live' addHtml: 'live'
...@@ -1449,7 +1608,7 @@ export default { ...@@ -1449,7 +1608,7 @@ export default {
this.getLiveList() this.getLiveList()
this.setMinHeight('.crowd-config') this.setMinHeight('.crowd-config')
this.routeInfo = this.$route.query this.routeInfo = this.$route.query
this.routeInfo.addOrEdit != 'add' ? this.getInfo() : this.getMerchantInfo() this.routeInfo.addOrEdit != 'add' ? this.getInfo() : ''
var id = this.routeInfo.id var id = this.routeInfo.id
var detailDisableList = ['editFormData'] var detailDisableList = ['editFormData']
if (id) { if (id) {
...@@ -1498,6 +1657,39 @@ export default { ...@@ -1498,6 +1657,39 @@ export default {
}, },
'editForm.liveBroadcastRoomId' (newValue, oldValue) { 'editForm.liveBroadcastRoomId' (newValue, oldValue) {
this.editForm.liveFlag = newValue ? true : false this.editForm.liveFlag = newValue ? true : false
},
'editForm.goodsId'(newValue, oldValue) {
if (newValue) {
let idx = this.editFormData.findIndex(val => val.name == 'goodsCategory')
this.editFormData[idx].isHide = false
}
},
'editForm.targetStock'(newValue, oldValue) {
this.editForm.targetStock = limitPrice(newValue, oldValue, 99999, 0)
},
'editForm.activityActionReport.noteTouchCustomerCount'(newValue, oldValue) {
this.editForm.activityActionReport.noteTouchCustomerCount = limitPrice(newValue, oldValue, 99999, 0)
},
'editForm.activityActionReport.noteTouchVisitorCount'(newValue, oldValue) {
this.editForm.activityActionReport.noteTouchVisitorCount = limitPrice(newValue, oldValue, 99999, 0)
},
'editForm.activityActionReport.noteTouchOrderCount'(newValue, oldValue) {
this.editForm.activityActionReport.noteTouchOrderCount = limitPrice(newValue, oldValue, 99999, 0)
},
'editForm.activityActionReport.signMerchantVisitorCount'(newValue, oldValue) {
this.editForm.activityActionReport.signMerchantVisitorCount = limitPrice(newValue, oldValue, 99999, 0)
},
'editForm.activityActionReport.signMerchantShareCount'(newValue, oldValue) {
this.editForm.activityActionReport.signMerchantShareCount = limitPrice(newValue, oldValue, 99999, 0)
},
'editForm.activityActionReport.signMerchantBrowseCount'(newValue, oldValue) {
this.editForm.activityActionReport.signMerchantBrowseCount = limitPrice(newValue, oldValue, 99999, 0)
},
'editForm.activityActionReport.signMerchantOrderCount'(newValue, oldValue) {
this.editForm.activityActionReport.signMerchantOrderCount = limitPrice(newValue, oldValue, 99999, 0)
},
'editForm.activityActionReport.signMerchantProduceCount'(newValue, oldValue) {
this.editForm.activityActionReport.signMerchantProduceCount = limitPrice(newValue, oldValue, 99999, 2, 0)
} }
}, },
...@@ -1885,37 +2077,38 @@ export default { ...@@ -1885,37 +2077,38 @@ export default {
}) })
}, },
getMerchantInfo () { // getMerchantInfo () {
this.loading = true // this.loading = true
let merchantId = this.$globalState.session.merchantId // let merchantId = this.$globalState.session.merchantId
this.$apis.common // this.$apis.common
.getMerchantInfoApi({ merchantId: merchantId }) // .getMerchantInfoApi({ merchantId: merchantId })
.then(res => { // .then(res => {
this.userInfo = res // this.userInfo = res
this.editForm.sponsorName = res.merchantName // this.editForm.sponsorName = res.merchantName
// 地图 // // 地图
if (res.provinceName || res.cityName) { // if (res.provinceName || res.cityName) {
this.$refs.configEditFormRef.$refs.provinceForm[0].init(res.provinceName, res.cityName) // this.$refs.configEditFormRef.$refs.provinceForm[0].init(res.provinceName, res.cityName)
let mapAttr = this.configEditFormData.find(item => item.name == 'activityAddressDetailName') // let mapAttr = this.configEditFormData.find(item => item.name == 'activityAddressDetailName')
this.editForm[mapAttr.attrObj.provinceName] = res.provinceName // this.editForm[mapAttr.attrObj.provinceName] = res.provinceName
this.editForm[mapAttr.attrObj.provinceCode] = res.provinceCode // this.editForm[mapAttr.attrObj.provinceCode] = res.provinceCode
this.editForm[mapAttr.attrObj.cityName] = res.cityName // this.editForm[mapAttr.attrObj.cityName] = res.cityName
this.editForm[mapAttr.attrObj.cityCode] = res.cityCode // this.editForm[mapAttr.attrObj.cityCode] = res.cityCode
this.editForm[mapAttr.attrObj.lat] = res.lat // this.editForm[mapAttr.attrObj.lat] = res.lat
this.editForm[mapAttr.attrObj.lng] = res.lng // this.editForm[mapAttr.attrObj.lng] = res.lng
this.editForm[mapAttr.attrObj.fullAddress] = res.merchantAddress // this.editForm[mapAttr.attrObj.fullAddress] = res.merchantAddress
} // }
this.$nextTick(() => { // this.$nextTick(() => {
this.editStatus = false // this.editStatus = false
}) // })
}) // })
.finally(() => { // .finally(() => {
this.loading = false // this.loading = false
}) // })
}, // },
getInfo () { getInfo () {
this.loading = true this.loading = true
this.reportFlag = '1'
this.$apis.seckillActivity this.$apis.seckillActivity
.getActivityDetailApi({ id: this.routeInfo.id }) .getActivityDetailApi({ id: this.routeInfo.id })
.then(res => { .then(res => {
...@@ -1996,6 +2189,31 @@ export default { ...@@ -1996,6 +2189,31 @@ export default {
let resetArr = [{ name: 'id' }, { name: 'activityTime', type: 'array' }, { name: 'liveBroadcastRoomId' }, { name: 'groupQrCode' }, { name: 'floatingMaskDiagram' }, { name: 'selectedProInfo', type: 'Object' }, { name: 'goodsId' }, { name: 'activityPrice' }, { name: 'goodsStock' }] let resetArr = [{ name: 'id' }, { name: 'activityTime', type: 'array' }, { name: 'liveBroadcastRoomId' }, { name: 'groupQrCode' }, { name: 'floatingMaskDiagram' }, { name: 'selectedProInfo', type: 'Object' }, { name: 'goodsId' }, { name: 'activityPrice' }, { name: 'goodsStock' }]
this.copyReset(resetArr) this.copyReset(resetArr)
} }
// 兼容以前众筹活动没有战报内容配置,展示页面
if (this.editForm.activityActionReport == null) {
this.editForm.activityActionReport = {
produceReportSummary: '',
customerAssetSummary: '',
touchPassageSummary: '',
signMerchantShareCount: '',
signMerchantBrowseCount: '',
signMerchantVisitorCount: '',
signMerchantOrderCount: '',
signMerchantProduceCount: '',
noteTouchCustomerCount: '',
noteTouchVisitorCount: '',
noteTouchOrderCount: '',
noteTouchConversionRate: ''
}
}
// 标杆门店总产值/元(已结束战报)
if (this.editForm.activityActionReport.signMerchantProduceCount) {
this.editForm.activityActionReport.signMerchantProduceCount = (info.activityActionReport.signMerchantProduceCount / 10000).toFixed(2)
}
// 转化率(已结束战报)
if (this.editForm.activityActionReport.noteTouchConversionRate) {
this.editForm.activityActionReport.noteTouchConversionRate = (info.activityActionReport.noteTouchConversionRate / 100).toFixed(2)
}
this.$nextTick(() => { this.$nextTick(() => {
this.editStatus = false this.editStatus = false
}) })
...@@ -2084,6 +2302,40 @@ export default { ...@@ -2084,6 +2302,40 @@ export default {
param.groupQrCode = '' param.groupQrCode = ''
param.floatingMaskDiagram = '' param.floatingMaskDiagram = ''
} }
// 标杆门店总产值/元(已结束战报)
if (param.activityActionReport.signMerchantProduceCount) {
param.activityActionReport.signMerchantProduceCount = (this.editForm.activityActionReport.signMerchantProduceCount * 10000).toFixed(0)
}
// 判断目标客户数与访客数
if (param.activityActionReport.noteTouchCustomerCount && param.activityActionReport.noteTouchVisitorCount) {
if (Number(param.activityActionReport.noteTouchCustomerCount) < Number(param.activityActionReport.noteTouchVisitorCount)) {
this.loading = false
this.$message({
message: '目标客户数应大于等于访客数',
type: 'error',
customClass: 'message-Z-zinde'
})
return
}
}
// 判断访客数与浏览数
if (param.activityActionReport.signMerchantVisitorCount && param.activityActionReport.signMerchantBrowseCount) {
if (Number(param.activityActionReport.signMerchantBrowseCount) < Number(param.activityActionReport.signMerchantVisitorCount)) {
this.loading = false
this.$message({
message: '浏览数应大于等于访客数',
type: 'error',
customClass: 'message-Z-zinde'
})
return
}
}
// 已结束战报转化率计算
param.activityActionReport.noteTouchConversionRate = ""
if (param.activityActionReport.noteTouchVisitorCount && param.activityActionReport.noteTouchOrderCount) {
let val = param.activityActionReport.noteTouchOrderCount / param.activityActionReport.noteTouchVisitorCount
param.activityActionReport.noteTouchConversionRate = (val * 10000).toFixed(0)
}
delete param.liveFlag delete param.liveFlag
return param return param
}, },
...@@ -2590,4 +2842,47 @@ export default { ...@@ -2590,4 +2842,47 @@ export default {
left: 0; left: 0;
} }
} }
.appointmentContactsClass {
display: flex;
flex-direction: column;
width: 574px;
height: 124px;
background: #F9F9F9;
justify-content: center;
.phoneClass {
margin-bottom: 0px !important;
}
}
.reportConfigure-bag {
width: 964px;
background: #F9F9F9;
.el-tabs__nav-scroll {
border-bottom: 1px solid #E8E8E8;
}
.el-tabs__item.is-active {
border: 0px solid #f9f9f9 !important;
border-bottom: 1px solid #5850ff !important;
background: #F9F9F9 !important;
}
.el-form-item--small.el-form-item {
margin: 20px 0 10px 74px;
}
.el-textarea .el-input__count {
background: #F9F9F9;
bottom: 2px;
right: -44px;
}
.reportConfigureList {
margin-bottom: 20px;
.reportConfigureLabel {
font-size: 14px;
font-weight: 400;
color: #666;
margin-left: 68px;
}
.el-form-item--small .el-form-item__label {
display: block;
}
}
}
</style> </style>
File mode changed
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!