Commit 34b650ed by 前端

Merge branch 'v2.8.3' into 'develop'

V2.8.3上线,代码合并。

See merge request !350
2 parents 3bbb9b1b 8048f481
Showing 39 changed files with 1637 additions and 963 deletions
This diff could not be displayed because it is too large.
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
"el-tree-transfer": "^2.2.6", "el-tree-transfer": "^2.2.6",
"element-ui": "^2.4.5", "element-ui": "^2.4.5",
"glsx-common": "^1.4.6", "glsx-common": "^1.4.6",
"glsx-components": "^1.5.1", "glsx-components": "^1.5.2",
"lodash": "^4.17.21", "lodash": "^4.17.21",
"node-sass": "^4.0.0", "node-sass": "^4.0.0",
"vue": "^2.6.10", "vue": "^2.6.10",
......
...@@ -110,8 +110,9 @@ html { ...@@ -110,8 +110,9 @@ html {
position: relative; position: relative;
} }
.marketing .wechat-container .w-100-per { .marketing .w-100-per,
width: 100%; .marketing .w-100-percent {
width: 100% !important;
} }
.marketing .wechat-container .wechat-box { .marketing .wechat-container .wechat-box {
...@@ -131,6 +132,12 @@ html { ...@@ -131,6 +132,12 @@ html {
margin-top: 20px; margin-top: 20px;
} }
.marketing .form-sub-block {
// width: 686px;
background: #f9f9f9;
padding: 20px 80px 20px 20px;
}
.marketing .f-right { .marketing .f-right {
float: right; float: right;
} }
...@@ -148,6 +155,7 @@ html { ...@@ -148,6 +155,7 @@ html {
color: #5850ff; color: #5850ff;
border-color: #5850ff; border-color: #5850ff;
height: 32px; height: 32px;
background-color: transparent;
} }
.el-scrollbar__bar.is-horizontal { .el-scrollbar__bar.is-horizontal {
...@@ -229,11 +237,6 @@ html { ...@@ -229,11 +237,6 @@ html {
cursor: pointer; cursor: pointer;
} }
.marketing .w-100-percent,
.marketing .img-w-100 {
width: 100%;
}
.marketing .img-36 { .marketing .img-36 {
width: 36px; width: 36px;
height: 36px; height: 36px;
...@@ -283,10 +286,6 @@ html { ...@@ -283,10 +286,6 @@ html {
margin-bottom: 20px; margin-bottom: 20px;
} }
.marketing .m-t-20 {
margin-top: 20px;
}
.marketing .m-b-60 { .marketing .m-b-60 {
margin-bottom: 60px; margin-bottom: 60px;
} }
...@@ -304,7 +303,7 @@ html { ...@@ -304,7 +303,7 @@ html {
} }
.marketing .m-l-10 { .marketing .m-l-10 {
margin-left: 10px; margin-left: 10px !important;
} }
.marketing .m-l-20 { .marketing .m-l-20 {
...@@ -329,6 +328,10 @@ html { ...@@ -329,6 +328,10 @@ html {
padding-left: 40px; padding-left: 40px;
} }
.marketing .p-0 {
padding: 0;
}
.marketing .circle { .marketing .circle {
display: inline-block; display: inline-block;
width: 6px; width: 6px;
...@@ -343,11 +346,11 @@ html { ...@@ -343,11 +346,11 @@ html {
} }
.marketing .txt-green { .marketing .txt-green {
color: #61CC43; color: #61cc43;
} }
.marketing .txt-orange { .marketing .txt-orange {
color: #FB8F28; color: #fb8f28;
} }
.marketing .txt-blue { .marketing .txt-blue {
......
<!-- 搜索 --> <!-- 搜索 -->
<template> <template>
<div class="glsx-combi-form"> <div :class="['glsx-combi-form', isEdit ? 'gl-form-page' : '']">
<el-form :ref="formRef" :inline="true" :model="formObj" :rules="formRules" size="small" class="glsx-combi-form-block"> <el-form :ref="formRef" :inline="true" :model="formObj" :rules="formRules" size="small" class="glsx-combi-form-block">
<template v-for="(item, index) in formData"> <template v-for="(item, index) in formData">
<el-form-item v-if="!item.isHide" :key="index" :id="item.name" :labelWidth="isEdit ? '144px' : labelWidth" :class="{ 'no-label': !item.label, isBlock: isBlock }" :style="{ 'margin-bottom': isEdit ? '24px' : '', 'margin-right': isEdit ? '0px' : '30px', ...item.style }" :label="item.label" :prop="item.name"> <el-form-item v-if="!item.isHide" :key="index" :id="item.name" :labelWidth="isEdit ? '154px' : labelWidth" :class="{ 'no-label': !item.label, isBlock: isBlock }" :style="{ 'margin-bottom': isEdit ? '24px' : '', 'margin-right': isEdit ? '0px' : '30px', ...item.style }" :label="item.label" :prop="item.name">
<span v-if="!item.isHide && item.tips" class="tips-block" slot="label"> <span v-if="!item.isHide && item.tips" class="tips-block" slot="label">
<span class="tips-label">{{ item.label }}</span> <span class="tips-label">{{ item.label }}</span>
<el-popover placement="top" width="200" trigger="hover" :content="item.tips"> <el-popover placement="top" width="200" trigger="hover" :content="item.tips">
<img slot="reference" class="tips-icon" src="./images/icon-tip.png" /> <img slot="reference" class="tips-icon" src="./images/icon-tip.png" />
</el-popover> </el-popover>
:
</span> </span>
<span v-else-if="!item.isHide && item.label && !item.tips" slot="label"> <span v-else-if="!item.isHide && item.label && !item.tips" slot="label">
<span class="combi-form-label" :style="{ width: item.labelWidth ? item.labelWidth + labelPaddingRight + 'px' : '', 'padding-right': isEdit ? '12px' : labelPaddingRight + 'px' }">{{ item.label }}</span> <span class="combi-form-label" :style="{ width: item.labelWidth || labelWidth }">{{ item.label }}:</span>
</span> </span>
<slot v-if="item.addHtml" :name="item.addHtml" :scope="item"></slot> <slot v-if="item.addHtml" :name="item.addHtml" :scope="item"></slot>
<span v-else-if="item.type === 'showTxt'">{{ formObj[item.name] }}</span> <span v-else-if="item.type === 'showTxt'">{{ formObj[item.name] }}</span>
...@@ -32,7 +33,9 @@ ...@@ -32,7 +33,9 @@
<!-- radio --> <!-- radio -->
<div v-else-if="item.type === 'radio'"> <div v-else-if="item.type === 'radio'">
<el-radio-group v-model="formObj[item.name]" v-bind="item.attrs ? item.attrs : {}" v-on="item.listeners ? item.listeners : {}" :disabled="item.isDisabled" @change="item.handleRadioChange"> <el-radio-group v-model="formObj[item.name]" v-bind="item.attrs ? item.attrs : {}" v-on="item.listeners ? item.listeners : {}" :disabled="item.isDisabled" @change="item.handleRadioChange">
<el-radio v-for="subItem in item.optionList" :key="subItem[item.optionId]" :disabled="subItem.isDisabled" :label="subItem[item.optionId]">{{ subItem[item.optionLabel] }} <slot :name="subItem.suffixSonSlot" :scope="subItem"></slot> <el-radio v-for="subItem in item.optionList" :key="subItem[item.optionId]" :disabled="subItem.isDisabled" :label="subItem[item.optionId]">
{{ subItem[item.optionLabel] }}
<slot :name="subItem.suffixSonSlot" :scope="subItem"></slot>
</el-radio> </el-radio>
</el-radio-group> </el-radio-group>
<slot :name="item.suffixSlot" :scope="item"></slot> <slot :name="item.suffixSlot" :scope="item"></slot>
...@@ -41,20 +44,21 @@ ...@@ -41,20 +44,21 @@
<template v-else-if="item.type === 'upload'"> <template v-else-if="item.type === 'upload'">
<p class="photo-top-tips">{{ item.topTips }}</p> <p class="photo-top-tips">{{ item.topTips }}</p>
<div v-if="!item.isDisabled" :style="{ width: item.width || defaultWidth }"> <div v-if="!item.isDisabled" :style="{ width: item.width || defaultWidth }">
<div v-if="Array.isArray(formObj[item.name]) ? formObj[item.name].length < item.maxPhotoNum : !formObj[item.name]" class="activity-img img-w-h"> <div v-if="Array.isArray(formObj[item.name]) ? formObj[item.name].length < item.maxPhotoNum : !formObj[item.name]" class="activity-img img-w-h" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''">
<div class="add" :style="{ top: item.maxPhotoNum == 1 ? '50%' : '40%' }">+</div> <div class="add" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('addStyle') ? item.uploadStyle.addStyle : ''">+</div>
<span v-if="item.maxPhotoNum > 1" class="number">{{ formObj[item.name].length }} / {{ item.maxPhotoNum }}</span> <!-- <span v-if="item.maxPhotoNum > 1" class="number">{{ formObj[item.name].length }}/{{ item.maxPhotoNum }}</span> -->
<input v-if="item.uploadType == 'video'" type="file" style="opacity: 0" :id="item.name + 'file'" ref="file" class="activity-img img-w-h" accept="video/mp4" @change="e => handleUploadChange(e, item)" /> <span class="number" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('fontSize') ? item.uploadStyle.fontSize : ''">上传{{ item.uploadType == 'video' ? '视频' : '图片' }}</span>
<input v-else type="file" style="opacity: 0" :id="item.name + 'file'" ref="file" class="activity-img img-w-h" accept="image/png, image/jpeg, image/gif, image/jpg" @change="e => handleUploadChange(e, item)" /> <input v-if="item.uploadType == 'video'" type="file" style="opacity: 0" :id="item.name + 'file'" ref="file" class="activity-img img-w-h" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''" accept="video/mp4" @change="e => handleUploadChange(e, item)" />
<input v-else type="file" style="opacity: 0" :id="item.name + 'file'" ref="file" class="activity-img img-w-h" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''" accept="image/png, image/jpeg, image/gif, image/jpg" @change="e => handleUploadChange(e, item)" />
</div> </div>
</div> </div>
<template> <template>
<div v-if="Array.isArray(formObj[item.name]) ? formObj[item.name].length : formObj[item.name]"> <div v-if="Array.isArray(formObj[item.name]) ? formObj[item.name].length : formObj[item.name]">
<span v-if="Array.isArray(formObj[item.name])"> <span v-if="Array.isArray(formObj[item.name])">
<span v-for="(subItem, subIndex) in formObj[item.name]" :key="subIndex" class="muti-imgs img-w-h"> <span v-for="(subItem, subIndex) in formObj[item.name]" :key="subIndex" class="muti-imgs img-w-h" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''">
<video v-if="item.uploadType == 'video'" class="img-w-h activity-img" :src="typeof subItem == 'object' ? subItem.content : subItem"></video> <video v-if="item.uploadType == 'video'" class="img-w-h activity-img" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''" :src="typeof subItem == 'object' ? subItem.content : subItem"></video>
<img v-else class="img-w-h" :src="typeof subItem == 'object' ? subItem.content : subItem" /> <img v-else class="img-w-h" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''" :src="typeof subItem == 'object' ? subItem.content : subItem" />
<span class="img-btns"> <span class="img-btns" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''">
<span class="btn-item"> <span class="btn-item">
<i v-show="!item.isDisabled" class="el-icon-delete" @click="handleImgDelete(item, subIndex)"></i> <i v-show="!item.isDisabled" class="el-icon-delete" @click="handleImgDelete(item, subIndex)"></i>
<i class="el-icon-zoom-in" @click="handleImgLook(typeof subItem == 'object' ? subItem.content : subItem, item)"></i> <i class="el-icon-zoom-in" @click="handleImgLook(typeof subItem == 'object' ? subItem.content : subItem, item)"></i>
...@@ -63,9 +67,9 @@ ...@@ -63,9 +67,9 @@
</span> </span>
</span> </span>
<span v-else class="muti-imgs"> <span v-else class="muti-imgs">
<video v-if="item.uploadType == 'video'" class="img-w-h activity-img" :src="formObj[item.name]"></video> <video v-if="item.uploadType == 'video'" class="img-w-h activity-img" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''" :src="formObj[item.name]"></video>
<img v-else class="img-w-h" :src="formObj[item.name]" /> <img v-else class="img-w-h" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''" :src="formObj[item.name]" />
<span class="img-btns"> <span class="img-btns" :style="item.uploadStyle && item.uploadStyle.hasOwnProperty('imgWH') ? item.uploadStyle.imgWH : ''">
<span class="btn-item"> <span class="btn-item">
<i v-show="!item.isDisabled" class="el-icon-delete" @click="handleImgDelete(item)"></i> <i v-show="!item.isDisabled" class="el-icon-delete" @click="handleImgDelete(item)"></i>
<i class="el-icon-zoom-in" @click="handleImgLook(formObj[item.name], item)"></i> <i class="el-icon-zoom-in" @click="handleImgLook(formObj[item.name], item)"></i>
...@@ -138,7 +142,7 @@ export default { ...@@ -138,7 +142,7 @@ export default {
}, },
defaultWidth: { defaultWidth: {
type: String, type: String,
default: '215px' default: '432px'
}, },
formRef: { formRef: {
type: String, type: String,
...@@ -149,14 +153,14 @@ export default { ...@@ -149,14 +153,14 @@ export default {
default: false default: false
}, },
labelWidth: { labelWidth: {
type: Number, type: String,
// 默认是四个字符长度 // 默认是四个字符长度
default: 56 default: '154px'
},
labelPaddingRight: {
type: Number,
default: 15
}, },
// labelPaddingRight: {
// type: Number,
// default: 15
// },
formData: { formData: {
type: Array, type: Array,
default: () => [] default: () => []
...@@ -206,7 +210,6 @@ export default { ...@@ -206,7 +210,6 @@ export default {
var reader = new FileReader() var reader = new FileReader()
var file = e.srcElement.files[0] var file = e.srcElement.files[0]
var uploadType = targetItem.uploadType || 'img' var uploadType = targetItem.uploadType || 'img'
// console.log(file)
// 默认1MB // 默认1MB
const limitSize = targetItem.limitSize || 1 const limitSize = targetItem.limitSize || 1
const isLt = file.size / 1024 / 1024 < limitSize const isLt = file.size / 1024 / 1024 < limitSize
...@@ -240,11 +243,11 @@ export default { ...@@ -240,11 +243,11 @@ export default {
if (targetItem.hasPixel && (imgWidth > wdithLt || imgHeight > heightLt)) { if (targetItem.hasPixel && (imgWidth > wdithLt || imgHeight > heightLt)) {
this.$message.error('图片尺寸最大为' + wdithLt + '像素*' + heightLt + '像素') this.$message.error('图片尺寸最大为' + wdithLt + '像素*' + heightLt + '像素')
} else { } else {
targetItem.handleUpload(e, file, targetItem) targetItem.handleUpload(e, file, targetItem, this.formObj)
} }
} }
} else { } else {
targetItem.handleUpload(e, file, targetItem) targetItem.handleUpload(e, file, targetItem, this.formObj)
} }
} }
document.getElementById(targetItem.name + 'file').value = '' document.getElementById(targetItem.name + 'file').value = ''
...@@ -415,12 +418,12 @@ export default { ...@@ -415,12 +418,12 @@ export default {
display: inline-block; display: inline-block;
width: 14px; width: 14px;
height: 14px; height: 14px;
margin-right: 12px; margin-right: 0px !important;
vertical-align: middle; vertical-align: middle;
cursor: pointer; cursor: pointer;
} }
.glsx-combi-form .combi-form-label { .glsx-combi-form .combi-form-label {
display: inline-block; /* display: inline-block; */
box-sizing: border-box; box-sizing: border-box;
} }
/* 图片上传 */ /* 图片上传 */
...@@ -450,6 +453,7 @@ export default { ...@@ -450,6 +453,7 @@ export default {
.glsx-combi-form .muti-imgs { .glsx-combi-form .muti-imgs {
display: inline-block; display: inline-block;
position: relative; position: relative;
margin: 10px 8px 0 0;
} }
.activity-img .add { .activity-img .add {
...@@ -465,6 +469,9 @@ export default { ...@@ -465,6 +469,9 @@ export default {
bottom: 0; bottom: 0;
left: 50%; left: 50%;
transform: translateX(-50%); transform: translateX(-50%);
font-size: 14px;
width: 100%;
text-align: center;
} }
.muti-imgs .img-btns { .muti-imgs .img-btns {
......
<template> <template>
<div v-if="provinceView"> <div v-if="provinceView">
<el-form ref="provinceForm" :model="provinceForm" inline="true" class="province"> <el-form ref="provinceForm" :model="provinceForm" inline="true" class="province" style="padding-left: 0;">
<el-select size="small" v-model="provinceForm.provinceName" clearable :disabled="isDisabled" placeholder="选择省份" :style="{ width: defaultWidth }" @change="selectProvince" class="select-padding"> <el-select size="small" v-model="provinceForm.provinceName" clearable :disabled="isDisabled" placeholder="选择省份" :style="{ width: defaultWidth }" @change="selectProvince" class="select-padding">
<el-option v-for="item in AllData" :key="item.adcode" :label="item.name" :value="item.name" @click.native="selectProvince(item)"></el-option> <el-option v-for="item in AllData" :key="item.adcode" :label="item.name" :value="item.name" @click.native="selectProvince(item)"></el-option>
</el-select> </el-select>
...@@ -160,9 +160,12 @@ export default { ...@@ -160,9 +160,12 @@ export default {
} }
} }
</script> </script>
<style scoped lang="scss"> <style lang="scss">
.province { .province {
display: inline-flex; display: inline-flex;
.el-select .el-input {
width: auto !important;
}
} }
.select-padding { .select-padding {
margin-right: 10px; margin-right: 10px;
......
...@@ -27,6 +27,7 @@ Vue.config.productionTip = false ...@@ -27,6 +27,7 @@ Vue.config.productionTip = false
Vue.prototype.$apis = apis Vue.prototype.$apis = apis
Vue.prototype.size = 'small' Vue.prototype.size = 'small'
Vue.prototype.setMinHeight = setMinHeight Vue.prototype.setMinHeight = setMinHeight
Vue.prototype.defaultLabelWidth = '154px'
start() start()
export { bootstrap, mount, unmount } from '@/setup' export { bootstrap, mount, unmount } from '@/setup'
export const http = params => Vue.prototype.$http(params) export const http = params => Vue.prototype.$http(params)
......
...@@ -2,13 +2,13 @@ ...@@ -2,13 +2,13 @@
<div class="activity-main"> <div class="activity-main">
<div class="activity-box-f" v-loading="addLoading"> <div class="activity-box-f" v-loading="addLoading">
<div class="activity-box-title">{{ activityId ? '编辑活动' : '创建活动' }}</div> <div class="activity-box-title">{{ activityId ? '编辑活动' : '创建活动' }}</div>
<div class="activity-box-form"> <div class="activity-box-form gl-form-page">
<el-form ref="addForm" :model="addForm" class="code-body-form" label-width="120px" :rules="addRules"> <el-form ref="addForm" :model="addForm" class="code-body-form" label-width="120px" :rules="addRules">
<el-form-item label="活动名称" prop="configName" size="small" class="form-w40"> <el-form-item label="活动名称:" prop="configName" size="small" class="form-w40">
<el-input size="small" v-model.trim="addForm.configName" placeholder="请输入活动名称" maxlength="20"></el-input> <el-input size="small" v-model.trim="addForm.configName" placeholder="请输入活动名称" maxlength="20"></el-input>
<div class="activity-name-tips">例:输入“定保客户”,系统推送任务时将自动追加月份信息“5月招揽-定保客户”</div> <div class="activity-name-tips">例:输入“定保客户”,系统推送任务时将自动追加月份信息“5月招揽-定保客户”</div>
</el-form-item> </el-form-item>
<el-form-item label="活动对象" prop="selectType" size="small" class="activity-item"> <el-form-item label="活动对象:" prop="selectType" size="small" class="activity-item">
<el-radio-group v-model="addForm.selectType" :disabled="this.activityId" @change="handleType"> <el-radio-group v-model="addForm.selectType" :disabled="this.activityId" @change="handleType">
<el-radio :label="1">客群</el-radio> <el-radio :label="1">客群</el-radio>
<el-radio :label="2">Excel导入</el-radio> <el-radio :label="2">Excel导入</el-radio>
...@@ -42,28 +42,28 @@ ...@@ -42,28 +42,28 @@
</template> </template>
</el-form-item> </el-form-item>
<template v-if="addForm.selectType == 1"> <template v-if="addForm.selectType == 1">
<el-form-item label="推送日期" prop="sendDate" size="small" class="activity-item"> <el-form-item label="推送日期:" prop="sendDate" size="small" class="activity-item">
<div class="activity-date"> <div class="activity-date">
每月 每月
<el-input-number v-model="addForm.sendDate" controls-position="right" :min="1" :max="28"></el-input-number> <el-input-number v-model="addForm.sendDate" controls-position="right" :min="1" :max="28"></el-input-number>
号 号
</div> </div>
</el-form-item> </el-form-item>
<el-form-item label="推送月份" prop="sendMonth" size="small" class="activity-item"> <el-form-item label="推送月份:" prop="sendMonth" size="small" class="activity-item">
<el-radio-group v-model="addForm.sendMonth"> <el-radio-group v-model="addForm.sendMonth">
<el-radio :label="1">次月</el-radio> <el-radio :label="1">次月</el-radio>
<el-radio :label="0">当月</el-radio> <el-radio :label="0">当月</el-radio>
</el-radio-group> </el-radio-group>
<div class="activity-name-tips">例:选择“次月”,系统将在设定的推送日期推送次月的待定保客户</div> <div class="activity-name-tips">例:选择“次月”,系统将在设定的推送日期推送次月的待定保客户</div>
</el-form-item> </el-form-item>
<el-form-item label="状态" size="small" class="activity-status"> <el-form-item label="状态:" size="small" class="activity-status">
<el-switch v-model="activityStatus"></el-switch> <el-switch v-model="activityStatus"></el-switch>
<span class="activity-stop">{{ activityStatus ? '启用' : '停用' }}</span> <span class="activity-stop">{{ activityStatus ? '启用' : '停用' }}</span>
<el-popover placement="top" width="300" trigger="hover" content="停用活动仅会影响下个周期的营销推送,不影响已经生成的招揽活动。"> <el-popover placement="top" width="300" trigger="hover" content="停用活动仅会影响下个周期的营销推送,不影响已经生成的招揽活动。">
<img src="@/assets/activity/question.png" slot="reference" class="count-item-question" /> <img src="@/assets/activity/question.png" slot="reference" class="count-item-question" />
</el-popover> </el-popover>
</el-form-item> </el-form-item>
<el-form-item label="客群" prop="custGroupId" size="small"> <el-form-item label="客群:" prop="custGroupId" size="small">
<div class="group-item"> <div class="group-item">
<el-select v-model="addForm.custGroupId" placeholder="请选择" @change="selectCrowd(addForm.custGroupId)"> <el-select v-model="addForm.custGroupId" placeholder="请选择" @change="selectCrowd(addForm.custGroupId)">
<el-option v-for="item in crowdGroupUnitList" :key="item.crowdGroupId" :label="item.crowdGroupName" :value="item.crowdGroupId"></el-option> <el-option v-for="item in crowdGroupUnitList" :key="item.crowdGroupId" :label="item.crowdGroupName" :value="item.crowdGroupId"></el-option>
...@@ -72,7 +72,7 @@ ...@@ -72,7 +72,7 @@
</div> </div>
</el-form-item> </el-form-item>
</template> </template>
<el-form-item label="配置营销" prop="name" size="small" v-if="addForm.custGroupId || (successStatus && exportUrl)"> <el-form-item label="配置营销:" prop="name" size="small" v-if="addForm.custGroupId || (successStatus && exportUrl)">
<GLTable :hasPage="false" ref="config" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams"> <GLTable :hasPage="false" ref="config" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams">
<template slot="welcomeConfigDTOS" slot-scope="scope"> <template slot="welcomeConfigDTOS" slot-scope="scope">
<div class="statusText"> <div class="statusText">
...@@ -152,11 +152,9 @@ ...@@ -152,11 +152,9 @@
</el-button> </el-button>
<el-button type="primary" @click="handleSure" v-show="(successStatus && addForm.selectType == 2 && exportUrl) || addForm.selectType == 1">提交</el-button> <el-button type="primary" @click="handleSure" v-show="(successStatus && addForm.selectType == 2 && exportUrl) || addForm.selectType == 1">提交</el-button>
</GLFooter> </GLFooter>
<component @handleConfigChecked="handleConfigChecked" :is="'market-config'" ref="configForm" :boxHeight="boxHeight"></component> <component @handleConfigChecked="handleConfigChecked" :is="'market-config'" ref="configForm" :boxHeight="boxHeight"></component>
</div> </div>
</template> </template>
<script> <script>
import { utils } from 'glsx-common' import { utils } from 'glsx-common'
import util from '@/utils/util' import util from '@/utils/util'
...@@ -463,7 +461,6 @@ export default { ...@@ -463,7 +461,6 @@ export default {
} }
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.downloading-containner { .downloading-containner {
padding: 20px; padding: 20px;
...@@ -613,7 +610,6 @@ export default { ...@@ -613,7 +610,6 @@ export default {
font-size: 0px; font-size: 0px;
} }
} }
a { a {
margin-left: 6px; margin-left: 6px;
color: #5850ff; color: #5850ff;
......
...@@ -3,18 +3,21 @@ ...@@ -3,18 +3,21 @@
<div class="edit-classify marketing edit-box"> <div class="edit-classify marketing edit-box">
<div class="container edit-container"> <div class="container edit-container">
<p class="edit-title">{{ title }}</p> <p class="edit-title">{{ title }}</p>
<glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" defaultWidth="320px" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<div slot="selectProBtn" slot-scope="scope" class="select-pro"> <div slot="selectProBtn" slot-scope="scope" class="select-pro">
<el-button type="default" @click="handleMutiProClose(scope)">{{ editForm.goodsRefList.length ? '更换商品' : '+选择商品' }}</el-button> <el-button type="default" @click="handleMutiProClose(scope)">{{ editForm.goodsRefList.length ? '更换商品' : '+选择商品' }}</el-button>
</div> </div>
<div slot="proTable" class="select-pro" style="padding-left: 20px"> <div slot="proTable" class="select-pro" :style="{ 'margin-left': defaultLabelWidth, width: `calc(100% - ${defaultLabelWidth} )` }">
<GLTable v-show="editForm.goodsRefList.length" :hasPage="false" :tableParams="tableParams" :tableData="editForm.goodsRefList"> <GLTable v-show="editForm.goodsRefList.length" :hasPage="false" :tableParams="tableParams" :tableData="editForm.goodsRefList">
<template slot="goodsImage" slot-scope="scope"> <div slot="goodsImage" class="table-image" slot-scope="scope">
<img class="img-60" :src="scope.scope.goodsImage" /> <el-popover placement="top" width="160" trigger="hover" popper-class="table-popover-block">
</template> <img class="table-popover-img" :src="scope.scope.goodsImage" />
<span slot="auth-button" slot-scope="scope"> <img class="img-60 pointer" slot="reference" :src="scope.scope.goodsImage" />
<el-button type="text" @click="handleProDelete(scope)">删除</el-button> </el-popover>
<el-button type="text" @click="handleProTop(scope)">置顶</el-button> </div>
<span slot="customBtn" slot-scope="scope">
<el-button class="p-0" type="text" @click="handleProDelete(scope)">删除</el-button>
<el-button class="p-0 m-l-10" type="text" @click="handleProTop(scope)">置顶</el-button>
</span> </span>
</GLTable> </GLTable>
</div> </div>
...@@ -94,7 +97,6 @@ export default { ...@@ -94,7 +97,6 @@ export default {
], ],
// 门店表格 // 门店表格
tableParams: { tableParams: {
tableOption: true,
tableColumns: [ tableColumns: [
{ {
label: '缩略图', label: '缩略图',
...@@ -103,11 +105,20 @@ export default { ...@@ -103,11 +105,20 @@ export default {
}, },
{ {
label: '商品名称', label: '商品名称',
prop: 'productName' prop: 'productName',
formatter: cellValue => {
return cellValue.productName || cellValue.goodsName || '--'
}
}, },
{ {
label: '零售价', label: '零售价',
prop: 'retailPrice' prop: 'retailPrice'
},
{
label: '操作',
prop: '',
width: '120px',
addHtml: 'customBtn'
} }
] ]
} }
......
...@@ -57,8 +57,7 @@ ...@@ -57,8 +57,7 @@
</div> </div>
</div> </div>
<p class="edit-title">{{ title }}代金券</p> <p class="edit-title">{{ title }}代金券</p>
<glsx-combi-form class="edit-form-container" style="min-height: 570px" ref="editFormRef" :isEdit="true" <glsx-combi-form class="edit-form-container" style="min-height: 570px" ref="editFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
:isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<template slot="useChannelHtml"> <template slot="useChannelHtml">
<el-radio v-model="editForm.useChannel" label="1" :disabled="apear != 'couponAdd'">线上商品</el-radio> <el-radio v-model="editForm.useChannel" label="1" :disabled="apear != 'couponAdd'">线上商品</el-radio>
<el-radio v-model="editForm.useChannel" label="2" :disabled="apear != 'couponAdd'">到店核销</el-radio> <el-radio v-model="editForm.useChannel" label="2" :disabled="apear != 'couponAdd'">到店核销</el-radio>
...@@ -82,18 +81,14 @@ ...@@ -82,18 +81,14 @@
<br /> <br />
<el-form-item prop="effectiveTime" ref="effectiveTime" style="margin-top: 12px; display: block"> <el-form-item prop="effectiveTime" ref="effectiveTime" style="margin-top: 12px; display: block">
<el-radio v-model="editForm.effectiveType" label="2" :disabled="apear != 'couponAdd'"> <el-radio v-model="editForm.effectiveType" label="2" :disabled="apear != 'couponAdd'">
<el-date-picker v-model="editForm.effectiveTime" @change="haveChange" type="datetimerange" <el-date-picker v-model="editForm.effectiveTime" @change="haveChange" type="datetimerange" style="width: 340px" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :picker-options="pickerOption" :default-time="defaultTime" :format="format" :disabled="editForm.effectiveType != 2 || apear != 'couponAdd'" clearable>
style="width: 340px" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"
value-format="yyyy-MM-dd HH:mm:ss" :picker-options="pickerOption" :default-time="defaultTime"
:format="format" :disabled="editForm.effectiveType != 2 || apear != 'couponAdd'" clearable>
</el-date-picker> </el-date-picker>
</el-radio> </el-radio>
</el-form-item> </el-form-item>
<el-form-item prop="effectiveDays" ref="effectiveDays"> <el-form-item prop="effectiveDays" ref="effectiveDays">
<el-radio v-model="editForm.effectiveType" label="1" :disabled="apear != 'couponAdd'"> <el-radio v-model="editForm.effectiveType" label="1" :disabled="apear != 'couponAdd'">
领取后 领取后
<el-input v-model="editForm.effectiveDays" style="width: 100px; margin-left: 5px; margin-right: 5px" <el-input v-model="editForm.effectiveDays" style="width: 100px; margin-left: 5px; margin-right: 5px" :disabled="apear != 'couponAdd' || editForm.effectiveType != 1" />
:disabled="apear != 'couponAdd' || editForm.effectiveType != 1" />
天内有效 天内有效
</el-radio> </el-radio>
</el-form-item> </el-form-item>
...@@ -101,21 +96,16 @@ ...@@ -101,21 +96,16 @@
<template slot="useBarriersHtml"> <template slot="useBarriersHtml">
<el-radio v-model="editForm.useBarriers" label="1" :disabled="apear != 'couponAdd'">无限制</el-radio> <el-radio v-model="editForm.useBarriers" label="1" :disabled="apear != 'couponAdd'">无限制</el-radio>
<el-form-item prop="full" ref="full"> <el-form-item prop="full" ref="full">
<el-radio v-model="editForm.useBarriers" label="2" <el-radio v-model="editForm.useBarriers" label="2" :disabled="apear != 'couponAdd' || editForm.useChannel == 2">
:disabled="apear != 'couponAdd' || editForm.useChannel == 2">
订单满 订单满
<el-input v-model="editForm.full" placeholder="输入金额(元)" <el-input v-model="editForm.full" placeholder="输入金额(元)" style="width: 110px; margin-left: 5px; margin-right: 5px" :disabled="apear != 'couponAdd' || editForm.useBarriers != 2" />
style="width: 110px; margin-left: 5px; margin-right: 5px"
:disabled="apear != 'couponAdd' || editForm.useBarriers != 2" />
元可用 元可用
</el-radio> </el-radio>
</el-form-item> </el-form-item>
</template> </template>
<template slot="denominationHtml"> <template slot="denominationHtml">
<el-input v-model="editForm.denomination" id="denomination" style="width: 150px" <el-input v-model="editForm.denomination" id="denomination" placeholder="请输入面值" :disabled="apear != 'couponAdd'" @blur.native.capture="editForm.useChannel == 1 && denominationBlur($event)">
:disabled="apear != 'couponAdd'" <!-- <span slot="append">元</span> -->
@blur.native.capture="editForm.useChannel == 1 && denominationBlur($event)">
<span slot="append">元</span>
</el-input> </el-input>
<span style="color: red; margin-left: 15px" v-if="priceFlag && editForm.useChannel == 1">{{ <span style="color: red; margin-left: 15px" v-if="priceFlag && editForm.useChannel == 1">{{
selectedAllProList.length ? '存在零售价低于代金券的商品' : '系统暂无已创建的商品,请先创建好商品后再配置代金券' selectedAllProList.length ? '存在零售价低于代金券的商品' : '系统暂无已创建的商品,请先创建好商品后再配置代金券'
...@@ -124,9 +114,8 @@ ...@@ -124,9 +114,8 @@
<!-- 库存,集团版集团账号-无限制库存;其他-输入框 --> <!-- 库存,集团版集团账号-无限制库存;其他-输入框 -->
<template slot="stock" slot-scope="scope"> <template slot="stock" slot-scope="scope">
<span v-if="$isGroupUp">无库存限制</span> <span v-if="$isGroupUp">无库存限制</span>
<el-input :disabled="apear != 'couponAdd'" v-else class="w-150" v-model="editForm[scope.scope.name]" <el-input :disabled="apear != 'couponAdd'" v-else class="w-150" v-model="editForm[scope.scope.name]" placeholder="请输入库存">
placeholder="请输入库存"> <!-- <span slot="suffix">张</span> -->
<span slot="suffix">张</span>
</el-input> </el-input>
</template> </template>
<!-- 只有使用途径为线上商品时才有效,到店核销时屏蔽 --> <!-- 只有使用途径为线上商品时才有效,到店核销时屏蔽 -->
...@@ -138,22 +127,19 @@ ...@@ -138,22 +127,19 @@
</el-radio> </el-radio>
</template> </template>
<!-- 新增时并且为指定商品时显示,编辑或者查看时也显示 --> <!-- 新增时并且为指定商品时显示,编辑或者查看时也显示 -->
<div slot="proTable" class="select-pro"> <div slot="proTable" class="select-pro" :style="{ 'margin-left': defaultLabelWidth, width: `calc(100% - ${defaultLabelWidth} )` }">
<!-- <div style="height:70px" v-if="editForm.goodsRefList.length"></div> --> <!-- <div style="height:70px" v-if="editForm.goodsRefList.length"></div> -->
<GLTable v-show="editForm.goodsRefList.length" :hasPage="false" :tableParams="tableParams" <GLTable v-show="editForm.goodsRefList.length" :hasPage="false" :tableParams="tableParams" :tableData="editForm.goodsRefList" style="padding-left: 10px; margin-right: 340px; max-height: 350px; overflow: auto">
:tableData="editForm.goodsRefList"
style="padding-left: 10px; margin-right: 340px; max-height: 350px; overflow: auto">
<template slot="goodsImage" slot-scope="scope"> <template slot="goodsImage" slot-scope="scope">
<img class="img-60" :src="scope.scope.goodsImage" /> <img class="img-60" :src="scope.scope.goodsImage" />
</template> </template>
<span slot="auth-button" slot-scope="scope"> <span slot="customBtn" slot-scope="scope">
<el-button type="text" @click="handleProDelete(scope)">删除</el-button> <el-button class="p-0" type="text" @click="handleProDelete(scope)">删除</el-button>
</span> </span>
</GLTable> </GLTable>
</div> </div>
<template slot="useDescriptionHtml"> <template slot="useDescriptionHtml">
<el-input type="textarea" v-model="editForm.useDescription" style="width: 320px" <el-input type="textarea" v-model="editForm.useDescription" style="width: 320px" :autosize="{ minRows: 2, maxRows: 4 }" maxlength="200" :disabled="userDisable" />
:autosize="{ minRows: 2, maxRows: 4 }" maxlength="200" :disabled="userDisable" />
</template> </template>
<template slot="editHtml"> <template slot="editHtml">
<el-button style="margin-left: 80px" @click="editMessage">编辑</el-button> <el-button style="margin-left: 80px" @click="editMessage">编辑</el-button>
...@@ -161,8 +147,7 @@ ...@@ -161,8 +147,7 @@
</glsx-combi-form> </glsx-combi-form>
<div v-if="$isGroupUp"> <div v-if="$isGroupUp">
<p class="edit-title">适用门店配置</p> <p class="edit-title">适用门店配置</p>
<glsx-combi-form class="edit-form-container" ref="merchantRef" :isEdit="true" :isBlock="true" <glsx-combi-form class="edit-form-container" ref="merchantRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="merchantEditFormData" :formRules="merchantRule">
:formRef="editChildRef" :formObj="editForm" :formData="merchantEditFormData" :formRules="merchantRule">
</glsx-combi-form> </glsx-combi-form>
</div> </div>
</div> </div>
...@@ -170,9 +155,7 @@ ...@@ -170,9 +155,7 @@
<el-button @click="handleCancel" size="medium">{{ apear != 'couponSee' ? '取消' : '返回' }}</el-button> <el-button @click="handleCancel" size="medium">{{ apear != 'couponSee' ? '取消' : '返回' }}</el-button>
<el-button v-if="showSubmit" type="primary" @click="handleConfirm" size="medium" :loading="loading">提交</el-button> <el-button v-if="showSubmit" type="primary" @click="handleConfirm" size="medium" :loading="loading">提交</el-button>
</GLFooter> </GLFooter>
<select-muti-pro-forcoupon-dialog v-if="isMutiSelectVisible" :isMutiSelectVisible="isMutiSelectVisible" <select-muti-pro-forcoupon-dialog v-if="isMutiSelectVisible" :isMutiSelectVisible="isMutiSelectVisible" :searchForm="searchProForm" :selectedProList="selectedProList" @handleMutiSelectConfirm="handleMutiSelectConfirm" @handleMutiSelectClose="handleMutiSelectClose"></select-muti-pro-forcoupon-dialog>
:searchForm="searchProForm" :selectedProList="selectedProList" @handleMutiSelectConfirm="handleMutiSelectConfirm"
@handleMutiSelectClose="handleMutiSelectClose"></select-muti-pro-forcoupon-dialog>
</div> </div>
</template> </template>
...@@ -224,7 +207,6 @@ export default { ...@@ -224,7 +207,6 @@ export default {
}, },
//商品列表 //商品列表
tableParams: { tableParams: {
tableOption: true,
tableColumns: [ tableColumns: [
{ {
label: '缩略图', label: '缩略图',
...@@ -238,6 +220,11 @@ export default { ...@@ -238,6 +220,11 @@ export default {
{ {
label: '零售价(元)', label: '零售价(元)',
prop: 'retailPrice' prop: 'retailPrice'
},
{
label: '操作',
prop: '',
addHtml: 'customBtn'
} }
] ]
}, },
...@@ -272,15 +259,14 @@ export default { ...@@ -272,15 +259,14 @@ export default {
{ {
label: '优惠券名称', label: '优惠券名称',
name: 'couponName', name: 'couponName',
width: '320px',
type: 'input', type: 'input',
maxlength: 20 maxlength: 20
}, },
{ {
label: '预估成本/元', label: '预估成本/元',
name: 'anticipatedCost', name: 'anticipatedCost',
width: '320px',
type: 'input', type: 'input',
placeholder: '请输入预估成本',
isDisabled: false isDisabled: false
}, },
{ {
...@@ -311,12 +297,12 @@ export default { ...@@ -311,12 +297,12 @@ export default {
isHide: true isHide: true
}, },
{ {
label: '面值', label: '面值/元',
name: 'denomination', name: 'denomination',
addHtml: 'denominationHtml' addHtml: 'denominationHtml'
}, },
{ {
label: '库存', label: '库存/张',
name: 'stock', name: 'stock',
addHtml: 'stock' addHtml: 'stock'
// width: '150px', // width: '150px',
...@@ -817,9 +803,9 @@ export default { ...@@ -817,9 +803,9 @@ export default {
this.cancelJump() this.cancelJump()
} }
}) })
.finally(() => { .finally(() => {
this.loading = false this.loading = false
}) })
} }
}) })
}, },
......
...@@ -2,27 +2,6 @@ ...@@ -2,27 +2,6 @@
<template> <template>
<div class="edit-share marketing edit-box"> <div class="edit-share marketing edit-box">
<div class="container edit-container" style="position: relative" v-loading="loading"> <div class="container edit-container" style="position: relative" v-loading="loading">
<!-- <div class="right_show">
<div class="card-top"></div>
<div class="card-middle">
<div>
<span class="cname">{{ editForm.couponName }}</span>
<span class="ctype"><span class="ctypeName">折扣券</span></span>
</div>
<div class="ctime">
<span class="ctime_name">有效期:</span>
<span class="ctime_content" v-if="editForm.effectiveType == 1">{{ editForm.effectiveDays }}天</span>
<span class="ctime_content" v-if="editForm.effectiveType == 2">{{ couponTime }}</span>
</div>
<div class="ctime">
<span class="ctime_name">核销券码:</span>
</div>
<img class="ccode" src="../../assets/coupon/code2.png" />
<div class="ccodeName">GH078-003</div>
<div class="cremarks">使用说明:</div>
<div class="cremarks_content">{{ editForm.useDescription }}</div>
</div>
</div> -->
<div class="right_show"> <div class="right_show">
<div class="card-top"></div> <div class="card-top"></div>
<div class="slider"> <div class="slider">
...@@ -32,9 +11,6 @@ ...@@ -32,9 +11,6 @@
<img src="../../images/unDiscount.png" class="couponImg" v-if="editForm.status == 3" /> <img src="../../images/unDiscount.png" class="couponImg" v-if="editForm.status == 3" />
<img src="../../images/discount.png" class="couponImg" v-else /> <img src="../../images/discount.png" class="couponImg" v-else />
</div> </div>
<!-- <div class="ctype">
<div class="ctypeName"></div>
</div> -->
<div class="validityPeriod"> <div class="validityPeriod">
<!-- <span class="ctime_name">有效期:</span> --> <!-- <span class="ctime_name">有效期:</span> -->
<span v-if="editForm.effectiveType == 3">永久有效</span> <span v-if="editForm.effectiveType == 3">永久有效</span>
...@@ -45,8 +21,7 @@ ...@@ -45,8 +21,7 @@
<div :class="editForm.status == 3 ? 'darkColor' : ''" class="ctime"> <div :class="editForm.status == 3 ? 'darkColor' : ''" class="ctime">
<!-- <span class="ctime_name">使用限制:</span> --> <!-- <span class="ctime_name">使用限制:</span> -->
<span class="ctime_content" style="font-size: 20px;font-weight: 600;" <span class="ctime_content" style="font-size: 20px;font-weight: 600;" v-show="editForm.discountIntensity">{{ editForm.discountIntensity }}</span>
v-show="editForm.discountIntensity">{{ editForm.discountIntensity }}</span>
<span v-show="editForm.discountIntensity" style="font-size: 12px;">折</span> <span v-show="editForm.discountIntensity" style="font-size: 12px;">折</span>
<span class="ctime_content">{{ editForm.useBarriers == 1 ? '无门槛' : '满' + editForm.full + '元可用' }}</span> <span class="ctime_content">{{ editForm.useBarriers == 1 ? '无门槛' : '满' + editForm.full + '元可用' }}</span>
</div> </div>
...@@ -81,8 +56,7 @@ ...@@ -81,8 +56,7 @@
</div> </div>
</div> </div>
<p class="edit-title">{{ title }}折扣券</p> <p class="edit-title">{{ title }}折扣券</p>
<glsx-combi-form class="edit-form-container" ref="editFormRef" :isEdit="true" :isBlock="true" <glsx-combi-form class="edit-form-container" ref="editFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
:formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<template slot="directionalFlagHtml"> <template slot="directionalFlagHtml">
<div> <div>
<el-radio v-model="editForm.directionalFlag" label="1" :disabled="apear != 'couponAdd'">所有客户可用</el-radio> <el-radio v-model="editForm.directionalFlag" label="1" :disabled="apear != 'couponAdd'">所有客户可用</el-radio>
...@@ -100,18 +74,13 @@ ...@@ -100,18 +74,13 @@
<template slot="effectiveHtml"> <template slot="effectiveHtml">
<el-form-item prop="effectiveTime" ref="effectiveTime" style="margin-top: 12px; display: block"> <el-form-item prop="effectiveTime" ref="effectiveTime" style="margin-top: 12px; display: block">
<el-radio v-model="editForm.effectiveType" label="2" :disabled="apear != 'couponAdd'" id="effectiveTime"> <el-radio v-model="editForm.effectiveType" label="2" :disabled="apear != 'couponAdd'" id="effectiveTime">
<el-date-picker v-model="editForm.effectiveTime" @change="haveChange" type="datetimerange" <el-date-picker v-model="editForm.effectiveTime" @change="haveChange" type="datetimerange" style="width: 340px" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :default-time="defaultTime" :format="format" :picker-options="pickerOption" :disabled="editForm.effectiveType != 2 || apear != 'couponAdd'" clearable></el-date-picker>
style="width: 340px" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"
value-format="yyyy-MM-dd HH:mm:ss" :default-time="defaultTime" :format="format"
:picker-options="pickerOption" :disabled="editForm.effectiveType != 2 || apear != 'couponAdd'"
clearable></el-date-picker>
</el-radio> </el-radio>
</el-form-item> </el-form-item>
<el-form-item prop="effectiveDays" ref="effectiveDays" id="effectiveDays"> <el-form-item prop="effectiveDays" ref="effectiveDays" id="effectiveDays">
<el-radio v-model="editForm.effectiveType" label="1" :disabled="apear != 'couponAdd'"> <el-radio v-model="editForm.effectiveType" label="1" :disabled="apear != 'couponAdd'">
领取后 领取后
<el-input v-model="editForm.effectiveDays" style="width: 100px; margin-left: 5px; margin-right: 5px" <el-input v-model="editForm.effectiveDays" style="width: 100px; margin-left: 5px; margin-right: 5px" :disabled="apear != 'couponAdd' || editForm.effectiveType != 1" />
:disabled="apear != 'couponAdd' || editForm.effectiveType != 1" />
天内有效 天内有效
</el-radio> </el-radio>
</el-form-item> </el-form-item>
...@@ -121,9 +90,7 @@ ...@@ -121,9 +90,7 @@
<el-form-item prop="full" ref="full"> <el-form-item prop="full" ref="full">
<el-radio v-model="editForm.useBarriers" label="2" :disabled="apear != 'couponAdd'"> <el-radio v-model="editForm.useBarriers" label="2" :disabled="apear != 'couponAdd'">
满 满
<el-input v-model="editForm.full" @blur="loseFocus" <el-input v-model="editForm.full" @blur="loseFocus" style="width: 100px; margin-left: 5px; margin-right: 5px" :disabled="apear != 'couponAdd' || editForm.useBarriers != 2" />
style="width: 100px; margin-left: 5px; margin-right: 5px"
:disabled="apear != 'couponAdd' || editForm.useBarriers != 2" />
元可用 元可用
</el-radio> </el-radio>
</el-form-item> </el-form-item>
...@@ -131,14 +98,12 @@ ...@@ -131,14 +98,12 @@
<!-- 库存,集团版集团账号-无限制库存;其他-输入框 --> <!-- 库存,集团版集团账号-无限制库存;其他-输入框 -->
<template slot="stock" slot-scope="scope"> <template slot="stock" slot-scope="scope">
<span v-if="$isGroupUp">无库存限制</span> <span v-if="$isGroupUp">无库存限制</span>
<el-input :disabled="apear != 'couponAdd'" v-else class="w-150" v-model="editForm[scope.scope.name]" <el-input :disabled="apear != 'couponAdd'" v-else class="w-150" v-model="editForm[scope.scope.name]" placeholder="请输入库存">
placeholder="请输入库存"> <!-- <span slot="suffix">张</span> -->
<span slot="suffix">张</span>
</el-input> </el-input>
</template> </template>
<template slot="useDescriptionHtml"> <template slot="useDescriptionHtml">
<el-input type="textarea" v-model="editForm.useDescription" style="width: 320px" <el-input type="textarea" v-model="editForm.useDescription" :autosize="{ minRows: 2, maxRows: 4 }" maxlength="200" :disabled="userDisable" />
:autosize="{ minRows: 2, maxRows: 4 }" maxlength="200" :disabled="userDisable" />
</template> </template>
<template slot="editHtml"> <template slot="editHtml">
<el-button style="margin-left: 80px" @click="editMessage">编辑</el-button> <el-button style="margin-left: 80px" @click="editMessage">编辑</el-button>
...@@ -146,9 +111,7 @@ ...@@ -146,9 +111,7 @@
</glsx-combi-form> </glsx-combi-form>
<div v-if="$isGroupUp"> <div v-if="$isGroupUp">
<p class="edit-title">适用门店配置</p> <p class="edit-title">适用门店配置</p>
<glsx-combi-form class="edit-form-container" ref="merchantRef" :isEdit="true" :isBlock="true" <glsx-combi-form class="edit-form-container" ref="merchantRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="merchantEditFormData" :formRules="merchantRule"></glsx-combi-form>
:formRef="editChildRef" :formObj="editForm" :formData="merchantEditFormData" :formRules="merchantRule">
</glsx-combi-form>
</div> </div>
</div> </div>
<GLFooter> <GLFooter>
...@@ -230,23 +193,21 @@ export default { ...@@ -230,23 +193,21 @@ export default {
{ {
label: '优惠券名称', label: '优惠券名称',
name: 'couponName', name: 'couponName',
width: '320px',
type: 'input', type: 'input',
maxlength: 20 maxlength: 20
}, },
{ {
label: '预估成本/元', label: '预估成本/元',
name: 'anticipatedCost', name: 'anticipatedCost',
width: '320px',
type: 'input', type: 'input',
isDisabled: false isDisabled: false,
placeholder: '请输入预估成本'
}, },
{ {
label: '优惠内容', label: '优惠内容/折',
name: 'discountIntensity', name: 'discountIntensity',
width: '180px',
type: 'input', type: 'input',
append: '折' placeholder: '请输入优惠内容'
}, },
{ {
label: '使用限制', label: '使用限制',
...@@ -254,7 +215,7 @@ export default { ...@@ -254,7 +215,7 @@ export default {
addHtml: 'useLimitHtml' addHtml: 'useLimitHtml'
}, },
{ {
label: '库存', label: '库存/张',
name: 'stock', name: 'stock',
addHtml: 'stock' addHtml: 'stock'
// width: '180px', // width: '180px',
...@@ -576,9 +537,9 @@ export default { ...@@ -576,9 +537,9 @@ export default {
this.cancelJump() this.cancelJump()
} }
}) })
.finally(() => { .finally(() => {
this.loading = false this.loading = false
}) })
} }
}) })
}, },
......
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
<template slot="stock" slot-scope="scope"> <template slot="stock" slot-scope="scope">
<span v-if="$isGroupUp">无库存限制</span> <span v-if="$isGroupUp">无库存限制</span>
<el-input :disabled="apear != 'couponAdd'" v-else class="w-150" v-model="editForm[scope.scope.name]" placeholder="请输入库存"> <el-input :disabled="apear != 'couponAdd'" v-else class="w-150" v-model="editForm[scope.scope.name]" placeholder="请输入库存">
<span slot="suffix">张</span> <!-- <span slot="suffix">张</span> -->
</el-input> </el-input>
</template> </template>
<template slot="directionalFlagHtml"> <template slot="directionalFlagHtml">
...@@ -174,19 +174,17 @@ export default { ...@@ -174,19 +174,17 @@ export default {
{ {
label: '优惠券名称', label: '优惠券名称',
name: 'couponName', name: 'couponName',
width: '320px',
type: 'input', type: 'input',
maxlength: 20 maxlength: 20
}, },
{ {
label: '预估成本/元', label: '预估成本/元',
name: 'anticipatedCost', name: 'anticipatedCost',
width: '320px',
type: 'input', type: 'input',
isDisabled: false isDisabled: false
}, },
{ {
label: '库存', label: '库存/张',
name: 'stock', name: 'stock',
addHtml: 'stock' addHtml: 'stock'
// width: '180px', // width: '180px',
......
...@@ -3,15 +3,15 @@ ...@@ -3,15 +3,15 @@
<div class="topMsg"> <div class="topMsg">
<p class="pageTitle">基本信息</p> <p class="pageTitle">基本信息</p>
</div> </div>
<div class="live-room container" style="padding-top: 20px;" v-loading="sloading"> <div class="live-room container gl-form-page" style="padding-top: 20px;" v-loading="sloading">
<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="120px" class="demo-ruleForm"> <el-form :model="ruleForm" :rules="rules" ref="ruleForm" :label-width="defaultLabelWidth" class="demo-ruleForm">
<el-form-item size="small" label="服务名称" prop="couponName" style="width: 440px" id="couponName"> <el-form-item size="small" label="服务名称:" prop="couponName" style="width: 440px" id="couponName">
<el-input size="small" :disabled="disabledContent" v-model.trim="ruleForm.couponName" maxlength="20" placeholder="请输入服务名称,如“精洗轿车”"></el-input> <el-input size="small" :disabled="disabledContent" v-model.trim="ruleForm.couponName" maxlength="20" placeholder="请输入服务名称,如“精洗轿车”"></el-input>
</el-form-item> </el-form-item>
<el-form-item size="small" label="预估成本/元" prop="anticipatedCost" style="width: 440px" id="anticipatedCost"> <el-form-item size="small" label="预估成本/元:" prop="anticipatedCost" style="width: 440px" id="anticipatedCost">
<el-input size="small" :disabled="disabledCost" v-model.trim="ruleForm.anticipatedCost" maxlength="20" placeholder="请输入预估成本"></el-input> <el-input size="small" :disabled="disabledCost" v-model.trim="ruleForm.anticipatedCost" maxlength="20" placeholder="请输入预估成本"></el-input>
</el-form-item> </el-form-item>
<el-form-item size="small" label="有效期" prop="effectiveType"> <el-form-item size="small" label="有效期:" prop="effectiveType">
<div class="radioGroupWrap"> <div class="radioGroupWrap">
<el-radio-group v-model="ruleForm.effectiveType" :disabled="disabledContent"> <el-radio-group v-model="ruleForm.effectiveType" :disabled="disabledContent">
<el-radio :label="3" class="itemBlock">永久有效</el-radio> <el-radio :label="3" class="itemBlock">永久有效</el-radio>
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
</el-radio-group> </el-radio-group>
</div> </div>
</el-form-item> </el-form-item>
<el-form-item size="small" label="使用限制" prop="customUseLimit"> <el-form-item size="small" label="使用限制:" prop="customUseLimit">
<div class="radioGroupWrap"> <div class="radioGroupWrap">
<el-radio-group v-model="ruleForm.customUseLimit" :disabled="disabledContent"> <el-radio-group v-model="ruleForm.customUseLimit" :disabled="disabledContent">
<el-radio :label="0" class="itemBlock">不限制使用次数</el-radio> <el-radio :label="0" class="itemBlock">不限制使用次数</el-radio>
...@@ -60,36 +60,30 @@ ...@@ -60,36 +60,30 @@
</el-radio-group> </el-radio-group>
</div> </div>
</el-form-item> </el-form-item>
<el-form-item v-if="!$isGroupUp" size="small" label="会员价" prop="vipPrice" style="width: 315px"> <el-form-item v-if="!$isGroupUp" size="small" label="会员价/元:" prop="vipPrice">
<el-input size="small" :disabled="disabledContent" maxlength="8" v-model="ruleForm.vipPrice" placeholder="请输入" @keyup.native="ruleForm.vipPrice = oninput(ruleForm.vipPrice)"> <el-input size="small" :disabled="disabledContent" maxlength="8" v-model="ruleForm.vipPrice" placeholder="请输入会员价" @keyup.native="ruleForm.vipPrice = oninput(ruleForm.vipPrice)">
<!-- <template slot="append">元</template> --> <!-- <span slot="suffix" class="suffix-label">元</span> -->
<span slot="suffix" class="suffix-label">元</span>
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item v-if="!$isGroupUp" size="small" label="门店价" prop="shopPrice" style="width: 315px"> <el-form-item v-if="!$isGroupUp" size="small" label="门店价/元:" prop="shopPrice">
<el-input size="small" :disabled="disabledContent" maxlength="8" v-model="ruleForm.shopPrice" placeholder="请输入" @keyup.native="ruleForm.shopPrice = oninput(ruleForm.shopPrice)"> <el-input size="small" :disabled="disabledContent" maxlength="8" v-model="ruleForm.shopPrice" placeholder="请输入门店价" @keyup.native="ruleForm.shopPrice = oninput(ruleForm.shopPrice)">
<!-- <template slot="append">元</template> --> <!-- <span slot="suffix" class="suffix-label">元</span> -->
<span slot="suffix" class="suffix-label">元</span>
</el-input> </el-input>
</el-form-item> </el-form-item>
<!-- 库存,集团版集团账号-无限制库存;其他-输入框 --> <!-- 库存,集团版集团账号-无限制库存;其他-输入框 -->
<el-form-item size="small" label="库存" prop="stock" style="width: 315px"> <el-form-item size="small" label="库存/张:" prop="stock">
<!-- <el-input size="small" :disabled="title == '查看'" maxlength="6" v-model.number="ruleForm.stock" placeholder="请输入"></el-input> --> <!-- <el-input size="small" :disabled="title == '查看'" maxlength="6" v-model.number="ruleForm.stock" placeholder="请输入"></el-input> -->
<span v-if="$isGroupUp">无库存限制</span> <span v-if="$isGroupUp">无库存限制</span>
<el-input :disabled="title == '查看'" v-else class="w-150" v-model="ruleForm.stock" placeholder="请输入库存"> <el-input :disabled="title == '查看'" v-else class="w-150" v-model="ruleForm.stock" placeholder="请输入库存">
<span slot="suffix">张</span> <!-- <span slot="suffix">张</span> -->
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item size="small" label="使用说明" prop="useDescription" style="width: 670px"> <el-form-item size="small" label="使用说明:" prop="useDescription">
<el-input size="small" :rows="6" :disabled="disabledDescription" type="textarea" v-model="ruleForm.useDescription" placeholder="请输入" maxlength="200" show-word-limit></el-input> <el-input size="small" :rows="6" :disabled="disabledDescription" type="textarea" v-model="ruleForm.useDescription" placeholder="请输入" maxlength="200" show-word-limit></el-input>
</el-form-item> </el-form-item>
<el-form-item size="small" style="margin-left: -100px" v-show="isEdit"> <el-form-item size="small" style="margin-left: -100px" v-show="isEdit">
<el-button style="margin-left: 80px" @click="editMessage">编辑</el-button> <el-button style="margin-left: 80px" @click="editMessage">编辑</el-button>
</el-form-item> </el-form-item>
<!-- <el-form-item size="small">
<el-button type="primary" @click="submitForm('ruleForm')" size="small">创建</el-button>
<el-button type="primary" @click="resetForm('ruleForm')" size="small">重置</el-button>
</el-form-item> -->
</el-form> </el-form>
<div class="edit-container" v-if="$isGroupUp"> <div class="edit-container" v-if="$isGroupUp">
...@@ -225,12 +219,6 @@ export default { ...@@ -225,12 +219,6 @@ export default {
ruleForm: { ruleForm: {
anticipatedCost: '', anticipatedCost: '',
couponName: '', couponName: '',
// region: '',
// date1: '',
// date2: '',
// delivery: false,
// type: [],
// resource: '',
effectiveType: 3, //有效期(默认永久有效) effectiveType: 3, //有效期(默认永久有效)
effectiveDays: '', effectiveDays: '',
customUseLimit: 0, //使用限制(默认不限制使用次数) customUseLimit: 0, //使用限制(默认不限制使用次数)
...@@ -248,10 +236,6 @@ export default { ...@@ -248,10 +236,6 @@ export default {
rules: { rules: {
anticipatedCost: [{ required: true, message: '请输入预估成本', trigger: 'change' }], anticipatedCost: [{ required: true, message: '请输入预估成本', trigger: 'change' }],
couponName: [{ required: true, message: '请输入服务名称', trigger: 'blur' }], couponName: [{ required: true, message: '请输入服务名称', trigger: 'blur' }],
// region: [{ required: true, message: '请选择活动区域', trigger: 'change' }],
// date1: [{ type: 'date', required: true, message: '请选择日期', trigger: 'change' }],
// date2: [{ type: 'date', required: true, message: '请选择时间', trigger: 'change' }],
// type: [{ type: 'array', required: true, message: '请至少选择一个活动性质', trigger: 'change' }],
effectiveType: [{ required: true, message: '请选择有效期', trigger: 'change' }], effectiveType: [{ required: true, message: '请选择有效期', trigger: 'change' }],
customUseLimit: [{ required: true, message: '请选择使用限制', trigger: 'change' }], customUseLimit: [{ required: true, message: '请选择使用限制', trigger: 'change' }],
vipPrice: [ vipPrice: [
...@@ -403,33 +387,33 @@ export default { ...@@ -403,33 +387,33 @@ export default {
}, },
submitForm(formName) { submitForm(formName) {
clearTimeout(this.timer) clearTimeout(this.timer)
this.timer = setTimeout(() => { this.timer = setTimeout(() => {
this.$refs[formName].validate((valid, errorObj) => { this.$refs[formName].validate((valid, errorObj) => {
var merchantval = true var merchantval = true
var merchantErrorObj = [] var merchantErrorObj = []
if (this.$isGroupUp) { if (this.$isGroupUp) {
this.$refs.merchantRef.$refs[this.editChildRef].validate((merchantVaild, errorObj) => { this.$refs.merchantRef.$refs[this.editChildRef].validate((merchantVaild, errorObj) => {
merchantval = merchantVaild merchantval = merchantVaild
merchantErrorObj = errorObj merchantErrorObj = errorObj
}) })
} }
if (!valid) { if (!valid) {
this.whereToGo(Object.keys(errorObj)[0]) this.whereToGo(Object.keys(errorObj)[0])
} else if (!merchantval) { } else if (!merchantval) {
this.whereToGo(Object.keys(merchantErrorObj)[0]) this.whereToGo(Object.keys(merchantErrorObj)[0])
} }
if (valid && merchantval) { if (valid && merchantval) {
if (this.isEdit == true) { if (this.isEdit == true) {
this.updateService() this.updateService()
} else {
this.createService()
}
} else { } else {
this.createService() return false
} }
} else { })
return false }, 500)
}
})
},500)
}, },
//创建服务 //创建服务
createService() { createService() {
...@@ -636,7 +620,7 @@ export default { ...@@ -636,7 +620,7 @@ export default {
.radioGroupWrap { .radioGroupWrap {
width: 550px; width: 550px;
height: 164px; height: 164px;
background-color: #f4f6fc; background-color: #f9f9f9;
padding-top: 10px; padding-top: 10px;
padding-left: 20px; padding-left: 20px;
} }
......
...@@ -26,11 +26,11 @@ ...@@ -26,11 +26,11 @@
<span class="cursor-pointer" @click="orderCodeHandleDetail(scope.scope)" v-else>{{ scope.scope.orderCode }}</span> <span class="cursor-pointer" @click="orderCodeHandleDetail(scope.scope)" v-else>{{ scope.scope.orderCode }}</span>
</span> </span>
</GLTable> </GLTable>
<GLDialog mode="small" :visible.sync="isDialogVisible" @onCancel="handleClose" @onOk="handleConfirm"> <GLDialog mode="mid" :visible.sync="isDialogVisible" @onCancel="handleClose" @onOk="handleConfirm">
<div slot="title">优惠券核销(请确保用户到店后核销,避免引起不必要问题)</div> <div slot="title">优惠券核销(请确保用户到店后核销,避免引起不必要问题)</div>
<div class="small-content"> <div class="gl-form-page m-t-20">
<el-form :rules="rules" ref="ruleForm" :model="ruleForm" label-width="80px"> <el-form :rules="rules" ref="ruleForm" :model="ruleForm" :label-width="defaultLabelWidth">
<el-form-item size="small" label="核销码" prop="verficationCode" style="width: 380px"> <el-form-item size="small" label="核销码:" prop="verficationCode">
<el-input size="small" v-model.trim="ruleForm.verficationCode" maxlength="50" placeholder="请输入核销码"></el-input> <el-input size="small" v-model.trim="ruleForm.verficationCode" maxlength="50" placeholder="请输入核销码"></el-input>
</el-form-item> </el-form-item>
</el-form> </el-form>
......
...@@ -5,10 +5,10 @@ ...@@ -5,10 +5,10 @@
<!-- 基础信息 --> <!-- 基础信息 -->
<div class="title">基础信息</div> <div class="title">基础信息</div>
<div class="info-box"> <div class="info-box">
<div class="info-content"> <div class="info-content gl-form-page">
<el-form class="basic-form" :model="basicForm" :rules="basicRules" ref="basicForm" label-width="120px"> <el-form class="basic-form" :model="basicForm" :rules="basicRules" ref="basicForm" label-width="154px">
<el-form-item prop="userList"> <el-form-item prop="userList">
<label slot="label" class="required">选择群发账号</label> <label slot="label" class="required">选择群发账号:</label>
<el-button size="small" :disabled="isSelectCrowd" @click="openMembers"> <el-button size="small" :disabled="isSelectCrowd" @click="openMembers">
<i class="el-icon-plus"></i> <i class="el-icon-plus"></i>
选择成员 选择成员
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
</div> </div>
</div> </div>
</el-form-item> </el-form-item>
<el-form-item label="选择客户" prop="selectType"> <el-form-item label="选择客户:" prop="selectType">
<el-radio-group v-model="basicForm.selectType" @change="radioChange"> <el-radio-group v-model="basicForm.selectType" @change="radioChange">
<el-radio :label="1">全部客户</el-radio> <el-radio :label="1">全部客户</el-radio>
<el-radio :label="2">筛选客户</el-radio> <el-radio :label="2">筛选客户</el-radio>
...@@ -35,8 +35,8 @@ ...@@ -35,8 +35,8 @@
</el-radio-group> </el-radio-group>
<div class="filter-box" v-show="basicForm.selectType == 2"> <div class="filter-box" v-show="basicForm.selectType == 2">
<div class="filter-memeber"> <div class="filter-memeber">
<el-form :model="basicForm.condition" label-width="120px"> <el-form :model="basicForm.condition" label-width="154px">
<el-form-item label="性别"> <el-form-item label="性别:">
<el-radio-group v-model="basicForm.condition.sex" @change="valueChange"> <el-radio-group v-model="basicForm.condition.sex" @change="valueChange">
<el-radio label>全部</el-radio> <el-radio label>全部</el-radio>
<el-radio :label="1">男性</el-radio> <el-radio :label="1">男性</el-radio>
...@@ -44,15 +44,15 @@ ...@@ -44,15 +44,15 @@
<el-radio :label="0">未知性别</el-radio> <el-radio :label="0">未知性别</el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item label="所在群聊"> <el-form-item label="所在群聊:">
<el-select v-model="basicForm.condition.chat" @change="valueChange" @focus="groupFocus" :size="size" value-key="id" multiple collapse-tags placeholder="请选择"> <el-select v-model="basicForm.condition.chat" @change="valueChange" @focus="groupFocus" :size="size" value-key="id" multiple collapse-tags placeholder="请选择">
<el-option v-for="item in groupList" :key="item.id" :label="item.groupName" :value="item"></el-option> <el-option v-for="item in groupList" :key="item.id" :label="item.groupName" :value="item"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="添加客户时间"> <el-form-item label="添加客户时间:">
<el-date-picker v-model="basicForm.condition.date" @change="valueChange" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" :size="size" style="width: 320px"></el-date-picker> <el-date-picker v-model="basicForm.condition.date" @change="valueChange" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" :size="size" style="width: 320px"></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item label="标签筛选"> <el-form-item label="标签筛选:">
<el-button size="small" @click="openLabel"> <el-button size="small" @click="openLabel">
<i class="el-icon-plus"></i> <i class="el-icon-plus"></i>
标签筛选 标签筛选
...@@ -95,13 +95,18 @@ ...@@ -95,13 +95,18 @@
<!-- 编辑入群欢迎语 --> <!-- 编辑入群欢迎语 -->
<div class="title">编辑群发内容</div> <div class="title">编辑群发内容</div>
<div class="group-content"> <div class="group-content">
<el-form :model="basicForm" :rules="basicRules" ref="groupForm" label-width="120px"> <el-form :model="basicForm" :rules="basicRules" ref="groupForm" label-width="154px">
<el-form-item prop="attachmentList"> <el-form-item prop="attachmentList">
<label slot="label" class="required">群发内容</label> <label slot="label" class="required">群发内容:</label>
<GLEditor ref="welcome" :form="'customer'" style="line-height: 12px;" :btnList="btnList" @previewWord="previewForm"></GLEditor> <GLEditor ref="welcome" :form="'customer'" style="line-height: 12px;" :btnList="btnList" @previewWord="previewForm"></GLEditor>
<div v-show="attachmentShow" class="el-form-item__error">{{ attachmentText }}</div> <div v-show="attachmentShow" class="el-form-item__error">{{ attachmentText }}</div>
</el-form-item> </el-form-item>
<el-form-item label="发送时间" prop="sendType"> <div class="transform-text">
<div class="tips-icon"><img src="@/assets/guestCustom/tips.png" alt /></div>
<span>每位客户每天可接收1条群发消息,超过接收上限的客户将无法再收到群发消息。</span>
<!-- <span v-if="form == 'customerGroup'">每个客户群每天可接收1条群发消息,超过接收上限的客户群将无法再收到群发消息。</span> -->
</div>
<el-form-item label="发送时间:" prop="sendType">
<el-radio-group v-model="basicForm.sendType"> <el-radio-group v-model="basicForm.sendType">
<el-radio :label="1">立即发送</el-radio> <el-radio :label="1">立即发送</el-radio>
<el-radio :label="2">定时发送</el-radio> <el-radio :label="2">定时发送</el-radio>
...@@ -454,7 +459,7 @@ export default { ...@@ -454,7 +459,7 @@ export default {
if (previewList.length != 0) { if (previewList.length != 0) {
this.basicForm.attachmentList = previewList this.basicForm.attachmentList = previewList
} }
if (this.basicForm.attachmentList && this.basicForm.attachmentList.length && this.basicForm.attachmentList[0].attType == 1 && this.basicForm.attachmentList[0].attContent != "") { if (this.basicForm.attachmentList && this.basicForm.attachmentList.length && this.basicForm.attachmentList[0].attType == 1 && this.basicForm.attachmentList[0].attContent != '') {
if (this.basicForm.attachmentList.length > 9) { if (this.basicForm.attachmentList.length > 9) {
return (this.attachmentText = '附件不可超过9个') return (this.attachmentText = '附件不可超过9个')
} else { } else {
...@@ -774,7 +779,8 @@ export default { ...@@ -774,7 +779,8 @@ export default {
.info-content { .info-content {
// width: calc(100% - 360px); // width: calc(100% - 360px);
width: 50%; width: 66%;
padding-right: 20px;
.filter-box { .filter-box {
// margin-left: 120px; // margin-left: 120px;
...@@ -816,10 +822,6 @@ export default { ...@@ -816,10 +822,6 @@ export default {
.basic-form { .basic-form {
padding: 32px 0 20px 20px; padding: 32px 0 20px 20px;
/deep/.el-input {
width: 320px;
}
} }
} }
} }
...@@ -830,8 +832,37 @@ export default { ...@@ -830,8 +832,37 @@ export default {
} }
.preview { .preview {
flex: 1;
margin-right: 24px; margin-right: 24px;
margin-bottom: 100px; margin-bottom: 58px;
}
}
.transform-text {
display: flex;
// align-items: center;
justify-self: center;
color: #000;
font-size: 14px;
padding: 10px 16px;
background-color: rgba(230, 233, 255, 0.49);
border: 1px solid rgba(88, 80, 255, 0.49);
border-radius: 4px;
line-height: 20px;
margin-left: 154px;
min-width: 488px;
max-width: 844px;
width: auto;
box-sizing: border-box;
.tips-icon {
display: flex;
align-items: center;
height: 20px;
img {
width: 14px;
height: 14px;
margin-right: 8px;
}
} }
} }
...@@ -939,10 +970,16 @@ export default { ...@@ -939,10 +970,16 @@ export default {
.el-scrollbar { .el-scrollbar {
padding-bottom: 10px; padding-bottom: 10px;
} }
.gl-form-page .el-form .welcome-box {
min-width: 488px;
max-width: 844px;
width: auto;
}
} }
.group-content { .group-content {
padding: 22px 0 20px 20px; padding: 22px 0 20px 0;
} }
.tips-text { .tips-text {
......
...@@ -5,13 +5,13 @@ ...@@ -5,13 +5,13 @@
<!-- 基础信息 --> <!-- 基础信息 -->
<div class="title">基础信息</div> <div class="title">基础信息</div>
<div class="info-box"> <div class="info-box">
<div class="info-content"> <div class="info-content gl-form-page">
<el-form :model="basicForm" class="basic-form" :rules="basicRules" ref="basicForm" label-width="120px"> <el-form :model="basicForm" class="basic-form" :rules="basicRules" ref="basicForm" label-width="154px">
<el-form-item label="群发名称" prop="massName"> <el-form-item label="群发名称:" prop="massName">
<el-input v-model="basicForm.massName" :size="size" placeholder="群发名称仅内部可见" maxlength="10"></el-input> <el-input v-model="basicForm.massName" :size="size" placeholder="群发名称仅内部可见" maxlength="10"></el-input>
</el-form-item> </el-form-item>
<el-form-item prop="userList"> <el-form-item prop="userList">
<label slot="label" class="required">选择群主</label> <label slot="label" class="required">选择群主:</label>
<el-button size="small" @click="openMembers"> <el-button size="small" @click="openMembers">
<i class="el-icon-plus"></i> <i class="el-icon-plus"></i>
全部账号 全部账号
...@@ -30,14 +30,18 @@ ...@@ -30,14 +30,18 @@
</el-form> </el-form>
<!-- 编辑入群欢迎语 --> <!-- 编辑入群欢迎语 -->
<div class="title">编辑群发内容</div> <div class="title">编辑群发内容</div>
<div> <div class="group-content">
<el-form :model="basicForm" :rules="basicRules" ref="groupForm" label-width="120px"> <el-form :model="basicForm" :rules="basicRules" ref="groupForm" label-width="154px">
<el-form-item prop="attachmentList"> <el-form-item prop="attachmentList">
<label slot="label" class="required">群发内容</label> <label slot="label" class="required">群发内容:</label>
<GLEditor ref="welcome" :form="'customerGroup'" style="line-height: 12px;" :btnList="btnList" @previewWord="previewForm"></GLEditor> <GLEditor ref="welcome" :form="'customerGroup'" style="line-height: 12px;" :btnList="btnList" @previewWord="previewForm"></GLEditor>
<div v-show="attachmentShow" class="el-form-item__error">{{ attachmentText }}</div> <div v-show="attachmentShow" class="el-form-item__error">{{ attachmentText }}</div>
</el-form-item> </el-form-item>
<el-form-item label="发送时间" prop="sendType"> <div class="transform-text">
<div class="tips-icon"><img src="@/assets/guestCustom/tips.png" alt /></div>
<span>每个客户群每天可接收1条群发消息,超过接收上限的客户群将无法再收到群发消息。</span>
</div>
<el-form-item label="发送时间:" prop="sendType">
<el-radio-group v-model="basicForm.sendType"> <el-radio-group v-model="basicForm.sendType">
<el-radio :label="1">立即发送</el-radio> <el-radio :label="1">立即发送</el-radio>
<el-radio :label="2">定时发送</el-radio> <el-radio :label="2">定时发送</el-radio>
...@@ -405,7 +409,7 @@ export default { ...@@ -405,7 +409,7 @@ export default {
message: '操作成功!' message: '操作成功!'
}) })
// this.$router.push('/customerTransform/index') // this.$router.push('/customerTransform/index')
this.$tracker.track(Object.assign({},{pageName:'群发助手',name:'新建客户群群发',params})) this.$tracker.track(Object.assign({}, { pageName: '群发助手', name: '新建客户群群发', params }))
} else { } else {
this.$message({ this.$message({
type: 'error', type: 'error',
...@@ -459,26 +463,54 @@ export default { ...@@ -459,26 +463,54 @@ export default {
justify-content: space-between; justify-content: space-between;
.info-content { .info-content {
// width: calc(100% - 360px); // width: calc(100% - 360px);
width: 50%; width: 66%;
// flex: 1; padding-right: 20px;
} }
} }
.basic-form { .basic-form {
padding: 32px 0 20px 66px; padding: 32px 0 20px 20px;
/deep/.el-input {
width: 320px;
}
} }
.form-tips { .form-tips {
font-size: 12px; font-size: 12px;
color: #999; color: #999;
} }
.preview { .preview {
flex: 1;
margin-right: 24px; margin-right: 24px;
margin-bottom: 100px; margin-bottom: 58px;
} }
} }
.transform-text {
display: flex;
// align-items: center;
justify-self: center;
color: #000;
font-size: 14px;
padding: 10px 16px;
background-color: rgba(230, 233, 255, 0.49);
border: 1px solid rgba(88, 80, 255, 0.49);
border-radius: 4px;
line-height: 20px;
margin-left: 154px;
min-width: 488px;
max-width: 844px;
width: auto;
box-sizing: border-box;
.tips-icon {
display: flex;
align-items: center;
height: 20px;
img {
width: 14px;
height: 14px;
margin-right: 8px;
}
}
}
.group-content {
padding: 22px 0 20px 0;
}
.footer-panel { .footer-panel {
display: flex; display: flex;
align-items: center; align-items: center;
...@@ -561,6 +593,11 @@ export default { ...@@ -561,6 +593,11 @@ export default {
.el-scrollbar { .el-scrollbar {
padding-bottom: 10px; padding-bottom: 10px;
} }
.gl-form-page .el-form .welcome-box {
min-width: 488px;
max-width: 844px;
width: auto;
}
} }
/deep/.content .btn-group { /deep/.content .btn-group {
line-height: 14px; line-height: 14px;
......
...@@ -17,18 +17,8 @@ ...@@ -17,18 +17,8 @@
<el-input :size="size" v-model.trim="searchForm.name" @keyup.enter.native="search" clearable placeholder="请输入姓名搜索"></el-input> <el-input :size="size" v-model.trim="searchForm.name" @keyup.enter.native="search" clearable placeholder="请输入姓名搜索"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="跟进专员类型"> <el-form-item label="跟进专员类型">
<el-select <el-select v-model="searchForm.status" clearable :size="size" placeholder="全部">
v-model="searchForm.status" <el-option v-for="item in state" :key="item.value" :label="item.label" :value="item.value"></el-option>
clearable
:size="size"
placeholder="全部"
>
<el-option
v-for="item in state"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -145,7 +135,7 @@ export default { ...@@ -145,7 +135,7 @@ export default {
}, },
unique(arr) { unique(arr) {
let res = new Set() let res = new Set()
return arr.filter((item) => { return arr.filter(item => {
let id = JSON.stringify(item) let id = JSON.stringify(item)
if (res.has(id)) { if (res.has(id)) {
return false return false
...@@ -176,7 +166,7 @@ export default { ...@@ -176,7 +166,7 @@ export default {
this.selectData = [] this.selectData = []
} }
res[0].entmicroStaffResponses.forEach(e => { res[0].entmicroStaffResponses.forEach(e => {
this.state.push({value: e.followerTypeId, label: e.followerName}) this.state.push({ value: e.followerTypeId, label: e.followerName })
}) })
this.state = this.unique(this.state) this.state = this.unique(this.state)
} else { } else {
......
...@@ -120,7 +120,7 @@ export default { ...@@ -120,7 +120,7 @@ export default {
} }
}, },
mounted() { mounted() {
this.getCustomerDetail() this.handleRefresh()
// this.getStatistic() // this.getStatistic()
// console.log(this.basicInfo.condition, '----') // console.log(this.basicInfo.condition, '----')
}, },
......
...@@ -9,38 +9,40 @@ ...@@ -9,38 +9,40 @@
</div> </div>
<div class="info-box"> <div class="info-box">
<div class="info-content"> <div class="info-content">
<el-form class="basic-form" :model="basicForm" :rules="basicRules" ref="basicForm" label-width="120px"> <div class="gl-form-page">
<el-form-item prop="userList"> <el-form class="basic-form" :model="basicForm" :rules="basicRules" ref="basicForm">
<label slot="label" class="required">发表成员</label> <el-form-item prop="userList">
<el-button size="small" @click="openMembers"> <label slot="label" class="required">发表成员:</label>
<i class="el-icon-plus"></i> <el-button size="small" @click="openMembers">
选择成员 <i class="el-icon-plus"></i>
</el-button> 选择成员
<div class="sale-select" v-show="basicForm.userList && basicForm.userList.length != 0"> </el-button>
<div :key="key" class="el-input-tag input-tag-wrapper"> <div class="sale-select" v-show="basicForm.userList && basicForm.userList.length != 0">
<el-tag effect="plain" type="info" v-for="(tag, idx) in basicForm.userList" :key="idx" closable :disable-transitions="false" @close="remove(tag, idx)"> <div :key="key" class="el-input-tag input-tag-wrapper">
<i class="el-icon-user-solid"></i> <el-tag effect="plain" type="info" v-for="(tag, idx) in basicForm.userList" :key="idx" closable :disable-transitions="false" @close="remove(tag, idx)">
{{ tag.staffName }} <i class="el-icon-user-solid"></i>
</el-tag> {{ tag.staffName }}
</el-tag>
</div>
</div> </div>
</div> <div class="filter-footer">
<div class="filter-footer"> <!-- <span>将消息发送给客户符合条件的客户</span> -->
<!-- <span>将消息发送给客户符合条件的客户</span> --> <div class="filter-number">
<div class="filter-number"> 查看客户数
查看客户数 <el-button type="text" v-show="isUpdate" :loading="viewLoading" @click="viewMembers">查看</el-button>
<el-button type="text" v-show="isUpdate" :loading="viewLoading" @click="viewMembers">查看</el-button> <!-- <span v-show="isUpdate" @click="viewMembers">查看</span> -->
<!-- <span v-show="isUpdate" @click="viewMembers">查看</span> --> <span v-show="!isUpdate">{{ groupNumber }}</span>
<span v-show="!isUpdate">{{ groupNumber }}</span> </div>
</div> </div>
</div> </el-form-item>
</el-form-item> </el-form>
</el-form> </div>
<!-- 编辑入群欢迎语 --> <!-- 编辑入群欢迎语 -->
<div class="title">编辑朋友圈消息</div> <div class="title">编辑朋友圈消息</div>
<div class="group-content"> <div class="group-content gl-form-page">
<el-form :model="basicForm" :rules="basicRules" ref="groupForm" label-width="120px"> <el-form :model="basicForm" :rules="basicRules" ref="groupForm">
<el-form-item prop="attachmentList"> <el-form-item prop="attachmentList">
<label slot="label" class="required">内容正文</label> <label slot="label" class="required">内容正文:</label>
<GLEditor ref="welcome" :form="'customer'" :btnList="btnList" @previewWord="previewForm"></GLEditor> <GLEditor ref="welcome" :form="'customer'" :btnList="btnList" @previewWord="previewForm"></GLEditor>
<div v-show="attachmentShow" class="el-form-item__error">{{ attachmentText }}</div> <div v-show="attachmentShow" class="el-form-item__error">{{ attachmentText }}</div>
<div class="tips-text"> <div class="tips-text">
...@@ -48,7 +50,7 @@ ...@@ -48,7 +50,7 @@
<span>因企业微信限制,普通图片:总像素不超过1555200,大小不超过10M,数量不超过9张。视频建议不超过1280x720,帧率30FPS,视频码率1.67 Mbps,最长不超过30S,最大不超过10MB</span> <span>因企业微信限制,普通图片:总像素不超过1555200,大小不超过10M,数量不超过9张。视频建议不超过1280x720,帧率30FPS,视频码率1.67 Mbps,最长不超过30S,最大不超过10MB</span>
</div> </div>
</el-form-item> </el-form-item>
<el-form-item label="发送时间" prop="sendType"> <el-form-item label="发送时间:" prop="sendType">
<el-radio-group v-model="basicForm.sendType"> <el-radio-group v-model="basicForm.sendType">
<el-radio :label="1">立即发送</el-radio> <el-radio :label="1">立即发送</el-radio>
<el-radio :label="2">定时发送</el-radio> <el-radio :label="2">定时发送</el-radio>
...@@ -432,8 +434,9 @@ export default { ...@@ -432,8 +434,9 @@ export default {
} }
.tips-text { .tips-text {
display: flex; display: flex;
align-items: center; // align-items: center;
justify-self: center; justify-self: center;
margin-left: 154px;
color: #000; color: #000;
font-size: 14px; font-size: 14px;
padding: 6px 16px; padding: 6px 16px;
...@@ -445,7 +448,7 @@ export default { ...@@ -445,7 +448,7 @@ export default {
.tips-icon { .tips-icon {
width: 14px; width: 14px;
height: 14px; height: 14px;
margin-right: 8px; margin: 6px 8px 0 0;
} }
} }
.info-box { .info-box {
...@@ -477,6 +480,7 @@ export default { ...@@ -477,6 +480,7 @@ export default {
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
color: #999; color: #999;
margin-left: 154px;
font-size: 14px; font-size: 14px;
.filter-number { .filter-number {
display: inline-block; display: inline-block;
...@@ -529,6 +533,7 @@ export default { ...@@ -529,6 +533,7 @@ export default {
.sale-select { .sale-select {
display: flex; display: flex;
align-items: center; align-items: center;
margin-left: 80px;
} }
.input-tag-wrapper { .input-tag-wrapper {
max-height: 75px; max-height: 75px;
...@@ -598,8 +603,11 @@ export default { ...@@ -598,8 +603,11 @@ export default {
.el-scrollbar { .el-scrollbar {
padding-bottom: 10px; padding-bottom: 10px;
} }
.welcome-box {
display: inline-block;
}
} }
.group-content { .group-content {
padding: 22px 0 20px 20px; padding: 22px 0 20px;
} }
</style> </style>
...@@ -307,7 +307,7 @@ export default { ...@@ -307,7 +307,7 @@ export default {
}, },
mounted() { mounted() {
this.getListData() this.handleRefresh()
this.getOptionsList('searchFormData') this.getOptionsList('searchFormData')
}, },
......
...@@ -17,10 +17,10 @@ ...@@ -17,10 +17,10 @@
</div> --> </div> -->
<div class="container edit-container"> <div class="container edit-container">
<p class="edit-title">{{ title }}</p> <p class="edit-title">{{ title }}</p>
<glsx-combi-form v-loading="loading" class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :labelWidth="labelWidth" defaultWidth="415px" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <glsx-combi-form v-loading="loading" class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :labelWidth="defaultLabelWidth" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<div slot="remarkName" class="edit-tips m-t-8">可根据备注名称进行查找,仅作内部查看,不展示给客户</div> <div slot="remarkName" class="edit-tips m-t-8">可根据备注名称进行查找,仅作内部查看,不展示给客户</div>
<el-button slot="selectGiftBtn" :disabled="routeInfo.receivedStock" class="default-blue-btn" @click="handleGiftAdd">选择礼包内容</el-button> <el-button slot="selectGiftBtn" :disabled="routeInfo.receivedStock" class="default-blue-btn" @click="handleGiftAdd">选择礼包内容</el-button>
<div slot="couponListBlock" class="gift-block" :style="{ 'margin-left': labelWidth }" v-show="editForm.couponList && editForm.couponList.length != 0"> <div slot="couponListBlock" class="gift-block" :style="{ 'margin-left': defaultLabelWidth }" v-show="editForm.couponList && editForm.couponList.length != 0">
<div class="gift-title"> <div class="gift-title">
预估成本: 预估成本:
<span class="price">{{ totalEstimatedCost }}</span> <span class="price">{{ totalEstimatedCost }}</span>
...@@ -52,17 +52,23 @@ ...@@ -52,17 +52,23 @@
<el-radio :disabled="routeInfo.receivedStock" v-model="editForm.approveFlag" :label="2">无需审批</el-radio> <el-radio :disabled="routeInfo.receivedStock" v-model="editForm.approveFlag" :label="2">无需审批</el-radio>
<p class="approval-tip">无需审批,可直接赠送给客户</p> <p class="approval-tip">无需审批,可直接赠送给客户</p>
</div> </div>
<div v-if="editForm.receiveRule === 1 || editForm.receiveRule === 4" class="telArea" slot="configSlot"> <div v-if="editForm.receiveRule === 1 || editForm.receiveRule === 4" class="telArea form-sub-block" slot="configSlot">
<label class="receiving" for="" v-show="editForm.receiveRule !== 4">领取条件:</label> <label class="receiving" :style="{ width: defaultLabelWidth }" for="" v-show="editForm.receiveRule !== 4">
<label class="receiving" for="" v-show="editForm.receiveRule === 4">用户手机号:</label> <span class="txt-red">*</span>
领取条件:
</label>
<label class="receiving" :style="{ width: defaultLabelWidth }" for="" v-show="editForm.receiveRule === 4">
<span class="txt-red">*</span>
用户手机号:
</label>
<el-radio-group v-if="editForm.receiveRule !== 4" @change="resetTextArea" v-model="receiveWay"> <el-radio-group v-if="editForm.receiveRule !== 4" @change="resetTextArea" v-model="receiveWay">
<el-radio :label="1">指定手机号</el-radio> <el-radio :label="1">指定手机号</el-radio>
<el-radio :label="2">指定车架号后6位</el-radio> <el-radio :label="2">指定车架号后6位</el-radio>
</el-radio-group> </el-radio-group>
<div style="margin-left:70px;width: calc(100% - 70px);"> <div :style="{ 'margin-left': defaultLabelWidth }">
<el-input :style="editForm.receiveRule === 4?'margin-top: -22px;margin-left: 8px;':''" @blur="formatPhone" type="textarea" v-model="phone" :placeholder="placeholder"></el-input> <el-input :style="editForm.receiveRule === 4?'margin-top: -22px;margin-left: 8px;':''" @blur="formatPhone" type="textarea" v-model="phone" :placeholder="placeholder"></el-input>
<span v-if="editForm.receiveRule !== 4" class="approval-tip" style="margin-left:0;">客户需准确输入该{{ receiveWay == 1 ? '手机号码' : '车架号后6位' }}才能成功领取</span> <p v-if="editForm.receiveRule !== 4" class="approval-tip">客户需准确输入该{{ receiveWay == 1 ? '手机号码' : '车架号后6位' }}才能成功领取</p>
<div :style="editForm.receiveRule === 4?'margin-left: 7px;':''"> <div :style="editForm.receiveRule === 4 ? 'margin-left: 7px;' : ''">
<div :class="['tel-item', !item.valid ? 'valid-tel': receiveWay == 1?'realTel':'realNum']" v-for="(item, index) in phoneList" :key="index"> <div :class="['tel-item', !item.valid ? 'valid-tel': receiveWay == 1?'realTel':'realNum']" v-for="(item, index) in phoneList" :key="index">
{{ item.tel }} {{ item.tel }}
<i style="cursor:pointer" class="el-icon-close" @click="delPhone(item.tel)"></i> <i style="cursor:pointer" class="el-icon-close" @click="delPhone(item.tel)"></i>
...@@ -72,27 +78,27 @@ ...@@ -72,27 +78,27 @@
</div> </div>
<span slot="bubble"> <span slot="bubble">
<el-popover placement="top-start" width="200" trigger="hover" content="创建礼包时指定好领取条件,客户需正确输入领取条件方可成功领取"> <el-popover placement="top-start" width="200" trigger="hover" content="创建礼包时指定好领取条件,客户需正确输入领取条件方可成功领取">
<i slot="reference" class="el-icon-question" style="color: #C6C6C6;"></i> <i slot="reference" class="el-icon-question" style="color: #C6C6C6;"></i>
</el-popover> </el-popover>
</span> </span>
<span slot="giveAway"> <span slot="giveAway">
<el-popover placement="top-start" width="200" trigger="hover" content="员工在每次发送礼包给客户之前,需设置好领取条件,客户需正确输入领取条件方可成功领取"> <el-popover placement="top-start" width="200" trigger="hover" content="员工在每次发送礼包给客户之前,需设置好领取条件,客户需正确输入领取条件方可成功领取">
<i slot="reference" class="el-icon-question" style="color: #C6C6C6;"></i> <i slot="reference" class="el-icon-question" style="color: #C6C6C6;"></i>
</el-popover> </el-popover>
</span> </span>
<span slot="receives"> <span slot="receives">
<el-popover placement="top-start" width="200" trigger="hover" content="客户无需输入任何领取条件,即可直接领取礼包"> <el-popover placement="top-start" width="200" trigger="hover" content="客户无需输入任何领取条件,即可直接领取礼包">
<i slot="reference" class="el-icon-question" style="color: #C6C6C6;"></i> <i slot="reference" class="el-icon-question" style="color: #C6C6C6;"></i>
</el-popover> </el-popover>
</span> </span>
<span slot="cardHolder"> <span slot="cardHolder">
<el-popover placement="top-start" width="200" trigger="hover" content="将根据手机号直接发送至小程序客户的卡包当中,客户无需领取"> <el-popover placement="top-start" width="200" trigger="hover" content="将根据手机号直接发送至小程序客户的卡包当中,客户无需领取">
<i slot="reference" class="el-icon-question" style="color: #C6C6C6;"></i> <i slot="reference" class="el-icon-question" style="color: #C6C6C6;"></i>
</el-popover> </el-popover>
</span> </span>
<!-- <div slot="receiveDetails" class="edit-tips m-t-8">客户需要输入该{{ editForm.receiveWay == '1' ? '手机号' : '车架号后6位' }}才能成功领取</div> --> <!-- <div slot="receiveDetails" class="edit-tips m-t-8">客户需要输入该{{ editForm.receiveWay == '1' ? '手机号' : '车架号后6位' }}才能成功领取</div> -->
<el-button slot="selectStaffBtn" :disabled="routeInfo.receivedStock" class="el-icon-plus" @click="handleSelectStaff">选择员工</el-button> <el-button slot="selectStaffBtn" :disabled="routeInfo.receivedStock" class="el-icon-plus" @click="handleSelectStaff">选择员工</el-button>
<div slot="staffListBlock" class="sale-select" :style="{ 'margin-left': labelWidth }" v-show="editForm.staffList && editForm.staffList.length != 0 && editForm.receiveRule !== 4"> <div slot="staffListBlock" class="sale-select" :style="{ 'margin-left': defaultLabelWidth }" v-show="editForm.staffList && editForm.staffList.length != 0 && editForm.receiveRule !== 4">
<div :key="key" class="el-input-tag input-tag-wrapper"> <div :key="key" class="el-input-tag input-tag-wrapper">
<el-tag effect="plain" type="info" v-for="(tag, idx) in editForm.staffList" :key="idx" :closable="!routeInfo.receivedStock" :disable-transitions="false" @close="handleStaffRemove(tag, idx)"> <el-tag effect="plain" type="info" v-for="(tag, idx) in editForm.staffList" :key="idx" :closable="!routeInfo.receivedStock" :disable-transitions="false" @close="handleStaffRemove(tag, idx)">
<i class="el-icon-user-solid"></i> <i class="el-icon-user-solid"></i>
...@@ -115,10 +121,14 @@ ...@@ -115,10 +121,14 @@
</div> </div>
</div> </div>
</div> </div>
<div class="footer" :style="{ left: footerLeft + 'px', width: footerWidth + 'px' }"> <!-- <div class="footer" :style="{ left: footerLeft + 'px', width: footerWidth + 'px' }">
<el-button type="default" @click="handleCancel">取消</el-button> <el-button type="default" @click="handleCancel">取消</el-button>
<el-button type="primary" @click="handleConfirm">提交</el-button> <el-button type="primary" @click="handleConfirm">提交</el-button>
</div> </div> -->
<GLFooter>
<el-button @click="handleCancel" size="medium">取消</el-button>
<el-button type="primary" @click="handleConfirm" size="medium" :loading="loading">提交</el-button>
</GLFooter>
<select-gift-dialog v-if="isSelectGiftVisible" :isSelectGiftVisible="isSelectGiftVisible" :selectedGiftList="selectedGiftList" @handleGiftConfirm="handleGiftConfirm" @handleGiftClose="handleGiftClose"></select-gift-dialog> <select-gift-dialog v-if="isSelectGiftVisible" :isSelectGiftVisible="isSelectGiftVisible" :selectedGiftList="selectedGiftList" @handleGiftConfirm="handleGiftConfirm" @handleGiftClose="handleGiftClose"></select-gift-dialog>
<select-staff-dialog v-if="isMutiSelectVisible" :isMutiSelectVisible="isMutiSelectVisible" :searchForm="searchStaffForm" :selectedStaffList="selectedStaffList" @handleMutiSelectConfirm="handleMutiSelectConfirm" @handleMutiSelectClose="handleMutiSelectClose"></select-staff-dialog> <select-staff-dialog v-if="isMutiSelectVisible" :isMutiSelectVisible="isMutiSelectVisible" :searchForm="searchStaffForm" :selectedStaffList="selectedStaffList" @handleMutiSelectConfirm="handleMutiSelectConfirm" @handleMutiSelectClose="handleMutiSelectClose"></select-staff-dialog>
</div> </div>
...@@ -133,7 +143,7 @@ export default { ...@@ -133,7 +143,7 @@ export default {
return { return {
phone: '', phone: '',
isLoaded: true, isLoaded: true,
loading:false, loading: false,
phoneList: [], phoneList: [],
size: 'small', size: 'small',
title: '新增礼包', title: '新增礼包',
...@@ -141,8 +151,6 @@ export default { ...@@ -141,8 +151,6 @@ export default {
add: '新增礼包', add: '新增礼包',
edit: '编辑礼包' edit: '编辑礼包'
}, },
footerLeft: '0',
footerWidth: '0',
// 选择员工弹窗 // 选择员工弹窗
isMutiSelectVisible: false, isMutiSelectVisible: false,
searchStaffForm: {}, searchStaffForm: {},
...@@ -157,7 +165,6 @@ export default { ...@@ -157,7 +165,6 @@ export default {
id: '' id: ''
}, },
editStatus: false, editStatus: false,
labelWidth: '144px',
receiveWay: 1, receiveWay: 1,
curStock: 0, curStock: 0,
curReceiveRule: 0, curReceiveRule: 0,
...@@ -322,7 +329,7 @@ export default { ...@@ -322,7 +329,7 @@ export default {
], ],
suffixSlot: 'configSlot', suffixSlot: 'configSlot',
handleRadioChange: (e) => { handleRadioChange: (e) => {
if(e==4){ if (e == 4) {
this.receiveWay = 1 this.receiveWay = 1
} }
this.resetTextArea() this.resetTextArea()
...@@ -412,16 +419,16 @@ export default { ...@@ -412,16 +419,16 @@ export default {
} }
}, },
'editForm.receiveRule'(newValue) { 'editForm.receiveRule'(newValue) {
let idx = this.editFormData.findIndex(item => item.name == 'staffList') let idx = this.editFormData.findIndex(item => item.name == 'staffList')
let idxx = this.editFormData.findIndex(item => item.name == 'approveFlag') let idxx = this.editFormData.findIndex(item => item.name == 'approveFlag')
let idxxx = this.editFormData.findIndex(item => item.name == 'stock') let idxxx = this.editFormData.findIndex(item => item.name == 'stock')
this.editFormData[idx].isHide = newValue == 4 this.editFormData[idx].isHide = newValue == 4
this.editFormData[idxx].isHide = newValue == 4 this.editFormData[idxx].isHide = newValue == 4
this.editFormData[idxxx].isHide = newValue == 4 this.editFormData[idxxx].isHide = newValue == 4
if(newValue == 4) { if (newValue == 4) {
this.editForm.staffList = [] this.editForm.staffList = []
this.editForm.stock = 1 this.editForm.stock = 1
} }
}, },
}, },
computed: { computed: {
...@@ -430,8 +437,7 @@ export default { ...@@ -430,8 +437,7 @@ export default {
} }
}, },
mounted() { mounted() {
this.footerLeft = document.querySelector('.base-container-right').offsetLeft this.setMinHeight()
this.footerWidth = document.documentElement.clientWidth - this.footerLeft
this.routeInfo = this.$route.query this.routeInfo = this.$route.query
if (this.routeInfo.receivedStock) this.routeInfo.receivedStock = +this.routeInfo.receivedStock if (this.routeInfo.receivedStock) this.routeInfo.receivedStock = +this.routeInfo.receivedStock
this.title = this.titleObj[this.routeInfo.addOrEdit] this.title = this.titleObj[this.routeInfo.addOrEdit]
...@@ -458,7 +464,7 @@ export default { ...@@ -458,7 +464,7 @@ export default {
delPhone(val) { delPhone(val) {
let phone = '\n' + this.phone + '\n' let phone = '\n' + this.phone + '\n'
phone = phone.replace(/[\n]/g, '\n\n') phone = phone.replace(/[\n]/g, '\n\n')
phone = phone.replace(new RegExp('[\n]'+ val + '[\n]', 'g'), '\n') phone = phone.replace(new RegExp('[\n]' + val + '[\n]', 'g'), '\n')
phone = phone.replace(/[\n]+/g, '\n') phone = phone.replace(/[\n]+/g, '\n')
phone = phone.replace(/^[\n]+/, '') phone = phone.replace(/^[\n]+/, '')
this.phone = phone this.phone = phone
...@@ -638,7 +644,7 @@ export default { ...@@ -638,7 +644,7 @@ export default {
if (this.editForm.receiveRule == 1 || this.editForm.receiveRule == 4) { if (this.editForm.receiveRule == 1 || this.editForm.receiveRule == 4) {
params.receiveDetailList = this.phoneList.map(item => item.tel) params.receiveDetailList = this.phoneList.map(item => item.tel)
let maxLength = 500 let maxLength = 500
if(params.receiveDetailList && params.receiveDetailList.length > maxLength){ if (params.receiveDetailList && params.receiveDetailList.length > maxLength) {
return this.$message.error(`领取${this.receiveWay == 1 ? '手机号' : '车架号'}不能超过${maxLength}个`) return this.$message.error(`领取${this.receiveWay == 1 ? '手机号' : '车架号'}不能超过${maxLength}个`)
} }
params.receiveWay = this.receiveWay params.receiveWay = this.receiveWay
...@@ -656,11 +662,11 @@ export default { ...@@ -656,11 +662,11 @@ export default {
params.requestSource = 1 params.requestSource = 1
// 插入判断是否存在审批模板 // 插入判断是否存在审批模板
// const { session } = this.$globalState // const { session } = this.$globalState
if(this.editForm.receiveRule == 1 || this.editForm.receiveRule == 4){ if (this.editForm.receiveRule == 1 || this.editForm.receiveRule == 4) {
if(!((this.editForm.receiveRule == 1 || this.editForm.receiveRule == 4) && params.receiveDetailList && params.receiveDetailList.length)) { if (!((this.editForm.receiveRule == 1 || this.editForm.receiveRule == 4) && params.receiveDetailList && params.receiveDetailList.length)) {
return this.$message.error(`${this.editForm.receiveRule == 1 ? '领取条件不能为空!':'用户手机号不能为空!'}`) return this.$message.error(`${this.editForm.receiveRule == 1 ? '领取条件不能为空!' : '用户手机号不能为空!'}`)
} }
} }
this.insertHttp(params) this.insertHttp(params)
// this.$apis.giftBag.templateModal({ merchantId: session.merchantId }).then(result => { // this.$apis.giftBag.templateModal({ merchantId: session.merchantId }).then(result => {
// if (result.data && (!this.isChangeCoupons || !this.isChangePeople)) { // if (result.data && (!this.isChangeCoupons || !this.isChangePeople)) {
...@@ -689,7 +695,7 @@ export default { ...@@ -689,7 +695,7 @@ export default {
text: '正在Loading···', text: '正在Loading···',
spinner: 'el-icon-loading', spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.5)', background: 'rgba(0, 0, 0, 0.5)',
customClass:'loadingClass' customClass: 'loadingClass'
}) })
this.$apis.giftBag this.$apis.giftBag
.insertGiftApi(params) .insertGiftApi(params)
...@@ -722,7 +728,7 @@ export default { ...@@ -722,7 +728,7 @@ export default {
.then(() => { .then(() => {
this.cancelJump() this.cancelJump()
}) })
.catch(() => {}) .catch(() => { })
} else { } else {
this.cancelJump() this.cancelJump()
} }
...@@ -768,21 +774,23 @@ export default { ...@@ -768,21 +774,23 @@ export default {
font-weight: 400; font-weight: 400;
color: #999999; color: #999999;
line-height: 12px; line-height: 12px;
margin-left: 24px; margin-top: 10px;
} }
.telArea { .telArea {
width: 713px; // width: 713px;
background: #f9f9f9; // background: #f9f9f9;
padding: 10px 20px; // padding: 10px 20px;
.receiving { .receiving {
display: inline-block;
color: #666; color: #666;
width: 70px; // width: 70px;
position: relative; position: relative;
&::before { text-align: right;
content: '*'; .txt-red {
// content: '*';
color: #f56c6c; color: #f56c6c;
left: -10px; // left: -10px;
position: absolute; // position: absolute;
} }
} }
.el-textarea__inner { .el-textarea__inner {
...@@ -807,10 +815,10 @@ export default { ...@@ -807,10 +815,10 @@ export default {
border: 1px solid #ffa39e; border: 1px solid #ffa39e;
color: #ff4d4f; color: #ff4d4f;
} }
.realTel{ .realTel {
width: 130px; width: 130px;
} }
.realNum{ .realNum {
width: 90px; width: 90px;
} }
} }
......
...@@ -41,15 +41,13 @@ ...@@ -41,15 +41,13 @@
</GLTable> </GLTable>
<!-- 表格区域 end --> <!-- 表格区域 end -->
</div> </div>
<GLDialog title="作废确认" mode="small" :visible.sync="isCancelVisible" @onOk="handleCancelConfirm" @onCancel="handleCancelClose"> <GLDialog title="作废确认" mode="mid" :visible.sync="isCancelVisible" @onOk="handleCancelConfirm" @onCancel="handleCancelClose">
<div class="small-content"> <p class="m-t-20" style="padding-left: 76px;">请先和客户沟通再确认,避免引起客诉,作废后客户将不可使用该礼包下所有优惠卷</p>
<p>请先和客户沟通再确认,避免引起客诉,作废后客户将不可使用该礼包下所有优惠卷</p> <el-form ref="cancelRef" label-width="154px" :rules="cancelRules" :model="cancelForm">
<el-form ref="cancelRef" label-width="80px" :rules="cancelRules" :model="cancelForm"> <el-form-item label="作废原因" prop="cancelReason" class="m-t-20">
<el-form-item label="作废原因" prop="cancelReason" class="m-t-20"> <el-input style="width: 432px;" :size="size" type="textarea" v-model="cancelForm.cancelReason" placeholder="请输入作废原因" maxlength="50" rows="3" show-word-limit></el-input>
<el-input style="width: 410px;" :size="size" type="textarea" v-model="cancelForm.cancelReason" placeholder="请输入作废原因" maxlength="50" rows="3" show-word-limit></el-input> </el-form-item>
</el-form-item> </el-form>
</el-form>
</div>
</GLDialog> </GLDialog>
</div> </div>
</template> </template>
......
...@@ -342,13 +342,14 @@ export default { ...@@ -342,13 +342,14 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
.welcome-box { .welcome-box {
display: inline-block !important;
// padding-top: 20px; // padding-top: 20px;
// margin-left: 87px; // margin-left: 87px;
} }
.content { .content {
display: inline-block; display: inline-block;
vertical-align: text-top; vertical-align: text-top;
width: calc(100% - 103px); width: calc(100% - 103px) !important;
// margin-left: 12px; // margin-left: 12px;
.content-bg { .content-bg {
background-color: #f7f7f7; background-color: #f7f7f7;
......
...@@ -18,8 +18,7 @@ ...@@ -18,8 +18,7 @@
</div> </div>
<div class="marketing-content">{{ item.content }}</div> <div class="marketing-content">{{ item.content }}</div>
<div class="marketing-btn"> <div class="marketing-btn">
<GLButton style="width: 118px;" display="disabled" type="primary" :size="size" :fn="item.linkName" <GLButton style="width: 118px;" display="disabled" type="primary" :size="size" :fn="item.linkName" @click="jumpPage(item.path)">{{ item.linkName }}</GLButton>
@click="jumpPage(item.path)">{{ item.linkName }}</GLButton>
<!-- <el-button <!-- <el-button
style="width: 118px;" style="width: 118px;"
:disabled="!$globalState.routers.find(i => i.compath == item.path)" :disabled="!$globalState.routers.find(i => i.compath == item.path)"
...@@ -156,16 +155,14 @@ ...@@ -156,16 +155,14 @@
<div class="data-item" style="margin-top: 10px;"> <div class="data-item" style="margin-top: 10px;">
<div class="data-half" style="margin-right: 20px;"> <div class="data-half" style="margin-right: 20px;">
<span class="data-half-name">周同比</span> <span class="data-half-name">周同比</span>
<span <span :class="[equity.weekFlag ? 'data-red-percentage data-half-red' : 'data-green-percentage data-half-green']">
:class="[equity.weekFlag ? 'data-red-percentage data-half-red' : 'data-green-percentage data-half-green']">
<span :class="[equity.weekFlag ? 'data-red-triangle' : 'data-green-triangle']"></span> <span :class="[equity.weekFlag ? 'data-red-triangle' : 'data-green-triangle']"></span>
<span>{{ equity.lastWeekDayMemberShipCompared ? equity.lastWeekDayMemberShipCompared : '--' }}</span> <span>{{ equity.lastWeekDayMemberShipCompared ? equity.lastWeekDayMemberShipCompared : '--' }}</span>
</span> </span>
</div> </div>
<div class="data-half"> <div class="data-half">
<span class="data-half-name">日环比</span> <span class="data-half-name">日环比</span>
<span <span :class="[equity.dayFlag ? 'data-red-percentage data-half-red' : 'data-green-percentage data-half-green']">
:class="[equity.dayFlag ? 'data-red-percentage data-half-red' : 'data-green-percentage data-half-green']">
<span :class="[equity.dayFlag ? 'data-red-triangle' : 'data-green-triangle']"></span> <span :class="[equity.dayFlag ? 'data-red-triangle' : 'data-green-triangle']"></span>
<span>{{ equity.yesterdayMembershipSequential ? equity.yesterdayMembershipSequential : '--' }}</span> <span>{{ equity.yesterdayMembershipSequential ? equity.yesterdayMembershipSequential : '--' }}</span>
</span> </span>
...@@ -189,8 +186,7 @@ ...@@ -189,8 +186,7 @@
<div class="data-item"> <div class="data-item">
<span class="data-title w-118">累计产值</span> <span class="data-title w-118">累计产值</span>
<span class="date-content"> <span class="date-content">
<span class="data-num orange">{{ equity.totalProductionValue ? equity.totalProductionValue : '--' <span class="data-num orange">{{ equity.totalProductionValue ? equity.totalProductionValue : '--' }}</span>
}}</span>
元 元
</span> </span>
</div> </div>
...@@ -200,19 +196,15 @@ ...@@ -200,19 +196,15 @@
</div> </div>
</div> </div>
<div class="border home-bottom"> <div class="border home-bottom">
<div class="title bottom-title"> <div class="bottom-title">
<div class="bottom-text">店铺数据</div> <div class="bottom-text">微店数据</div>
<div class="bottom-time"> <div class="bottom-time">
<div class="bottom-btn"> <div class="bottom-btn">
<el-button :style="currentTime == 'week' ? '' : blackColor" type="text" @click="storeData('week')">本周 <el-button :style="currentTime == 'week' ? '' : blackColor" type="text" @click="storeData('week')">本周</el-button>
</el-button> <el-button :style="currentTime == 'month' ? '' : blackColor" type="text" @click="storeData('month')">本月</el-button>
<el-button :style="currentTime == 'month' ? '' : blackColor" type="text" @click="storeData('month')">本月 <el-button :style="currentTime == 'year' ? '' : blackColor" type="text" @click="storeData('year')">全年</el-button>
</el-button>
<el-button :style="currentTime == 'year' ? '' : blackColor" type="text" @click="storeData('year')">全年
</el-button>
</div> </div>
<el-date-picker class="bottom-picker" v-model="date" type="daterange" size="small" range-separator="至" <el-date-picker class="bottom-picker" v-model="date" type="daterange" size="small" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" @change="dateChange"></el-date-picker>
start-placeholder="开始日期" end-placeholder="结束日期" @change="dateChange"></el-date-picker>
</div> </div>
</div> </div>
<div class="bottom-content"> <div class="bottom-content">
...@@ -221,37 +213,39 @@ ...@@ -221,37 +213,39 @@
<div v-show="!order.list" class="no-data">暂无数据</div> <div v-show="!order.list" class="no-data">暂无数据</div>
</div> </div>
<div class="bottom-right"> <div class="bottom-right">
<div class="bottom-right-item"> <div class="bottom-right-boxs">
<div class="item-content"> <div class="bottom-right-item">
<img src="@/assets/icon-amount.png" alt /> <div class="item-content">
<div> <img src="@/assets/icon-amount.png" alt />
<div>成交金额</div> <div>
<div class="item-number"> <div>成交金额</div>
{{ order.totalAmount ? order.totalAmount : '--' }} <div class="item-number">
<span>元</span> {{ order.totalAmount ? order.totalAmount : '--' }}
<span>元</span>
</div>
</div> </div>
</div> </div>
</div> <!-- <div class="item-chain">
<!-- <div class="item-chain">
<span>同比上月</span> <span>同比上月</span>
<span class="green-num">0.3%</span> <span class="green-num">0.3%</span>
</div>--> </div>-->
</div> </div>
<div class="bottom-right-item"> <div class="bottom-right-item">
<div class="item-content"> <div class="item-content">
<img src="@/assets/icon-order.png" alt /> <img src="@/assets/icon-order.png" alt />
<div> <div>
<div>订单总数</div> <div>订单总数</div>
<div class="item-number"> <div class="item-number">
{{ order.totalCount ? order.totalCount : '--' }} {{ order.totalCount ? order.totalCount : '--' }}
<span>单</span> <span>单</span>
</div>
</div> </div>
</div> </div>
</div> <!-- <div class="item-chain">
<!-- <div class="item-chain">
<span>同比上月</span> <span>同比上月</span>
<span class="red-num">0.3%</span> <span class="red-num">0.3%</span>
</div>--> </div>-->
</div>
</div> </div>
</div> </div>
</div> </div>
...@@ -700,9 +694,18 @@ export default { ...@@ -700,9 +694,18 @@ export default {
margin-top: 20px; margin-top: 20px;
.bottom { .bottom {
&-title { // &-title {
display: flex; // display: flex;
justify-content: space-between; // justify-content: space-between;
// }
&-text {
font-size: 20px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #333333;
line-height: 20px;
margin-bottom: 20px;
} }
&-btn { &-btn {
...@@ -710,6 +713,7 @@ export default { ...@@ -710,6 +713,7 @@ export default {
} }
&-time { &-time {
margin-left: 36px;
width: 31.5%; width: 31.5%;
} }
...@@ -722,20 +726,28 @@ export default { ...@@ -722,20 +726,28 @@ export default {
&-content { &-content {
display: flex; display: flex;
justify-content: space-between;
} }
&-right { &-right {
margin-top: 10px;
min-width: 240px; min-width: 240px;
width: 270px;
height: 210px;
background: #f9f9fc;
border-radius: 3px;
&-boxs {
margin: 24px 24px 31px 24px;
}
&-item { &-item {
font-size: 16px; font-size: 16px;
color: #333; color: #333;
margin-bottom: 21px;
&:first-child {
border-bottom: 1px solid #e5e5e5;
padding-bottom: 31px;
}
&:last-child { &:last-child {
margin-top: 50px; padding-top: 24px;
margin-bottom: 0;
} }
.item-content { .item-content {
......
...@@ -5,8 +5,8 @@ ...@@ -5,8 +5,8 @@
<div class="home-set-form flex-grow"> <div class="home-set-form flex-grow">
<div v-for="(item, index) in externalFormList" :key="index"> <div v-for="(item, index) in externalFormList" :key="index">
<p class="edit-title">{{ item.title }}</p> <p class="edit-title">{{ item.title }}</p>
<glsx-combi-form class="edit-form-container m-b-60" ref="editFormRef" :isEdit="isEdit" :labelWidth="labelWidth" defaultWidth="320px" :isBlock="true" :formRef="item.editChildRef" :formObj="editForm" :formData="item.editFormData" :formRules="item.editRule"> <glsx-combi-form class="edit-form-container m-b-60" ref="editFormRef" :isEdit="isEdit" :labelWidth="defaultLabelWidth" :isBlock="true" :formRef="item.editChildRef" :formObj="editForm" :formData="item.editFormData" :formRules="item.editRule">
<div slot="merchantQrcode" slot-scope="scope" :style="{ 'margin-left': labelWidth, width: '120px', 'text-align': 'center' }"> <div slot="merchantQrcode" slot-scope="scope" :style="{ 'margin-left': defaultLabelWidth, width: '120px', 'text-align': 'center' }">
<p> <p>
<img class="img-120" :src="editForm[scope.scope.name]" /> <img class="img-120" :src="editForm[scope.scope.name]" />
</p> </p>
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
<template slot="bannerBtn"> <template slot="bannerBtn">
<el-button type="primary" :size="size" @click="handleBannerAdd">新增banner</el-button> <el-button type="primary" :size="size" @click="handleBannerAdd">新增banner</el-button>
</template> </template>
<div :style="{ 'margin-left': labelWidth }" slot="bannerList" slot-scope="scope"> <div :style="{ 'margin-left': defaultLabelWidth }" slot="bannerList" slot-scope="scope">
<div v-for="(subItem, subIndex) in editForm[scope.scope.name]" :key="subIndex" class="flex"> <div v-for="(subItem, subIndex) in editForm[scope.scope.name]" :key="subIndex" class="flex">
<!-- 上传图片 --> <!-- 上传图片 -->
<div class="banner-upload-box"> <div class="banner-upload-box">
...@@ -136,20 +136,17 @@ ...@@ -136,20 +136,17 @@
<el-checkbox v-for="(item, index) in baseData.clueList" :label="item.confId" :key="index">{{ item.confName }}</el-checkbox> <el-checkbox v-for="(item, index) in baseData.clueList" :label="item.confId" :key="index">{{ item.confName }}</el-checkbox>
</el-checkbox-group> </el-checkbox-group>
</div> </div>
<!-- <div slot="serviceTable" :style="{ 'margin-left': labelWidth, width: `calc(100% - ${labelWidth} )` }"> <div class="approval" slot="customerServerUserId" :key="freshFlag">
<GLTable v-show="editForm.customerServerUserId" :hasPage="false" :tableParams="tableParams" :tableData="customerServerList"></GLTable>
</div> -->
<div class="approval" slot="customerServerUserId">
<el-radio v-model="editForm.customerServerType" :label="1"> <el-radio v-model="editForm.customerServerType" :label="1">
<el-select style="width: 320px" v-model="editForm.customerServerUserId" :disabled="editForm.customerServerType == 2" :clearable="true" :placeholder="'请选择在线客服'" :no-data-text="'无数据'" @change="selectAddAttr"> <el-select style="width: 432px" v-model="editForm.customerServerUserId" :disabled="editForm.customerServerType == 2" :clearable="true" :placeholder="'请选择在线客服'" :no-data-text="'无数据'" @clear="selectAddAttr" @change="selectAddAttr">
<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> <el-button v-show="!baseData.consultantList.length" type="text"></el-button>
<p style="color: #5850ff;margin-left: 22px;" @click="handleNoServer">请在首页-跟进专员模块里添加类型为“在线客服”的跟进专员</p> <p style="color: #5850ff;margin-left: 22px;" @click="handleNoServer">请在首页-跟进专员模块里添加类型为“在线客服”的跟进专员</p>
<el-radio v-model="editForm.customerServerType" :label="2"> <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 style="width: 320px" placeholder="请输入链接" :disabled="editForm.customerServerType == 1" v-model="editForm.customerServerUrl" clearable></el-input> <el-input placeholder="请输入链接" :disabled="editForm.customerServerType == 1" v-model="editForm.customerServerUrl" clearable @change="handleServerUrlChange"></el-input>
</el-radio> </el-radio>
</div> </div>
</glsx-combi-form> </glsx-combi-form>
...@@ -233,6 +230,7 @@ export default { ...@@ -233,6 +230,7 @@ export default {
// 查看大图 // 查看大图
isImgVisible: false, isImgVisible: false,
state: '', state: '',
freshFlag: new Date(),
dialogObj: { dialogObj: {
url: '', url: '',
uploadType: 'img' uploadType: 'img'
...@@ -300,7 +298,7 @@ export default { ...@@ -300,7 +298,7 @@ export default {
noticeToSubMerchant: 'N', noticeToSubMerchant: 'N',
bannerMerchantList: [], bannerMerchantList: [],
noticeMerchantList: [], noticeMerchantList: [],
customerServerType: 1, customerServerType: '',
customerServerUrl: '' customerServerUrl: ''
}, },
bannerItem: { bannerItem: {
...@@ -322,7 +320,6 @@ export default { ...@@ -322,7 +320,6 @@ export default {
{ confId: '2', confName: '图文介绍' }, { confId: '2', confName: '图文介绍' },
{ confId: '3', confName: '视频介绍' } { confId: '3', confName: '视频介绍' }
], ],
labelWidth: '144px',
isEdit: true, isEdit: true,
externalFormList: [ externalFormList: [
{ {
...@@ -457,6 +454,10 @@ export default { ...@@ -457,6 +454,10 @@ export default {
}, },
methods: { methods: {
handleServerUrlChange(value) {
this.editForm.customerServerType = value ? 2 : ''
this.freshFlag = new Date()
},
selectAddAttr(value) { selectAddAttr(value) {
var tempObj = { var tempObj = {
customerServerName: '', customerServerName: '',
...@@ -467,6 +468,7 @@ export default { ...@@ -467,6 +468,7 @@ export default {
this.editForm.customerServerName = '' this.editForm.customerServerName = ''
this.editForm.customerServerUserTitle = '' this.editForm.customerServerUserTitle = ''
if (value) { if (value) {
this.editForm.customerServerType = 1
tempObj = this.baseData.consultantList.find(item => item.userOneid == value) tempObj = this.baseData.consultantList.find(item => item.userOneid == value)
this.editForm.customerServerId = tempObj.id this.editForm.customerServerId = tempObj.id
this.editForm.customerServerName = tempObj.staffName this.editForm.customerServerName = tempObj.staffName
...@@ -475,7 +477,10 @@ export default { ...@@ -475,7 +477,10 @@ export default {
customerServerName: tempObj.staffName, customerServerName: tempObj.staffName,
customerServerUserTitle: tempObj.staffTitle customerServerUserTitle: tempObj.staffTitle
}) })
return true
} }
this.editForm.customerServerType = ''
this.freshFlag = new Date()
}, },
getInfo() { getInfo() {
this.$apis.homeSet.getHomeInfoListApi({}).then(res => { this.$apis.homeSet.getHomeInfoListApi({}).then(res => {
...@@ -486,7 +491,7 @@ export default { ...@@ -486,7 +491,7 @@ export default {
this.editForm.clueList = res.clueList.map(k => k.clueId) this.editForm.clueList = res.clueList.map(k => k.clueId)
this.editForm.preferentialPolicy = res.preferentialPolicy this.editForm.preferentialPolicy = res.preferentialPolicy
this.editForm.customerServerUserId = '' this.editForm.customerServerUserId = ''
this.editForm.customerServerType = +res.customerServerType || 1 this.editForm.customerServerType = +res.customerServerType
this.editForm.customerServerUrl = res.customerServerUrl this.editForm.customerServerUrl = res.customerServerUrl
this.editForm.bannerToSubMerchant = res.bannerToSubMerchant || 'N' this.editForm.bannerToSubMerchant = res.bannerToSubMerchant || 'N'
this.editForm.noticeToSubMerchant = res.noticeToSubMerchant || 'N' this.editForm.noticeToSubMerchant = res.noticeToSubMerchant || 'N'
...@@ -503,7 +508,7 @@ export default { ...@@ -503,7 +508,7 @@ export default {
}) })
} }
if (res.bannerList && res.bannerList.length) { if (res.bannerList && res.bannerList.length) {
res.bannerList.forEach((item,inx) => { res.bannerList.forEach((item, inx) => {
var params = { var params = {
bannerImg: item.bannerImg, bannerImg: item.bannerImg,
goodsId: item.goods ? item.goods.id : '', goodsId: item.goods ? item.goods.id : '',
...@@ -821,7 +826,15 @@ export default { ...@@ -821,7 +826,15 @@ export default {
return { clueId: k } return { clueId: k }
}) })
: [] : []
console.log(params) // 在线客服
switch (this.editForm.customerServerType) {
case 1:
!this.editForm.customerServerUserId && (params.customerServerType = '')
break
case 2:
!this.editForm.customerServerUrl && (params.customerServerType = '')
break
}
this.$apis.homeSet.updateHomeApi(params).then(res => { this.$apis.homeSet.updateHomeApi(params).then(res => {
this.$message({ this.$message({
message: res.code == '0' ? '操作成功' : res.message, message: res.code == '0' ? '操作成功' : res.message,
......
<template> <template>
<div class="container"> <div class="container marketing">
<el-form ref="materialAddForm" :model="materialAddForm" label-width="146px" :rules="materialAddFormRules"> <el-form ref="materialAddForm" :model="materialAddForm" :label-width="defaultLabelWidth" :rules="materialAddFormRules">
<div class="creat-material"> <div class="creat-material">
<h4>{{ title }}</h4> <h4>{{ title }}</h4>
<el-divider></el-divider> <el-divider></el-divider>
<div class="form-item-container"> <div class="m-l-20">
<el-form-item v-if="routeInfo.addOrEdit == 1" label="选择素材组:" prop="groupId"> <el-form-item v-if="routeInfo.addOrEdit == 1" label="选择素材组:" prop="groupId">
<el-select v-model="materialAddForm.groupId" placeholder="全部" :size="size"> <el-select v-model="materialAddForm.groupId" placeholder="全部" :size="size">
<el-option v-for="item in groupCounter" :key="item.id" :label="item.materialGroupName" :value="item.id"></el-option> <el-option v-for="item in groupCounter" :key="item.id" :label="item.materialGroupName" :value="item.id"></el-option>
</el-select> </el-select>
...@@ -15,10 +15,10 @@ ...@@ -15,10 +15,10 @@
<el-option v-for="item in groupCounter" :key="item.id" :label="item.materialGroupName" :value="item.id"></el-option> <el-option v-for="item in groupCounter" :key="item.id" :label="item.materialGroupName" :value="item.id"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="素材名称:" prop="materialName"> <el-form-item label="素材名称:" prop="materialName">
<el-input v-model="materialAddForm.materialName" :size="size" placeholder="请输入素材名称" maxlength="30"></el-input> <el-input v-model="materialAddForm.materialName" :size="size" placeholder="请输入素材名称" maxlength="30"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="素材类型:" prop="materialType"> <el-form-item label="素材类型:" prop="materialType">
<el-radio-group v-model="materialAddForm.materialType" @change="radioChange" :disabled="routeInfo.addOrEdit == 2 && routeInfo.status != 1"> <el-radio-group v-model="materialAddForm.materialType" @change="radioChange" :disabled="routeInfo.addOrEdit == 2 && routeInfo.status != 1">
<el-radio :label="1">PDF文件</el-radio> <el-radio :label="1">PDF文件</el-radio>
<!-- <el-radio :label="2">自定义链接</el-radio> --> <!-- <el-radio :label="2">自定义链接</el-radio> -->
...@@ -40,12 +40,12 @@ ...@@ -40,12 +40,12 @@
</div> </div>
<!-- 选择自定义链接 --> <!-- 选择自定义链接 -->
<!-- <div v-show="materialAddForm.materialType == 2"> <!-- <div v-show="materialAddForm.materialType == 2">
<el-form :model="linkForm" :rules="linkRules" ref="linkForm" label-width="100px"> <el-form :model="linkForm" :rules="linkRules" ref="linkForm" label-width="100px">
<el-form-item label="链接地址" prop="link"> <el-form-item label="链接地址" prop="link">
<el-input v-model="linkForm.link" placeholder="请填写跳转链接" maxlength="150" show-word-limit></el-input> <el-input v-model="linkForm.link" placeholder="请填写跳转链接" maxlength="150" show-word-limit></el-input>
</el-form-item> </el-form-item>
</el-form> </el-form>
</div> --> </div> -->
<!-- 选择图文 --> <!-- 选择图文 -->
<div v-show="materialAddForm.materialType == 3"> <div v-show="materialAddForm.materialType == 3">
<textBox @change="writeChange" ref="textBox" @forbid="forbidEdit"></textBox> <textBox @change="writeChange" ref="textBox" @forbid="forbidEdit"></textBox>
...@@ -57,7 +57,7 @@ ...@@ -57,7 +57,7 @@
<div class="track"> <div class="track">
<h4>追踪设置</h4> <h4>追踪设置</h4>
<el-divider></el-divider> <el-divider></el-divider>
<div form-item-container> <div form-item-container class="m-l-20">
<el-form-item prop="businessType"> <el-form-item prop="businessType">
<span slot="label"> <span slot="label">
<span class="label-word"> <span class="label-word">
...@@ -65,7 +65,7 @@ ...@@ -65,7 +65,7 @@
<el-popover placement="top-start" width="200" trigger="hover" content="给素材添加业务类型,客户可根据业务类型筛选,也可在客户浏览了该素材时能及时提醒跟进员工,以提高客户成单率。"> <el-popover placement="top-start" width="200" trigger="hover" content="给素材添加业务类型,客户可根据业务类型筛选,也可在客户浏览了该素材时能及时提醒跟进员工,以提高客户成单率。">
<img slot="reference" src="@/assets/question.png" alt="" /> <img slot="reference" src="@/assets/question.png" alt="" />
</el-popover> </el-popover>
: :
</span> </span>
</span> </span>
<el-checkbox-group v-model="materialAddForm.businessType"> <el-checkbox-group v-model="materialAddForm.businessType">
...@@ -79,7 +79,7 @@ ...@@ -79,7 +79,7 @@
<el-popover placement="top-start" width="200" trigger="hover" content="有效浏览:指客户在页面的停留时间超过15秒并且有交互行为,非完全静止"> <el-popover placement="top-start" width="200" trigger="hover" content="有效浏览:指客户在页面的停留时间超过15秒并且有交互行为,非完全静止">
<img slot="reference" src="@/assets/question.png" alt="" /> <img slot="reference" src="@/assets/question.png" alt="" />
</el-popover> </el-popover>
: :
</span> </span>
</span> </span>
<el-checkbox :value="materialAddForm.isNotifySender" :checked="checked" @change="notifyChange">客户打开素材链接时通知发送人</el-checkbox> <el-checkbox :value="materialAddForm.isNotifySender" :checked="checked" @change="notifyChange">客户打开素材链接时通知发送人</el-checkbox>
...@@ -92,7 +92,7 @@ ...@@ -92,7 +92,7 @@
<el-popover placement="top-start" width="200" trigger="hover" content="标签失效后在客户信息中看不到此标签,但是在素材效果统计的记录仍然存在"> <el-popover placement="top-start" width="200" trigger="hover" content="标签失效后在客户信息中看不到此标签,但是在素材效果统计的记录仍然存在">
<img slot="reference" src="@/assets/question.png" alt="" /> <img slot="reference" src="@/assets/question.png" alt="" />
</el-popover> </el-popover>
: :
</span> </span>
</span> </span>
<span class="track-behavior">给浏览了素材的客户自动打上标签,并且标签在30天后自动失效</span> <span class="track-behavior">给浏览了素材的客户自动打上标签,并且标签在30天后自动失效</span>
...@@ -114,7 +114,7 @@ ...@@ -114,7 +114,7 @@
</div> </div>
</div> </div>
<div class="share"> <div class="share">
<div class="share-container"> <div class="share-container m-l-20">
<div class="share-top"> <div class="share-top">
<span>分享设置</span> <span>分享设置</span>
<span class="share-tips">设置自定义分享内容,能提高用户体验,促进用户打开链接的概率</span> <span class="share-tips">设置自定义分享内容,能提高用户体验,促进用户打开链接的概率</span>
...@@ -132,14 +132,14 @@ ...@@ -132,14 +132,14 @@
</div> </div>
<el-divider></el-divider> <el-divider></el-divider>
<div class="share-desc" v-show="descVisible"> <div class="share-desc" v-show="descVisible">
<div class="share-desc-left"> <div class="share-desc-left m-l-20">
<el-form-item label="分享标题:"> <el-form-item label="分享标题:">
<el-input v-model="materialAddForm.materialTitle" :size="size" maxlength="30" show-word-limit placeholder="请输入自定义标题"></el-input> <el-input v-model="materialAddForm.materialTitle" :size="size" maxlength="30" show-word-limit placeholder="请输入自定义标题"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="描述:"> <el-form-item label="描述:">
<el-input type="textarea" v-model="materialAddForm.description" :size="size" maxlength="30" show-word-limit placeholder="请输入自定义描述"></el-input> <el-input type="textarea" v-model="materialAddForm.description" :size="size" maxlength="30" show-word-limit placeholder="请输入自定义描述"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="封面:"> <el-form-item label="封面:">
<div class="img-div"> <div class="img-div">
<div class="put-img" v-show="materialAddForm.titleUrl"> <div class="put-img" v-show="materialAddForm.titleUrl">
<img :src="materialAddForm.titleUrl" alt="" /> <img :src="materialAddForm.titleUrl" alt="" />
...@@ -684,7 +684,7 @@ export default { ...@@ -684,7 +684,7 @@ export default {
} }
.share { .share {
margin-bottom: 80px; margin-bottom: 20px;
&-container { &-container {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
...@@ -719,7 +719,7 @@ export default { ...@@ -719,7 +719,7 @@ export default {
.el-input--small, .el-input--small,
.el-select, .el-select,
.el-select--small { .el-select--small {
width: 411px; width: 432px;
} }
.btn-cancle { .btn-cancle {
border-color: #5850ff; border-color: #5850ff;
......
...@@ -43,10 +43,10 @@ ...@@ -43,10 +43,10 @@
</div> </div>
<el-button class="seeEquity" size="small" type="primary" @click="openDialog">查看权益</el-button> <el-button class="seeEquity" size="small" type="primary" @click="openDialog">查看权益</el-button>
</div> </div>
<div class="cardDetail editForm" v-else> <div class="cardDetail editForm gl-form-page" v-else>
<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="90px" class="demo-ruleForm" style="width: 500px"> <el-form :model="ruleForm" :rules="rules" ref="ruleForm" class="demo-ruleForm">
<template v-if="!showGh"> <template v-if="!showGh">
<el-form-item label="会员卡名" prop="cardName" size="small"> <el-form-item label="会员卡名:" prop="cardName" size="small">
<el-input v-model.trim="ruleForm.cardName" size="small" class="cardNameInput" show-word-limit placeholder="请输入会员卡名" maxlength="15"></el-input> <el-input v-model.trim="ruleForm.cardName" size="small" class="cardNameInput" show-word-limit placeholder="请输入会员卡名" maxlength="15"></el-input>
</el-form-item> </el-form-item>
</template> </template>
...@@ -60,14 +60,14 @@ ...@@ -60,14 +60,14 @@
</template> </template>
<div class="pricesMerge"> <div class="pricesMerge">
<el-form-item label="售价" size="small" prop="price" style="width: 300px"> <el-form-item label="售价/元:" size="small" prop="price" style="width: 300px">
<el-input v-model="ruleForm.price" size="small" placeholder="请输入售价" @keyup.native="ruleForm.price = oninput(ruleForm.price)"> <el-input v-model="ruleForm.price" size="small" style="width: 136px;" placeholder="请输入售价" @keyup.native="ruleForm.price = oninput(ruleForm.price)">
<span slot="suffix" class="suffix-label">元</span> <!-- <span slot="suffix" class="suffix-label">元</span> -->
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item label="市场价" prop="marketPrice" size="small" style="width: 300px"> <el-form-item label="市场价/元:" prop="marketPrice" size="small" style="width: 300px">
<el-input v-model="ruleForm.marketPrice" size="small" placeholder="请输入市场价" @keyup.native="ruleForm.marketPrice = oninput(ruleForm.marketPrice)"> <el-input v-model="ruleForm.marketPrice" size="small" style="width: 136px;" placeholder="请输入市场价" @keyup.native="ruleForm.marketPrice = oninput(ruleForm.marketPrice)">
<span slot="suffix" class="suffix-label">元</span> <!-- <span slot="suffix" class="suffix-label">元</span> -->
</el-input> </el-input>
</el-form-item> </el-form-item>
</div> </div>
...@@ -110,7 +110,7 @@ ...@@ -110,7 +110,7 @@
</span> </span>
</GLTable> </GLTable>
</div> </div>
<GLDialog :mode="mode" title="权益详情" :hasFooter="hasFooter" :type="'error'" :visible.sync="isDialogVisible"> <GLDialog :mode="mode" title="权益详情" :hasFooter="hasFooter" :type="'error'" :visible.sync="isDialogVisible">
<div class="modal-body"> <div class="modal-body">
<div class="equity-name">汽车权益</div> <div class="equity-name">汽车权益</div>
<div class="equity-panel"> <div class="equity-panel">
...@@ -133,7 +133,7 @@ ...@@ -133,7 +133,7 @@
</div> </div>
</GLDialog> </GLDialog>
<!-- 推广弹窗 --> <!-- 推广弹窗 -->
<GLDialog :mode="mode" title="试用推广" @onOk="handleQRConfirm" @onCancel="handleQRClose" :visible.sync="isQRVisible"> <GLDialog :mode="mode" title="试用推广" @onOk="handleQRConfirm" @onCancel="handleQRClose" :visible.sync="isQRVisible">
<el-form class="proForm" :model="ruleForm" :rules="rules" ref="ruleForm" label-width="68px"> <el-form class="proForm" :model="ruleForm" :rules="rules" ref="ruleForm" label-width="68px">
<div class="form"> <div class="form">
<div class="main-qrcode"> <div class="main-qrcode">
...@@ -771,7 +771,6 @@ export default { ...@@ -771,7 +771,6 @@ export default {
width: 215px; width: 215px;
} }
/deep/.el-dialog__body { /deep/.el-dialog__body {
.modal-body { .modal-body {
max-height: 400px; max-height: 400px;
} }
......
...@@ -5,14 +5,14 @@ ...@@ -5,14 +5,14 @@
<p class="pageTitle" v-else>编辑套餐</p> <p class="pageTitle" v-else>编辑套餐</p>
<!-- <el-button type="primary" size="small" @click="goBack">返回</el-button> --> <!-- <el-button type="primary" size="small" @click="goBack">返回</el-button> -->
</div> </div>
<div class="live-room container marketing "> <div class="live-room container marketing gl-form-page">
<el-form ref="ruleForm" :rules="rules" :model="ruleForm" label-width="120px" class="demo-ruleForm"> <el-form ref="ruleForm" :rules="rules" :model="ruleForm" class="demo-ruleForm">
<el-form-item size="small" label="套餐名称" prop="packageName" style="width: 440px"> <el-form-item size="small" label="套餐名称:" prop="packageName">
<el-input size="small" v-model="ruleForm.packageName" maxlength="15" placeholder="请输入套餐名称"></el-input> <el-input size="small" v-model="ruleForm.packageName" maxlength="15" placeholder="请输入套餐名称"></el-input>
</el-form-item> </el-form-item>
<el-form-item size="small" label="服务内容" class="is-required"> <el-form-item size="small" label="服务内容:" class="is-required">
<el-button @click="handleGiftAdd" size="small" class="default-blue-btn">选择服务</el-button> <el-button @click="handleGiftAdd" size="small" class="default-blue-btn">选择服务</el-button>
<div class="gift-block m-t-10" :style="{ 'margin-left': labelWidth }" v-show="choseItemList.length != 0"> <div class="gift-block m-t-10" :style="{ 'margin-left': defaultLabelWidth }" v-show="choseItemList.length != 0">
<div v-for="(item, index) in orderShow" :key="index"> <div v-for="(item, index) in orderShow" :key="index">
<div class="gift-box flex-top" v-show="couponObj[item].list.length"> <div class="gift-box flex-top" v-show="couponObj[item].list.length">
<img class="gift-logo" :src="couponObj[item].logo" alt="" /> <img class="gift-logo" :src="couponObj[item].logo" alt="" />
...@@ -30,9 +30,9 @@ ...@@ -30,9 +30,9 @@
<div class="el-form-item__error" v-if="setmealContentRules">请选择套餐</div> <div class="el-form-item__error" v-if="setmealContentRules">请选择套餐</div>
</el-form-item> </el-form-item>
<el-form-item size="small" label="套餐售价" prop="packagePrice" style="width: 315px"> <el-form-item size="small" label="套餐售价/元:" prop="packagePrice">
<el-input size="small" v-model="ruleForm.packagePrice" placeholder="请输入套餐售价" @keyup.native="ruleForm.packagePrice = oninput(ruleForm.packagePrice)"> <el-input size="small" v-model="ruleForm.packagePrice" placeholder="请输入套餐售价" @keyup.native="ruleForm.packagePrice = oninput(ruleForm.packagePrice)">
<span slot="suffix" class="suffix-label">元</span> <!-- <span slot="suffix" class="suffix-label">元</span> -->
</el-input> </el-input>
</el-form-item> </el-form-item>
<!-- <template v-if="accountLevel == 4"> <!-- <template v-if="accountLevel == 4">
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
<span class="price">{{ totalShopPrice }}元</span> <span class="price">{{ totalShopPrice }}元</span>
</div> </div>
</template> --> </template> -->
<el-form-item size="small" label="说明" prop="notes" style="width: 670px"> <el-form-item size="small" label="说明:" prop="notes">
<el-input size="small" :rows="6" type="textarea" v-model="ruleForm.notes" placeholder="请输入" maxlength="200" show-word-limit></el-input> <el-input size="small" :rows="6" type="textarea" v-model="ruleForm.notes" placeholder="请输入" maxlength="200" show-word-limit></el-input>
</el-form-item> </el-form-item>
</el-form> </el-form>
...@@ -195,7 +195,7 @@ export default { ...@@ -195,7 +195,7 @@ export default {
this.getServiceInfo() this.getServiceInfo()
// this.getSetmealServiceFun() //获取服务套餐,执行完了之后去获取编辑详情 // this.getSetmealServiceFun() //获取服务套餐,执行完了之后去获取编辑详情
}, },
mounted() {}, mounted() { },
methods: { methods: {
//获取会员卡上方卡片的相关信息 //获取会员卡上方卡片的相关信息
getCardContentFun() { getCardContentFun() {
......
...@@ -3,11 +3,11 @@ ...@@ -3,11 +3,11 @@
<div class="edit-car marketing edit-box"> <div class="edit-car marketing edit-box">
<div class="container edit-container"> <div class="container edit-container">
<p class="edit-title">{{ title }}</p> <p class="edit-title">{{ title }}</p>
<glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :labelWidth="labelWidth" defaultWidth="320px" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :labelWidth="defaultLabelWidth" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<div slot="selectMerchant" slot-scope="scope" class="select-merchant"> <div slot="selectMerchant" slot-scope="scope" class="select-merchant">
<el-button type="default" @click="handleRelateStoreClose(scope)">{{ editForm.merchantList.length ? '更换门店' : '+选择门店' }}</el-button> <el-button type="default" @click="handleRelateStoreClose(scope)">{{ editForm.merchantList.length ? '更换门店' : '+选择门店' }}</el-button>
</div> </div>
<div slot="merchantTable" :style="{ 'margin-left': labelWidth, width: `calc(100% - ${labelWidth} )` }"> <div slot="merchantTable" :style="{ 'margin-left': defaultLabelWidth, width: `calc(100% - ${defaultLabelWidth} )` }">
<GLTable v-show="editForm.merchantList.length" ref="warehousListRef" :hasPage="false" :tableParams="tableParams" :tableData="editForm.merchantList"> <GLTable v-show="editForm.merchantList.length" ref="warehousListRef" :hasPage="false" :tableParams="tableParams" :tableData="editForm.merchantList">
<span slot="auth-button" slot-scope="scope"> <span slot="auth-button" slot-scope="scope">
<el-button type="text" @click="handleMerchantDelete(scope)">删除</el-button> <el-button type="text" @click="handleMerchantDelete(scope)">删除</el-button>
...@@ -58,7 +58,6 @@ export default { ...@@ -58,7 +58,6 @@ export default {
id: '' id: ''
}, },
editStatus: false, editStatus: false,
labelWidth: '144px',
editForm: { editForm: {
// 专区类型(1发现频道,2商城专区) // 专区类型(1发现频道,2商城专区)
zoneType: '2', zoneType: '2',
......
...@@ -61,12 +61,12 @@ ...@@ -61,12 +61,12 @@
<!-- 表格区域 - 全部订单/售后订单 - end --> <!-- 表格区域 - 全部订单/售后订单 - end -->
</div> </div>
<!-- 快递信息 --> <!-- 快递信息 -->
<GLDialog v-if="isExpressVisible" title="输入快递信息" mode="small" okText="确定" cancelText="取消" :visible.sync="isExpressVisible" @onOk="handleExpressConfirm" @onCancel="handleExpressClose"> <GLDialog v-if="isExpressVisible" title="输入快递信息" mode="mid" okText="确定" cancelText="取消" :visible.sync="isExpressVisible" @onOk="handleExpressConfirm" @onCancel="handleExpressClose">
<glsx-combi-form class="small-content" ref="expressRef" labelWidth="100px" defaultWidth="320px" :isBlock="true" :formRef="editChildRef" :formObj="expressForm" :formData="expressFormData" :formRules="expressRules"></glsx-combi-form> <glsx-combi-form class="small-content m-t-20" ref="expressRef" :isBlock="true" defaultWidth="284px" :isEdit="isEdit" :formRef="editChildRef" :formObj="expressForm" :formData="expressFormData" :formRules="expressRules"></glsx-combi-form>
</GLDialog> </GLDialog>
<!-- 订单核销 --> <!-- 订单核销 -->
<GLDialog v-if="isWriteOffVisible" title="订单核销(请确保用户到店后核销,避免引起不必要问题)" mode="small" okText="确定" cancelText="取消" :visible.sync="isWriteOffVisible" @onOk="handleWriteOffConfirm" @onCancel="handleWriteOffClose"> <GLDialog v-if="isWriteOffVisible" title="订单核销(请确保用户到店后核销,避免引起不必要问题)" mode="mid" okText="确定" cancelText="取消" :visible.sync="isWriteOffVisible" @onOk="handleWriteOffConfirm" @onCancel="handleWriteOffClose">
<glsx-combi-form class="small-content" ref="writeOffRef" labelWidth="100px" defaultWidth="320px" :isBlock="true" :formRef="editChildRef" :formObj="writeOffForm" :formData="writeOffFormData" :formRules="writeOffRules"></glsx-combi-form> <glsx-combi-form class="small-content m-t-20" ref="writeOffRef" :isBlock="true" defaultWidth="284px" :formRef="editChildRef" :formObj="writeOffForm" :formData="writeOffFormData" :formRules="writeOffRules"></glsx-combi-form>
</GLDialog> </GLDialog>
<!-- 退款审核 --> <!-- 退款审核 -->
<GLDialog v-if="isExamineVisible" bigTitle="退款审核" mode="big" :visible.sync="isExamineVisible" @onOk="handleExamineConfirm" @onCancel="handleExamineClose"> <GLDialog v-if="isExamineVisible" bigTitle="退款审核" mode="big" :visible.sync="isExamineVisible" @onOk="handleExamineConfirm" @onCancel="handleExamineClose">
...@@ -95,7 +95,7 @@ ...@@ -95,7 +95,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<template v-if="orderInfo.refundType == 1 && examineForm.isAllowed == '1'"> <template v-if="orderInfo.refundType == 1 && examineForm.isAllowed == '1'">
<glsx-combi-form ref="examineRef" :isEdit="isEdit" defaultWidth="320px" :isBlock="true" :formRef="editChildRef" :formObj="examineForm" :formData="examineFormData" :formRules="examineRules"></glsx-combi-form> <glsx-combi-form ref="examineRef" :isEdit="isEdit" defaultWidth="284px" :isBlock="true" :formRef="editChildRef" :formObj="examineForm" :formData="examineFormData" :formRules="examineRules"></glsx-combi-form>
</template> </template>
</el-form> </el-form>
</GLDialog> </GLDialog>
...@@ -316,6 +316,20 @@ export default { ...@@ -316,6 +316,20 @@ export default {
labelWidth: 56, labelWidth: 56,
type: 'input', type: 'input',
maxlength: 100 maxlength: 100
},
{
label: '手机号',
name: 'customerPhone',
labelWidth: 56,
type: 'input',
maxlength: 11
},
{
label: '推荐人手机号',
name: 'shareStaffPhone',
labelWidth: 56,
type: 'input',
maxlength: 11
} }
], ],
// 快递信息 // 快递信息
...@@ -497,19 +511,34 @@ export default { ...@@ -497,19 +511,34 @@ export default {
tableOption: true, tableOption: true,
tableColumns: [ tableColumns: [
{ {
label: '订单编号', label: '客户名称',
prop: 'orderCode', prop: 'customerName',
width: '180' line: 2,
width: 180,
formatter: cellValue => {
return cellValue.customerName || '-'
}
}, },
{ {
label: '商户订单号', label: '手机号',
prop: 'outTradeNo', prop: 'customerPhone',
width: '160', width: 130,
formatter: cellValue => { formatter: cellValue => {
return cellValue.outTradeNo || '-' return cellValue.customerPhone || '-'
} }
}, },
{ {
label: '其他信息',
prop: 'otherInformation',
width: '280'
},
{
label: '微信名称',
prop: 'weChatName',
addHtml: 'weChatName',
width: 300
},
{
label: '订单时间', label: '订单时间',
prop: 'createdDate', prop: 'createdDate',
width: '180', width: '180',
...@@ -534,29 +563,6 @@ export default { ...@@ -534,29 +563,6 @@ export default {
} }
}, },
{ {
label: '微信名称',
prop: 'weChatName',
addHtml: 'weChatName',
width: 300
},
{
label: '客户名称',
prop: 'customerName',
line: 2,
width: 180,
formatter: cellValue => {
return cellValue.customerName || '-'
}
},
{
label: '手机号',
prop: 'customerPhone',
width: 130,
formatter: cellValue => {
return cellValue.customerPhone || '-'
}
},
{
label: '车架号', label: '车架号',
prop: 'vinNo', prop: 'vinNo',
width: 130, width: 130,
...@@ -632,6 +638,19 @@ export default { ...@@ -632,6 +638,19 @@ export default {
formatter: cellValue => { formatter: cellValue => {
return this.baseData.deliveryTypeList.map(item => item.confId).includes(cellValue.deliveryType + '') ? this.baseData.deliveryTypeList.find(item => item.confId == cellValue.deliveryType).confName : '-' return this.baseData.deliveryTypeList.map(item => item.confId).includes(cellValue.deliveryType + '') ? this.baseData.deliveryTypeList.find(item => item.confId == cellValue.deliveryType).confName : '-'
} }
},
{
label: '订单编号',
prop: 'orderCode',
width: '180'
},
{
label: '商户订单号',
prop: 'outTradeNo',
width: '160',
formatter: cellValue => {
return cellValue.outTradeNo || '-'
}
} }
] ]
}, },
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<div class="edit-share marketing edit-box"> <div class="edit-share marketing edit-box">
<div class="container edit-container"> <div class="container edit-container">
<p class="edit-title">{{ title }}</p> <p class="edit-title">{{ title }}</p>
<glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" defaultWidth="320px" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<template slot="selectPro" slot-scope="scope"> <template slot="selectPro" slot-scope="scope">
<el-button type="primary" @click="handleRelateProClose(scope)">{{ editForm.goodsId ? '更换' : '请选择' }}</el-button> <el-button type="primary" @click="handleRelateProClose(scope)">{{ editForm.goodsId ? '更换' : '请选择' }}</el-button>
<div class="m-t-10" v-show="editForm.goodsId"> <div class="m-t-10" v-show="editForm.goodsId">
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
<div class="home-set-form flex-grow"> <div class="home-set-form flex-grow">
<div v-for="(item, index) in externalFormList" :key="index"> <div v-for="(item, index) in externalFormList" :key="index">
<p class="edit-title">{{ item.title }}</p> <p class="edit-title">{{ item.title }}</p>
<glsx-combi-form class="edit-form-container m-b-60" ref="editFormRef" :labelWidth="labelWidth" :isEdit="isEdit" defaultWidth="320px" :isBlock="true" :formRef="item.editChildRef" :formObj="editForm" :formData="item.editFormData" :formRules="item.editRule" @handleImgDelete="handleFormImgDelete"> <glsx-combi-form class="edit-form-container m-b-60" ref="editFormRef" :isEdit="isEdit" :isBlock="true" :formRef="item.editChildRef" :formObj="editForm" :formData="item.editFormData" :formRules="item.editRule" @handleImgDelete="handleFormImgDelete">
<template slot="businessType" slot-scope="scope"> <template slot="businessType" slot-scope="scope">
<el-checkbox-group v-model="editForm.businessType"> <el-checkbox-group v-model="editForm.businessType">
<el-checkbox :disabled="routeInfo.addOrEdit == 3" v-for="value in scope.scope.businessTypeList" :key="value.businessType" :label="value.businessType">{{ value.businessTypeName }}</el-checkbox> <el-checkbox :disabled="routeInfo.addOrEdit == 3" v-for="value in scope.scope.businessTypeList" :key="value.businessType" :label="value.businessType">{{ value.businessTypeName }}</el-checkbox>
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
<p class="edit-tips">作为商品详情页顶部展示</p> <p class="edit-tips">作为商品详情页顶部展示</p>
<p class="edit-tips">格式建议mp4,大小不超过20M</p> <p class="edit-tips">格式建议mp4,大小不超过20M</p>
</template> </template>
<div :style="{ 'margin-left': labelWidth }" slot="descImgs" slot-scope="scope"> <div :style="{ 'margin-left': defaultLabelWidth }" slot="descImgs" slot-scope="scope">
<div v-for="(subItem, subIndex) in editForm[scope.scope.name]" :key="subIndex" class="flex"> <div v-for="(subItem, subIndex) in editForm[scope.scope.name]" :key="subIndex" class="flex">
<!-- 上传图片 --> <!-- 上传图片 -->
<div class="banner-upload-box"> <div class="banner-upload-box">
...@@ -63,26 +63,6 @@ ...@@ -63,26 +63,6 @@
</div> </div>
<template slot="association"> <template slot="association">
<el-button type="default" :disabled="specificationDetailList.length" @click="dialogTableVisible = true" v-if="routeInfo.addOrEdit !== 3">+选择</el-button> <el-button type="default" :disabled="specificationDetailList.length" @click="dialogTableVisible = true" v-if="routeInfo.addOrEdit !== 3">+选择</el-button>
<GLDialog bigTitle="选择优惠券" mode="big" :visible.sync="dialogTableVisible" @onOk="associationConfirm" @onCancel="associationCancel">
<glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormData">
<span slot="footer" class="footer-btns">
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
</span>
</glsx-combi-form>
<!-- <GLButton class="default-blue-btn" style="float: right; margin-bottom: 10px;" :size="size" fn="创建优惠券" @click="handleJumpCoupon">创建优惠券</GLButton> -->
<el-button class="default-blue-btn" style="float: right; margin: 0 10px 10px 0;" :size="size" @click="handleJumpCoupon">创建优惠券</el-button>
<GLTable ref="coupon" :hasNum="false" :getListApi="getListApi" :searchForm="searchForm" :tableParams="associationTableParams" :pageConf="pageConf" @setTableFinishFun="setTableFinishFun">
<div slot="association" slot-scope="scope" class="association">
<el-radio :label="scope.scope.id" v-model="associationRadio" @change.native="getCouponInfo()"></el-radio>
</div>
</GLTable>
<!-- 表格区域 end -->
<!-- <div class="associationBtn">
<el-button type="primary" @click="associationConfirm">确定</el-button>
<el-button type="default" @click="associationCancel">取消</el-button>
</div> -->
</GLDialog>
<div class="association-X" v-if="editForm.relatedCouponId"> <div class="association-X" v-if="editForm.relatedCouponId">
<div class="associationRow"> <div class="associationRow">
<span class="associationLists">名称</span> <span class="associationLists">名称</span>
...@@ -105,7 +85,7 @@ ...@@ -105,7 +85,7 @@
<template slot="proSpecsBtn"> <template slot="proSpecsBtn">
<el-button :disabled="editForm.relatedCouponId || isDisabled" type="default" @click="handleSpecsEdit(1)">+添加规格项目</el-button> <el-button :disabled="editForm.relatedCouponId || isDisabled" type="default" @click="handleSpecsEdit(1)">+添加规格项目</el-button>
</template> </template>
<div slot="proSpecs" :style="{ 'margin-left': labelWidth }"> <div slot="proSpecs" :style="{ 'margin-left': defaultLabelWidth }">
<div class="sepce-box" v-for="(subItem, subIndex) in specificationDetailList" :key="subIndex"> <div class="sepce-box" v-for="(subItem, subIndex) in specificationDetailList" :key="subIndex">
<div> <div>
<span class="specs-title">规格名:</span> <span class="specs-title">规格名:</span>
...@@ -126,8 +106,8 @@ ...@@ -126,8 +106,8 @@
</div> </div>
</div> </div>
<div slot="specsDetail" class="flex"> <div slot="specsDetail" class="flex">
<span class="spesc-label" :style="{ width: labelWidth }">规格明细:</span> <span class="spesc-label" :style="{ width: defaultLabelWidth }">规格明细:</span>
<div :style="{ width: `calc(100% - ${labelWidth} )` }"> <div :style="{ width: `calc(100% - ${defaultLabelWidth} )` }">
<table class="table-spesc"> <table class="table-spesc">
<tbody> <tbody>
<tr style="padding: 17px 0; background: #F4F6FC; box-shadow: 0px 1px 5px 0px rgba(38, 38, 38, 0.1);"> <tr style="padding: 17px 0; background: #F4F6FC; box-shadow: 0px 1px 5px 0px rgba(38, 38, 38, 0.1);">
...@@ -144,16 +124,16 @@ ...@@ -144,16 +124,16 @@
<td :style="{ width: specsWidth }" v-for="(n, idx) in subItem.specsValueList" :key="idx" :title="n">{{ n }}</td> <td :style="{ width: specsWidth }" v-for="(n, idx) in subItem.specsValueList" :key="idx" :title="n">{{ n }}</td>
<td :style="{ width: specsWidth }"> <td :style="{ width: specsWidth }">
<div v-if="routeInfo.groupOrStore == 1 && editForm.takeType == '1'"> <div v-if="routeInfo.groupOrStore == 1 && editForm.takeType == '1'">
<el-input :disabled="isDisabled" :class="{ 'border-red': (!(subItem.retailPrice + '') || +editForm.supplyPrice > +subItem.retailPrice) && submitted }" placeholder="零售价" v-model="subItem.retailPrice" @input.native="e => handleRetailPriceInput(e, subIndex)" @blur="handleRetailPriceBlur"> <el-input :disabled="isDisabled" :class="{ 'w-100-per': true, 'border-red': (!(subItem.retailPrice + '') || +editForm.supplyPrice > +subItem.retailPrice) && submitted }" placeholder="零售价" v-model="subItem.retailPrice" @input.native="e => handleRetailPriceInput(e, subIndex)" @blur="handleRetailPriceBlur">
<el-popover v-show="(!(subItem.retailPrice + '') || +editForm.supplyPrice > +subItem.retailPrice) && submitted" slot="suffix" placement="top" title width="90" trigger="hover" :content="!(subItem.retailPrice + '') ? '零售价是必填项' : '零售价要大于供货价'"> <el-popover v-show="(!(subItem.retailPrice + '') || +editForm.supplyPrice > +subItem.retailPrice) && submitted" slot="suffix" placement="top" title width="90" trigger="hover" :content="!(subItem.retailPrice + '') ? '零售价是必填项' : '零售价要大于供货价'">
<i class="el-icon-warning color-red" slot="reference"></i> <i class="el-icon-warning color-red" slot="reference"></i>
</el-popover> </el-popover>
</el-input> </el-input>
</div> </div>
<el-input :disabled="isDisabled" v-else placeholder="零售价" v-model="subItem.retailPrice" @input.native="e => handleRetailPriceInput(e, subIndex)" @blur="handleRetailPriceBlur"></el-input> <el-input :disabled="isDisabled" class="w-100-per" v-else placeholder="零售价" v-model="subItem.retailPrice" @input.native="e => handleRetailPriceInput(e, subIndex)" @blur="handleRetailPriceBlur"></el-input>
</td> </td>
<td :style="{ width: specsWidth }"> <td :style="{ width: specsWidth }">
<el-input :disabled="isDisabled" placeholder="库存" v-model="subItem.stock" :class="{ 'border-red': !(subItem.stock + '') && submitted }" @input.native="e => handleStockInput(e, subIndex)"> <el-input :disabled="isDisabled" placeholder="库存" v-model="subItem.stock" :class="{ 'w-100-per': true, 'border-red': !(subItem.stock + '') && submitted }" @input.native="e => handleStockInput(e, subIndex)">
<el-popover v-show="!(subItem.stock + '') && submitted" slot="suffix" placement="top" title width="90" trigger="hover" content="库存是必填项"> <el-popover v-show="!(subItem.stock + '') && submitted" slot="suffix" placement="top" title width="90" trigger="hover" content="库存是必填项">
<i class="el-icon-warning color-red" slot="reference"></i> <i class="el-icon-warning color-red" slot="reference"></i>
</el-popover> </el-popover>
...@@ -185,12 +165,12 @@ ...@@ -185,12 +165,12 @@
<span class="mode-radio">{{ n.confName }}</span> <span class="mode-radio">{{ n.confName }}</span>
<span class="mode-radio radio-tip-txt" @click.stop.prevent="e => handleCancelBubble(e)">{{ scope.scope.tipObj[n.confId] }}</span> <span class="mode-radio radio-tip-txt" @click.stop.prevent="e => handleCancelBubble(e)">{{ scope.scope.tipObj[n.confId] }}</span>
</div> </div>
<el-form-item v-show="n.confId == '0'" prop="takeFee" label="分润比例:"> <el-form-item v-show="n.confId == '0'" prop="takeFee" label="分润比例/%:" class="form-sub-block">
<el-input v-model="editForm.takeFee" :disabled="isDisabled || editForm[scope.scope.name] != '0'" placeholder="请输入分润比例"><span slot="append">%</span></el-input> <el-input v-model="editForm.takeFee" :disabled="isDisabled || editForm[scope.scope.name] != '0'" placeholder="请输入分润比例"></el-input>
<p class="edit-tips">此商品由门店帮卖货后获得的分成比例</p> <p class="edit-tips">此商品由门店帮卖货后获得的分成比例</p>
</el-form-item> </el-form-item>
<el-form-item v-show="n.confId == '1'" prop="supplyPrice" label="供货价:"> <el-form-item v-show="n.confId == '1'" prop="supplyPrice" label="供货价/元:" class="form-sub-block">
<el-input v-model="editForm.supplyPrice" :disabled="isDisabled || editForm[scope.scope.name] != '1'" placeholder="请输入供货价"><span slot="append">元</span></el-input> <el-input v-model="editForm.supplyPrice" :disabled="isDisabled || editForm[scope.scope.name] != '1'" placeholder="请输入供货价"></el-input>
<p class="edit-tips">作为货源供给门店的价格</p> <p class="edit-tips">作为货源供给门店的价格</p>
</el-form-item> </el-form-item>
</el-radio> </el-radio>
...@@ -198,7 +178,7 @@ ...@@ -198,7 +178,7 @@
</el-radio-group> </el-radio-group>
</template> </template>
<template slot="serviceDescHtml"> <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" placeholder="请输入服务说明" :autosize="{ minRows: 2, maxRows: 4 }" maxlength="30" :disabled="isDisabled" />
</template> </template>
<div slot="selectMerchant" slot-scope="scope" class="select-merchant"> <div slot="selectMerchant" slot-scope="scope" class="select-merchant">
<div> <div>
...@@ -209,10 +189,10 @@ ...@@ -209,10 +189,10 @@
</div> </div>
<el-button :disabled="isDisabled" v-show="editForm.takeAllMerchant == '0'" type="default" @click="handleRelateStoreClose(scope)">{{ editForm.supplyMerchantList.length ? '更换门店' : '+选择门店' }}</el-button> <el-button :disabled="isDisabled" v-show="editForm.takeAllMerchant == '0'" type="default" @click="handleRelateStoreClose(scope)">{{ editForm.supplyMerchantList.length ? '更换门店' : '+选择门店' }}</el-button>
</div> </div>
<div slot="merchantTable" class="select-merchant" v-show="editForm.takeAllMerchant == '0'" :style="{ 'margin-left': labelWidth, width: `calc(100% - ${labelWidth} - 10px )` }"> <div slot="merchantTable" class="select-merchant" v-show="editForm.takeAllMerchant == '0'" :style="{ 'margin-left': defaultLabelWidth, width: `calc(100% - ${defaultLabelWidth} - 10px )` }">
<GLTable v-show="editForm.supplyMerchantList.length" ref="merchantTableRef" :tableParams="tableParams" :tableData="editForm.supplyMerchantList" :hasPage="false"> <GLTable v-show="editForm.supplyMerchantList.length" ref="merchantTableRef" :tableParams="tableParams" :tableData="editForm.supplyMerchantList" :hasPage="false">
<span slot="auth-button" slot-scope="scope"> <span slot="customBtn" slot-scope="scope">
<el-button :disabled="isDisabled" type="text" @click="handleMerchantDelete(scope)">删除</el-button> <el-button class="p-0" :disabled="isDisabled" type="text" @click="handleMerchantDelete(scope)">删除</el-button>
</span> </span>
</GLTable> </GLTable>
</div> </div>
...@@ -289,6 +269,20 @@ ...@@ -289,6 +269,20 @@
<el-dialog :visible.sync="isImgVisible"> <el-dialog :visible.sync="isImgVisible">
<img class="dialog-img" width="100%" :src="dialogImageUrl" alt /> <img class="dialog-img" width="100%" :src="dialogImageUrl" alt />
</el-dialog> </el-dialog>
<GLDialog bigTitle="选择优惠券" mode="big" :visible.sync="dialogTableVisible" @onOk="associationConfirm" @onCancel="associationCancel">
<glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormData">
<span slot="footer" class="footer-btns">
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
</span>
</glsx-combi-form>
<!-- <GLButton class="default-blue-btn" style="float: right; margin-bottom: 10px;" :size="size" fn="创建优惠券" @click="handleJumpCoupon">创建优惠券</GLButton> -->
<el-button class="default-blue-btn" style="float: right; margin: 0 10px 10px 0;" :size="size" @click="handleJumpCoupon">创建优惠券</el-button>
<GLTable ref="coupon" :hasNum="false" :getListApi="getListApi" :searchForm="searchForm" :tableParams="associationTableParams" :pageConf="pageConf" @setTableFinishFun="setTableFinishFun">
<div slot="association" slot-scope="scope" class="association">
<el-radio :label="scope.scope.id" v-model="associationRadio" @change.native="getCouponInfo()"></el-radio>
</div>
</GLTable>
</GLDialog>
<GLDialog title="规格" mode="mid" :visible.sync="isSpescVisible" @onOk="handleSpescConfirm" @onCancel="handleSpescClose"> <GLDialog title="规格" mode="mid" :visible.sync="isSpescVisible" @onOk="handleSpescConfirm" @onCancel="handleSpescClose">
<el-form label-width="120px" :model="spescEditForm" :rules="spescRules" ref="spescRef"> <el-form label-width="120px" :model="spescEditForm" :rules="spescRules" ref="spescRef">
<el-form-item label="规格名:" prop="specificationName"> <el-form-item label="规格名:" prop="specificationName">
...@@ -442,11 +436,15 @@ export default { ...@@ -442,11 +436,15 @@ export default {
selectedList: [], selectedList: [],
// 门店表格 // 门店表格
tableParams: { tableParams: {
tableOption: true,
tableColumns: [ tableColumns: [
{ {
label: '门店名称', label: '门店名称',
prop: 'merchantName' prop: 'merchantName'
},
{
label: '操作',
prop: '',
addHtml: 'customBtn'
} }
] ]
}, },
...@@ -516,7 +514,6 @@ export default { ...@@ -516,7 +514,6 @@ export default {
serviceDesc: '' serviceDesc: ''
}, },
isEdit: true, isEdit: true,
labelWidth: '144px',
externalFormList: [ externalFormList: [
{ {
title: '基本信息', title: '基本信息',
...@@ -639,7 +636,7 @@ export default { ...@@ -639,7 +636,7 @@ export default {
rows: 5, rows: 5,
maxlength: '200', maxlength: '200',
style: { style: {
'margin-left': '144px' 'margin-left': this.defaultLabelWidth
} }
}, },
{ {
...@@ -699,22 +696,20 @@ export default { ...@@ -699,22 +696,20 @@ export default {
addHtml: 'specsDetail' addHtml: 'specsDetail'
}, },
{ {
label: '零售价', label: '零售价/元',
name: 'retailPrice', name: 'retailPrice',
type: 'input', type: 'input',
append: '元',
width: '320px',
suffixSlot: 'retailPrice', suffixSlot: 'retailPrice',
placeholder: '请输入零售价',
isHide: false, isHide: false,
isDisabled: false isDisabled: false
}, },
{ {
label: '划线价', label: '划线价/元',
name: 'originalPrice', name: 'originalPrice',
type: 'input', type: 'input',
append: '元',
width: '320px',
suffixSlot: 'originalPrice', suffixSlot: 'originalPrice',
placeholder: '请输入划线价',
isDisabled: false isDisabled: false
}, },
// { // {
...@@ -727,12 +722,11 @@ export default { ...@@ -727,12 +722,11 @@ export default {
// isDisabled: false // isDisabled: false
// }, // },
{ {
label: '会员价', label: '会员价/元',
name: 'memberPrice', name: 'memberPrice',
type: 'input', type: 'input',
append: '元',
width: '320px',
suffixSlot: 'memberPrice', suffixSlot: 'memberPrice',
placeholder: '请输入会员价',
isDisabled: false isDisabled: false
}, },
{ {
...@@ -747,12 +741,11 @@ export default { ...@@ -747,12 +741,11 @@ export default {
isDisabled: false isDisabled: false
}, },
{ {
label: '库存', label: '库存/件',
name: 'goodsStock', name: 'goodsStock',
type: 'input', type: 'input',
append: '件',
width: '320px',
suffixSlot: 'goodsStock', suffixSlot: 'goodsStock',
placeholder: '请输入库存',
isHide: false, isHide: false,
isDisabled: false isDisabled: false
} }
...@@ -808,11 +801,10 @@ export default { ...@@ -808,11 +801,10 @@ export default {
isDisabled: false isDisabled: false
}, },
{ {
label: '运费', label: '运费/元',
name: 'expressFee', name: 'expressFee',
type: 'input', type: 'input',
append: '元', placeholder: '请输入运费',
width: '320px',
isHide: false, isHide: false,
isDisabled: false isDisabled: false
}, },
...@@ -1615,15 +1607,15 @@ export default { ...@@ -1615,15 +1607,15 @@ export default {
}, },
setTableFinishFun() { setTableFinishFun() {
let num = 0 let num = 0
let pageSize = Number(this.$refs.coupon[0].page.pageSize) let pageSize = Number(this.$refs.coupon.page.pageSize)
let pageNum = Number(this.$refs.coupon[0].page.pageNum) let pageNum = Number(this.$refs.coupon.page.pageNum)
let sum = pageSize * (pageNum - 1) let sum = pageSize * (pageNum - 1)
this.$refs.coupon[0].data.forEach(val => { this.$refs.coupon.data.forEach(val => {
if (num <= pageSize) val.num = ++num if (num <= pageSize) val.num = ++num
if (pageNum > 1) val.num = ++sum if (pageNum > 1) val.num = ++sum
}) })
//接收到的数据为空 //接收到的数据为空
this.templateSelection = this.$refs.coupon[0].data this.templateSelection = this.$refs.coupon.data
}, },
handleSearch() { handleSearch() {
this.$refs.coupon[0].refreshTable() this.$refs.coupon[0].refreshTable()
...@@ -1673,7 +1665,6 @@ export default { ...@@ -1673,7 +1665,6 @@ export default {
} }
.edit-pro .take-good-mode-block { .edit-pro .take-good-mode-block {
display: flex; display: flex;
align-items: center;
} }
.edit-pro .mode-radio { .edit-pro .mode-radio {
height: 32px; height: 32px;
...@@ -1681,7 +1672,8 @@ export default { ...@@ -1681,7 +1672,8 @@ export default {
margin-right: 8px; margin-right: 8px;
} }
.edit-pro .take-good-mode-block .el-radio__input { .edit-pro .take-good-mode-block .el-radio__input {
height: 86px; height: 100px;
margin-top: 10px;
} }
.edit-pro .take-good-mode-block .radio-tip-txt { .edit-pro .take-good-mode-block .radio-tip-txt {
color: #999999; color: #999999;
......
<template>
<div class="wechat-box marketing">
<img class="w-100-percent" src="@/assets/seckillActivity/phone.png" />
<div class="wechat-back">
<p class="wechat-name one-line-ellipsis">{{ editForm.activityName }}</p>
<img class="wechat-head" src="@/assets/seckillActivity/crowd-head.png" />
<img class="icon-server" src="@/assets/seckillActivity/icon-server.png" />
<div class="wechat-inner-box">
<div class="wechat-banner-img">
<img class="icon-music" src="@/assets/seckillActivity/icon-music.png" />
<img :src="editForm.activityBigImg || require('@/assets/seckillActivity/icon-default.png')" />
<img class="wechat-customer" src="@/assets/seckillActivity/crowd-customer.png" />
<div class="w-100-percent txt-center">
<video v-if="editForm.activityVideoList.length" class="wechat-video" controls>
<source :src="editForm.activityVideoList[0]" type="video/mp4" />
</video>
</div>
<div class="wechat-block">
<p class="wechat-block-title">活动举办方</p>
<div class="flex-center">
<div>
<p class="m-b-10">{{ editForm.sponsorName }}</p>
<p class="m-b-10 wechat-sub-addr">{{ editForm.activityAddressDetailName }}</p>
<p class="wechat-time" v-if="editForm.activityTime && editForm.activityTime.length">活动时间:{{ editForm.activityTime[0].split(' ')[0] }}-{{ editForm.activityTime[1].split(' ')[0] }}</p>
</div>
<img class="icon-addr" src="@/assets/seckillActivity/icon-addr.png" />
</div>
</div>
<div class="wechat-block">
<p class="wechat-block-title">{{ countDownObj.typeTxt }}</p>
<p v-if="countDownObj.activityStatus != 3" class="wechat-count-down">
<span v-if="editForm.activityTime && editForm.activityTime.length">{{ editForm.activityTime[0].split(' ')[0].split('-')[2] }}</span>
日开始活动,还差
<span class="wechat-txt">{{ countDownObj.d }}</span>天
<span class="wechat-txt">{{ countDownObj.h }}</span>时
<span class="wechat-txt">{{ countDownObj.m }}</span>分
<span class="wechat-txt">{{ countDownObj.s }}</span>秒
</p>
<img v-else class="count-down-img" src="@/assets/seckillActivity/count-down.png" />
</div>
<div class="w-100-percent txt-center">
<img class="crowd-jdt" src="@/assets/seckillActivity/crowd-jdt.png" />
</div>
<div class="wechat-block service">
<div class="serve" v-if="editForm.activityServices.length">
<div class="box flex">
<div style="width: 26px;">服务</div>
<div class="serve-text flex-center">
<template v-for="(i, index) in editForm.activityServices">
<div :key="index" class="flex-default">
{{ i.title }}
<span v-if="index != editForm.activityServices.length - 1">·</span>
</div>
</template>
</div>
<div class="sprite-icon icon-arrow"></div>
</div>
</div>
</div>
<div class="wechat-block">
<div>
<div class="flex">
<div>玩家心得({{ editForm.activityExperienceDTOs.length }})</div>
<div class="sprite-icon icon-arrow"></div>
</div>
<div v-if="editForm.activityExperienceDTOs.length">
<div class="head-box">
<img class="icon-head" src="@/assets/seckillActivity/icon-default-head.png" />
<span>虚拟人物1</span>
</div>
<div class="m-t-10">{{ editForm.activityExperienceDTOs[0].experience }}</div>
<div v-if="editForm.activityExperienceDTOs[0].activityExperienceImgs.length">
<img class="img-w-h m-t-10" v-for="(item, index) in editForm.activityExperienceDTOs[0].activityExperienceImgs" :key="index" :src="item" />
</div>
</div>
</div>
<div class="line"></div>
<div v-if="editForm.activityCommoditys.length">
<div class="flex m-b-10">
<div>商品答疑({{ editForm.activityCommoditys.length }})</div>
<div class="sprite-icon icon-arrow"></div>
</div>
<div class="m-b-10">
<span class="icon-question">问</span>
<span>{{ editForm.activityCommoditys[0].question }}</span>
</div>
<div>
<span class="icon-answer">答</span>
<span>{{ editForm.activityCommoditys[0].answer }}</span>
</div>
</div>
</div>
<div class="p-b-6"></div>
<div v-html="editForm.activityDetail"></div>
</div>
</div>
<div>
<img class="wechat-footer" src="@/assets/seckillActivity/crowd-footer.png" />
</div>
</div>
</div>
</template>
<script>
export default {
name: 'crowdEditWechat',
data() {
return {}
},
props: {
editForm: {
type: Object,
default: () => { }
},
countDownObj: {
type: Object,
default: () => { }
}
},
mounted() { },
methods: {}
}
</script>
<style lang="scss" scoped>
.wechat-box {
width: 276px;
box-sizing: border-box;
position: relative;
margin: 0 auto;
}
.wechat-box .wechat-inner-box {
position: absolute;
top: 73px;
left: 20px;
width: 236px;
height: 424px;
background-color: #f7f8fa;
overflow-y: scroll;
overflow-x: hidden;
}
.wechat-box .wechat-footer {
position: absolute;
width: 236px;
height: 35px;
bottom: 20px;
left: 20px;
}
.wechat-box .wechat-head {
position: absolute;
width: 236px;
height: 53px;
top: 20px;
left: 20px;
}
.wechat-box .wechat-banner-img {
width: 100%;
height: 552px;
}
.wechat-box .icon-server {
position: absolute;
width: 34px;
height: 42px;
top: 320px;
right: 30px;
z-index: 999;
}
.wechat-box .wechat-banner-img img {
width: 100%;
height: 385px;
}
.wechat-box .wechat-video {
width: 160px;
height: 90px;
margin: 10px auto;
}
.wechat-box .wechat-banner-img .icon-music {
position: absolute;
width: 20px;
height: 20px;
top: 20px;
right: 10px;
}
.wechat-box .wechat-banner-img .wechat-customer {
position: absolute;
width: 100px;
height: 137px;
top: 240px;
left: 10px;
}
.wechat-box .wechat-banner-img {
.wechat-block-title {
text-align: center;
color: #fc5b32;
}
.wechat-block {
box-sizing: border-box;
background-color: #fff;
width: 205px;
font-size: 14px;
padding: 10px;
margin: 10px 12px;
.wechat-sub-addr {
font-size: 12px;
color: #656566;
}
.wechat-time {
font-size: 12px;
color: #fc5b32;
}
.icon-addr {
width: 34px;
height: 34px;
}
.wechat-count-down {
line-height: 22px;
padding: 15px;
border: 1px dotted #e3e3e3;
margin-top: 10px;
}
.wechat-txt {
color: #f13c3d;
background-color: #fff4f4;
padding: 4px;
margin: 0 4px;
}
.count-down-img {
margin-top: 10px;
width: 180px;
height: 188px;
}
}
}
.wechat-box .wechat-banner-img .crowd-jdt {
width: 205px;
height: 80px;
}
.box {
color: #999999;
font-size: 12px;
font-weight: 400;
border-radius: 4px;
line-height: 17px;
.serve-text {
width: 130px;
color: #2c2c2c;
margin-left: 6px;
overflow: hidden;
white-space: nowrap;
span {
margin: 0 4px;
}
}
.sprite-icon {
margin-left: auto;
}
}
.icon-arrow {
width: 6px;
height: 6px;
border: 1px solid #fc5b32;
border-width: 1px 1px 0 0;
opacity: 0.7;
transform: rotate(45deg);
margin: 6px 0 0 5px;
}
.head-box {
display: flex;
align-items: center;
padding: 20px 0 0 0;
color: #282829;
.icon-head {
width: 26px !important;
height: 26px !important;
margin-right: 4px;
}
}
.img-w-h {
width: 30px !important;
height: 30px !important;
margin-right: 2px;
border-radius: 4px;
}
.line {
border: 1px solid #e3e3e6;
margin: 6px 0;
}
.icon-question {
width: 14px;
height: 14px;
font-size: 12px;
background: linear-gradient(108deg, #ffbe68 0%, #ff5446 60%, #f45454 100%);
border-radius: 2px;
color: #ffffff;
padding: 1px 2px;
margin-right: 4px;
}
.icon-answer {
width: 14px;
height: 14px;
font-size: 12px;
background: linear-gradient(108deg, #4f7bf6 0%, #3d6ced 60%, #3162e6 100%);
border-radius: 2px;
color: #ffffff;
padding: 1px 2px;
margin-right: 4px;
}
.p-b-6 {
padding-bottom: 6px;
}
.wechat-box .wechat-name {
position: absolute;
top: 50px;
left: 58px;
width: 138px;
color: #282829;
z-index: 99;
text-align: center;
}
</style>
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<glsx-combi-form class="edit-form-container" ref="editFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <glsx-combi-form class="edit-form-container" ref="editFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<div slot="activityImg" class="edit-tips m-t-8">展示在首页的活动详情页</div> <div slot="activityImg" class="edit-tips m-t-8">展示在首页的活动详情页</div>
<template slot="activityTimeHtml" slot-scope="scope"> <template slot="activityTimeHtml" slot-scope="scope">
<el-date-picker style="width: 474px" v-model="editForm.activityTime" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :picker-options="pickerOptions" :default-time="['00:00:00', '23:59:59']" :disabled="isDisabled" @change="e => handleTimeChange(e, scope.scope)"></el-date-picker> <el-date-picker v-model="editForm.activityTime" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :picker-options="pickerOptions" :default-time="['00:00:00', '23:59:59']" :disabled="isDisabled" @change="e => handleTimeChange(e, scope.scope)"></el-date-picker>
</template> </template>
<div slot="goodsHtml"> <div slot="goodsHtml">
<el-button type="default" class="default-blue-btn el-icon-plus" v-if="apear != 'see'" @click="handleRelateProClose">选择商品</el-button> <el-button type="default" class="default-blue-btn el-icon-plus" v-if="apear != 'see'" @click="handleRelateProClose">选择商品</el-button>
...@@ -15,11 +15,11 @@ ...@@ -15,11 +15,11 @@
<img class="img-60" :src="selectedProInfo.goodsImage" /> <img class="img-60" :src="selectedProInfo.goodsImage" />
&nbsp;&nbsp;&nbsp; 零售价 {{ (selectedProInfo.retailPrice / 100).toFixed(2) }}元 &nbsp;&nbsp;&nbsp; 商品库存 {{ selectedProInfo.goodsStock }}件 &nbsp;&nbsp;&nbsp; 零售价 {{ (selectedProInfo.retailPrice / 100).toFixed(2) }}元 &nbsp;&nbsp;&nbsp; 商品库存 {{ selectedProInfo.goodsStock }}件
</p> </p>
<el-form-item label="设置秒杀价" prop="activityPrice"> <el-form-item label="设置秒杀价/元:" prop="activityPrice">
<el-input v-model="editForm.activityPrice" style="width: 150px" :disabled="isDisabled"><span slot="append">元</span></el-input> <el-input v-model="editForm.activityPrice" style="width: 150px" :disabled="isDisabled"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="活动库存" prop="goodsStock"> <el-form-item label="活动库存/件:" prop="goodsStock">
<el-input v-model="editForm.goodsStock" style="width: 150px" :disabled="isDisabled"><span slot="append">件</span></el-input> <el-input v-model="editForm.goodsStock" style="width: 150px" :disabled="isDisabled"></el-input>
</el-form-item> </el-form-item>
</div> </div>
</div> </div>
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
<p v-if="editForm[scope.scope.name] == 2" id="limitPurchaseNumber" style="color: #333333;"> <p v-if="editForm[scope.scope.name] == 2" id="limitPurchaseNumber" style="color: #333333;">
每人限购 每人限购
<el-form-item prop="limitPurchaseNumber"> <el-form-item prop="limitPurchaseNumber">
<el-input v-model="editForm.limitPurchaseNumber" placeholder="请输入限购次数" :disabled="isDisabled"></el-input> <el-input style="width: 150px;" v-model="editForm.limitPurchaseNumber" placeholder="请输入限购次数" :disabled="isDisabled"></el-input>
</el-form-item> </el-form-item>
件 件
</p> </p>
...@@ -200,7 +200,6 @@ export default { ...@@ -200,7 +200,6 @@ export default {
{ {
label: '活动名称', label: '活动名称',
name: 'activityName', name: 'activityName',
width: '474px',
type: 'input', type: 'input',
maxlength: 20, maxlength: 20,
isDisabled: false isDisabled: false
...@@ -226,7 +225,6 @@ export default { ...@@ -226,7 +225,6 @@ export default {
{ {
label: '活动宣传语', label: '活动宣传语',
name: 'promotion', name: 'promotion',
width: '474px',
type: 'input', type: 'input',
maxlength: 20, maxlength: 20,
isDisabled: false isDisabled: false
......
<!-- 众筹活动 --> <!-- 众筹活动 -->
<template> <template>
<div class="edit-share marketing edit-box edit-activity" v-loading="loading"> <div v-loading="loading" class="edit-activity">
<div class="container edit-container"> <!-- 导航 -->
<el-tabs :tab-position="tabPosition" v-model="tabName" class="nav-tabs" @tab-click="whereToGo(tabName)">
<el-tab-pane label="基本信息" name="basic"></el-tab-pane>
<el-tab-pane label="活动配置" name="config"></el-tab-pane>
<el-tab-pane name="activityServices">
<span class="p-l-23" slot="label">服务说明</span>
</el-tab-pane>
<el-tab-pane name="activityCommoditys">
<span class="p-l-23" slot="label">商品答疑</span>
</el-tab-pane>
<el-tab-pane name="activityExperienceDTOs">
<span class="p-l-23" slot="label">玩家心得</span>
</el-tab-pane>
</el-tabs>
<div class="marketing edit-box">
<!-- 基本信息 --> <!-- 基本信息 -->
<p class="edit-title">基本信息</p> <div class="container edit-container" style="min-height: 520px !important;">
<glsx-combi-form class="edit-form-container" ref="editFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <p class="edit-title" id="basic">基本信息</p>
<div slot="activityImg" class="edit-tips m-t-8">展示在首页的活动详情页</div> <glsx-combi-form class="edit-form-container" ref="editFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<template slot="activityTimeHtml" slot-scope="scope"> <div slot="activityImg" class="edit-tips m-t-8">展示在首页的活动详情页</div>
<el-date-picker style="width: 474px" v-model="editForm.activityTime" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :picker-options="pickerOptions" :default-time="['00:00:00', '23:59:59']" :disabled="isDisabled" @change="e => handleTimeChange(e, scope.scope)"></el-date-picker> <template slot="activityTimeHtml" slot-scope="scope">
</template> <el-date-picker v-model="editForm.activityTime" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :default-time="['00:00:00', '23:59:59']" :disabled="isDisabled" @change="e => handleTimeChange(e, scope.scope)"></el-date-picker>
<div slot="goodsHtml"> </template>
<el-button type="default" class="el-icon-plus" v-if="!isDisabled" @click="handleRelateProClose">选择商品</el-button> <div slot="goodsHtml">
<div v-if="selectedProInfo.id && !specificationDetailList.length" style="margin-top: 10px"> <el-button type="default" class="el-icon-plus" v-if="!isDisabled" @click="handleRelateProClose">选择商品</el-button>
<p> <div v-if="selectedProInfo.id && !specificationDetailList.length" style="margin-top: 10px">
<img class="img-60" :src="selectedProInfo.goodsImage" /> <p>
&nbsp;&nbsp;&nbsp; 零售价 {{ (selectedProInfo.retailPrice / 100).toFixed(2) }}元 &nbsp;&nbsp;&nbsp; 商品库存 {{ selectedProInfo.goodsStock }}件 <img class="img-60" :src="selectedProInfo.goodsImage" />
</p> &nbsp;&nbsp;&nbsp; 零售价 {{ (selectedProInfo.retailPrice / 100).toFixed(2) }}元 &nbsp;&nbsp;&nbsp; 商品库存 {{ selectedProInfo.goodsStock }}件
<el-form-item label="设置秒杀价" prop="activityPrice" id="activityPrice"> </p>
<el-input v-model="editForm.activityPrice" style="width: 150px" :disabled="isDisabled"><span slot="append">元</span></el-input> <el-form-item label="设置秒杀价:" prop="activityPrice" id="activityPrice">
</el-form-item> <el-input v-model="editForm.activityPrice" style="width: 150px" :disabled="isDisabled"><span slot="append">元</span></el-input>
<el-form-item label="活动库存" prop="goodsStock" id="goodsStock"> </el-form-item>
<el-input v-model="editForm.goodsStock" style="width: 150px" :disabled="isDisabled"><span slot="append">件</span></el-input> <el-form-item label="活动库存:" prop="goodsStock" id="goodsStock">
</el-form-item> <el-input v-model="editForm.goodsStock" style="width: 150px" :disabled="isDisabled"><span slot="append">件</span></el-input>
</el-form-item>
</div>
</div> </div>
</div> <div slot="specificationsHtml" v-if="specificationDetailList.length" class="flex" style="min-width: 600px" id="specificationDetailList">
<div slot="specificationsHtml" v-if="specificationDetailList.length" class="flex" style="min-width: 600px" id="specificationDetailList"> <div style="width: calc(100%)">
<div style="width: calc(100%)"> <table class="table-spesc" style="width: calc(100%)">
<table class="table-spesc" style="width: calc(100%)"> <tbody>
<tbody> <tr>
<tr> <td :style="{ width: specsWidth }" v-for="(subItem, subIndex) in specificationDetailList" :key="subIndex">{{ subItem.specificationName }}</td>
<td :style="{ width: specsWidth }" v-for="(subItem, subIndex) in specificationDetailList" :key="subIndex">{{ subItem.specificationName }}</td> <td :style="{ width: specsWidth }">零售价(元)</td>
<td :style="{ width: specsWidth }">零售价(元)</td> <td :style="{ width: specsWidth }">库存</td>
<td :style="{ width: specsWidth }">库存</td> <td :style="{ width: specsWidth }">设置秒杀价</td>
<td :style="{ width: specsWidth }">设置秒杀价</td> <td :style="{ width: specsWidth }">活动库存</td>
<td :style="{ width: specsWidth }">活动库存</td> </tr>
</tr> </tbody>
</tbody> </table>
</table> <table class="table-spesc" style="max-height: 400px">
<table class="table-spesc" style="max-height: 400px"> <tbody>
<tbody> <tr style="border-bottom: 1px solid rgb(235, 235, 235)" v-for="(item, index) in nameToValSpecsList" :key="index">
<tr style="border-bottom: 1px solid rgb(235, 235, 235)" v-for="(item, index) in nameToValSpecsList" :key="index"> <td :style="{ width: specsWidth }" v-for="(n, idx) in item.specsValueList" :key="idx">{{ n }}</td>
<td :style="{ width: specsWidth }" v-for="(n, idx) in item.specsValueList" :key="idx">{{ n }}</td> <td :style="{ width: specsWidth }">{{ item.retailPrice }}元</td>
<td :style="{ width: specsWidth }">{{ item.retailPrice }}元</td> <td :style="{ width: specsWidth }">{{ item.stock }}件</td>
<td :style="{ width: specsWidth }">{{ item.stock }}件</td> <td :style="{ width: specsWidth }">
<td :style="{ width: specsWidth }"> <el-input :disabled="isDisabled" placeholder="秒杀价" style="width: 90%" v-model="item.activityPrice" @input="item.activityPrice = activityPrice_input($event, item.retailPrice)"></el-input>
<el-input :disabled="isDisabled" placeholder="秒杀价" style="width: 90%" v-model="item.activityPrice" @input="item.activityPrice = activityPrice_input($event, item.retailPrice)"></el-input> </td>
</td> <td :style="{ width: specsWidth }">
<td :style="{ width: specsWidth }"> <el-input :disabled="isDisabled" placeholder="活动库存" style="width: 90%" v-model="item.goodsStock" @input="item.goodsStock = goodsStock_input($event, item.stock)"></el-input>
<el-input :disabled="isDisabled" placeholder="活动库存" style="width: 90%" v-model="item.goodsStock" @input="item.goodsStock = goodsStock_input($event, item.stock)"></el-input> </td>
</td> </tr>
</tr> </tbody>
</tbody> </table>
</table> </div>
</div> </div>
</div> <template slot="limitPurchaseFlag" slot-scope="scope">
<template slot="limitPurchaseFlag" slot-scope="scope"> <el-radio-group v-model="editForm[scope.scope.name]" @change="handleIsLimit">
<el-radio-group v-model="editForm[scope.scope.name]" @change="handleIsLimit"> <el-radio v-for="(item, index) in scope.scope.optionList" :key="index" :label="item[scope.scope.optionId]" :disabled="isDisabled">{{ item[scope.scope.optionLabel] }}</el-radio>
<el-radio v-for="(item, index) in scope.scope.optionList" :key="index" :label="item[scope.scope.optionId]" :disabled="isDisabled">{{ item[scope.scope.optionLabel] }}</el-radio> </el-radio-group>
</el-radio-group> <p v-if="editForm[scope.scope.name] == 2" id="limitPurchaseNumber" style="color: #333333;">
<p v-if="editForm[scope.scope.name] == 2" id="limitPurchaseNumber" style="color: #333333;"> 每人限购
每人限购 <el-form-item prop="limitPurchaseNumber">
<el-form-item prop="limitPurchaseNumber"> <el-input v-model="editForm.limitPurchaseNumber" placeholder="请输入限购次数" :disabled="isDisabled"></el-input>
<el-input v-model="editForm.limitPurchaseNumber" placeholder="请输入限购次数" :disabled="isDisabled"></el-input> </el-form-item>
</el-form-item> 件
件 </p>
</p> </template>
</template> </glsx-combi-form>
</glsx-combi-form> </div>
<!-- 活动配置 --> <!-- 活动配置 -->
<p class="edit-title">活动配置</p> <div class="container edit-container crowd-config">
<glsx-combi-form class="edit-form-container" ref="configEditFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="configEditFormData" :formRules="editRule"> <p class="edit-title" id="config">活动配置</p>
<template slot="customerServiceFlag" slot-scope="scope"> <glsx-combi-form class="edit-form-container" ref="configEditFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="configEditFormData" :formRules="editRule">
<el-radio-group v-model="editForm[scope.scope.name]"> <template slot="customerServiceFlag" slot-scope="scope">
<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 v-model="editForm[scope.scope.name]">
</el-radio-group> <el-radio v-for="(item, index) in scope.scope.optionList" :key="index" :label="item[scope.scope.optionId]">{{ item[scope.scope.optionLabel] }}</el-radio>
<div class="customer-service" v-if="editForm[scope.scope.name] == 2" id="customerServiceFlag"> </el-radio-group>
<glsx-combi-form class="edit-form-container" ref="serviceEditFormRef" :isEdit="true" :isBlock="false" :formRef="editChildRef" :formObj="editForm" :formData="serviceEditFormData" :formRules="editRule"></glsx-combi-form> <div class="customer-service" v-if="editForm[scope.scope.name] == 2" id="customerServiceFlag">
</div> <glsx-combi-form class="edit-form-container" ref="customerEditFormRef" :isEdit="true" :isBlock="false" :formRef="editChildRef" :formObj="editForm" :formData="customerEditFormData" :formRules="editRule"></glsx-combi-form>
</template> </div>
<template slot="activityMusic" slot-scope="scope"> </template>
<div class="flex"> <template slot="activityMusic" slot-scope="scope">
<div class="music-box flex-center" v-for="(item, index) in musicList" :key="index" @click="handleMusicChange(index)"> <div class="flex">
<div class="music-icon" @click.stop="handleMusic(item, index)"> <div class="music-box flex-center" v-for="(item, index) in musicList" :key="index" @click="handleMusicChange(index)">
<div :class="[index != playObj.idx ? 'icon-start' : 'icon-stop']"></div> <div class="music-icon" @click.stop="handleMusic(item, index)">
<img src="@/assets/seckillActivity/icon-music-default.png" /> <div :class="[index != playObj.idx ? 'icon-start' : 'icon-stop']"></div>
</div> <img src="@/assets/seckillActivity/icon-music-default.png" />
<div class="music-name"> </div>
<p class="ellipsis-1" style="max-width: 90%;">{{ item.name }}</p> <div class="music-name">
.mp3 <p class="ellipsis-1" style="max-width: 90%;">{{ item.name }}</p>
.mp3
</div>
<img v-show="item.isCheck" :class="{ 'icon-check': item.isCheck }" src="@/assets/seckillActivity/icon-check.png" />
</div> </div>
<img v-show="item.isCheck" :class="{ 'icon-check': item.isCheck }" src="@/assets/seckillActivity/icon-check.png" />
</div> </div>
</div> <el-upload class="m-t-10" action="" accept="audio/mp3, audio/m4a" :show-file-list="false" :http-request="handleMusicUpload" :before-upload="e => handleMusicBeforeUpload(e, scope.scope)" :file-list="fileList">
<el-upload class="m-t-10" action="" accept="audio/mp3, audio/m4a" :show-file-list="false" :http-request="handleMusicUpload" :before-upload="e => handleMusicBeforeUpload(e, scope.scope)" :file-list="fileList"> <el-button class="el-icon-plus" size="small" type="default">背景音乐</el-button>
<el-button class="el-icon-plus" size="small" type="default">背景音乐</el-button> </el-upload>
</el-upload> <audio v-if="playObj.src" style="display: none;" id="music-audio" controls>
<audio v-if="playObj.src" style="display: none;" id="music-audio" controls> <source type="audio/mpeg" :src="playObj.src" />
<source type="audio/mpeg" :src="playObj.src" /> </audio>
</audio> <!-- <div v-if="editForm[scope.scope.name]" class="flex">
<!-- <div v-if="editForm[scope.scope.name]" class="flex">
<audio controls> <audio controls>
<source :src="editForm[scope.scope.name]" type="audio/mpeg" /> <source :src="editForm[scope.scope.name]" type="audio/mpeg" />
</audio> </audio>
<el-button class="describe-delete" icon="el-icon-delete" type="text" @click="handleMusicDelete(scope.scope)"></el-button> <el-button class="describe-delete" icon="el-icon-delete" type="text" @click="handleMusicDelete(scope.scope)"></el-button>
</div> --> </div> -->
</template> </template>
<template slot="fictitious"> <template slot="fictitious">
<div class="fictitious" id="fictitious"> <div class="fictitious" id="fictitious">
<el-form-item label="参团:" prop="fictitiousGroupQuantity" labelWidth="60px"> <el-form-item label="参团:" prop="fictitiousGroupQuantity" labelWidth="60px">
<el-input v-model="editForm.fictitiousGroupQuantity" style="width: 90px" maxlength="50" placeholder="参团人数"></el-input> <el-input v-model="editForm.fictitiousGroupQuantity" style="width: 90px" maxlength="50" placeholder="参团人数"></el-input>
</el-form-item> </el-form-item>
<el-form-item id="fictitiousLadderQuantity" label="阶梯人数:" prop="fictitiousLadderQuantity" labelWidth="90px"> <el-form-item id="fictitiousLadderQuantity" label="阶梯人数:" prop="fictitiousLadderQuantity" labelWidth="90px">
<el-input v-model="editForm.fictitiousLadderQuantity" style="width: 90px" maxlength="50" placeholder="阶梯人数"></el-input> <el-input v-model="editForm.fictitiousLadderQuantity" style="width: 90px" maxlength="50" placeholder="阶梯人数"></el-input>
</el-form-item> </el-form-item>
<el-form-item id="fictitiousViewQuantity" label="浏览:" prop="fictitiousViewQuantity" labelWidth="60px"> <el-form-item id="fictitiousViewQuantity" label="浏览:" prop="fictitiousViewQuantity" labelWidth="60px">
<el-input v-model="editForm.fictitiousViewQuantity" style="width: 90px" maxlength="50" placeholder="浏览人数"></el-input> <el-input v-model="editForm.fictitiousViewQuantity" style="width: 90px" maxlength="50" placeholder="浏览人数"></el-input>
</el-form-item> </el-form-item>
</div> </div>
</template> </template>
<div slot="activityBigImg" class="edit-tips m-t-8">建议尺寸750*1258</div> <div slot="activityBigImg" class="edit-tips m-t-8">建议尺寸750*1258</div>
<div slot="activityVideos" class="edit-tips m-t-8">最多上传6个视频</div> <div slot="activityVideos" class="edit-tips m-t-8">最多上传6个视频</div>
<div slot="posterImg" class="edit-tips m-t-8">建议尺寸640*1008</div> <div slot="posterImg" class="edit-tips m-t-8">建议尺寸640*1008</div>
<div class="form-describe-box" slot="formDescribe"> <div class="form-describe-box" slot="formDescribe">
<el-checkbox-group v-model="editForm.formDescribeCheck"> <el-checkbox-group v-model="editForm.formDescribeCheck">
<el-checkbox v-for="(item, index) in formDescribeCheckList" :label="item.value" :key="index">{{ item.label }}</el-checkbox> <el-checkbox v-for="(item, index) in formDescribeCheckList" :label="item.value" :key="index">{{ item.label }}</el-checkbox>
</el-checkbox-group> </el-checkbox-group>
<div v-for="(item, index) in formDescribeList" :key="index" class="form-describe flex-default"> <div v-for="(item, index) in formDescribeList" :key="index" class="form-describe flex-default">
<el-input class="describe-input" v-model="item.value" placeholder="请输入" maxlength="20"></el-input> <el-input class="describe-input" v-model="item.value" placeholder="请输入" maxlength="20"></el-input>
<p class="describe-delete"> <p class="describe-delete">
<img v-show="!(index == 0 && formDescribeList.length == 1)" @click="handleDescribeDelete(index)" src="@/assets/icon-delete.png" /> <img v-show="!(index == 0 && formDescribeList.length == 1)" @click="handleDescribeDelete(index)" src="@/assets/icon-delete.png" />
</p> </p>
</div>
<el-button class="describe-btn" v-show="formDescribeList.length < describeNum" :size="size" type="text" @click="handleDescribeAdd">
<img class="icon-add" src="@/assets/seckillActivity/icon-add.png" />
新增表单
</el-button>
</div>
</glsx-combi-form>
</div>
<div class="wechat-box">
<img class="w-100-percent" src="@/assets/seckillActivity/phone.png" />
<div class="wechat-back">
<p class="wechat-name one-line-ellipsis">{{ editForm.activityName }}</p>
<img class="wechat-head" src="@/assets/seckillActivity/crowd-head.png" />
<img class="icon-server" src="@/assets/seckillActivity/icon-server.png" />
<div class="wechat-inner-box">
<div class="wechat-banner-img">
<img class="icon-music" src="@/assets/seckillActivity/icon-music.png" />
<img :src="editForm.activityBigImg || require('@/assets/seckillActivity/icon-default.png')" />
<img class="wechat-customer" src="@/assets/seckillActivity/crowd-customer.png" />
<div class="w-100-percent txt-center">
<video v-if="editForm.activityVideoList.length" class="wechat-video" controls>
<source :src="editForm.activityVideoList[0]" type="video/mp4" />
</video>
</div> </div>
<div class="wechat-block"> <el-button class="btn-basic" v-show="formDescribeList.length < describeNum" :size="size" type="text" @click="handleDescribeAdd">
<p class="wechat-block-title">活动举办方</p> <img class="icon-add" src="@/assets/seckillActivity/icon-add.png" />
<div class="flex-center"> 新增表单
<div> </el-button>
<p class="m-b-10">{{ editForm.sponsorName }}</p> </div>
<p class="m-b-10 wechat-sub-addr">{{ editForm.activityAddressDetailName }}</p> <!-- 服务说明 -->
<p class="wechat-time" v-if="editForm.activityTime && editForm.activityTime.length">活动时间:{{ editForm.activityTime[0].split(' ')[0] }}-{{ editForm.activityTime[1].split(' ')[0] }}</p> <div slot="activityServices" id="activityServices" class="flex-default">
<span class="custom-label arrow" slot="label" @click="handleArrow('activityServices')" :style="{ width: defaultLabelWidth }">
<i :class="[arrowFlagObj.activityServices == 'open' ? 'el-icon-caret-bottom' : 'el-icon-caret-right']"></i>
服务说明:
</span>
<div class="form-show-box">
<div :class="['btn-box', arrowFlagObj.activityServices == 'open' && editForm.activityServices.length ? 'line' : '']">
<el-button :class="[editForm.activityServices.length < 9 ? 'btn-basic' : 'btn-disable']" :size="size" type="text" @click="handleAddItem('services', 'activityServices', 9)">
<img class="icon-add" src="@/assets/seckillActivity/icon-add.png" />
新增一项
</el-button>
</div>
<div :class="['form-show-block', arrowFlagObj.activityServices == 'close' ? 'form-close' : 'form-open']">
<div v-for="(item, index) in editForm.activityServices" :key="index" :class="['form-show-item', editForm.activityServices.length > index + 1 ? 'line' : '']">
<glsx-combi-form class="p-t-20" ref="serviceEditFormRef" :formRef="editChildRef" :isEdit="true" :isBlock="true" :formObj="item" :formData="serviceEditFormData" :formRules="serviceEditRule"></glsx-combi-form>
<el-button :class="['btn-basic', 'btn-delete', index == editForm.activityServices.length - 1 ? 'last-btn-delete' : '']" :size="size" type="text" @click="handleDeleteItem('services', 'activityServices', index)">
<img class="icon-add" src="@/assets/icon-delete.png" />
</el-button>
</div> </div>
<img class="icon-addr" src="@/assets/seckillActivity/icon-addr.png" />
</div> </div>
</div> </div>
</div>
<div class="wechat-block"> <!-- 商品答疑 -->
<p class="wechat-block-title">{{ countDownObj.typeTxt }}</p> <div slot="activityCommoditys" id="activityCommoditys" class="flex-default">
<p v-if="countDownObj.activityStatus != 3" class="wechat-count-down"> <span class="custom-label arrow" slot="label" @click="handleArrow('activityCommoditys')" :style="{ width: defaultLabelWidth }">
<span v-if="editForm.activityTime && editForm.activityTime.length">{{ editForm.activityTime[0].split(' ')[0].split('-')[2] }}</span> <i :class="[arrowFlagObj.activityCommoditys == 'open' ? 'el-icon-caret-bottom' : 'el-icon-caret-right']"></i>
日开始活动,还差 商品答疑:
<span class="wechat-txt">{{ countDownObj.d }}</span>天 </span>
<span class="wechat-txt">{{ countDownObj.h }}</span>时 <div class="form-show-box">
<span class="wechat-txt">{{ countDownObj.m }}</span>分 <div :class="['btn-box', arrowFlagObj.activityCommoditys == 'open' && editForm.activityCommoditys.length ? 'line' : '']">
<span class="wechat-txt">{{ countDownObj.s }}</span>秒 <el-button :class="[editForm.activityCommoditys.length < 9 ? 'btn-basic' : 'btn-disable']" :size="size" type="text" @click="handleAddItem('commoditys', 'activityCommoditys', 9)">
</p> <img class="icon-add" src="@/assets/seckillActivity/icon-add.png" />
<img v-else class="count-down-img" src="@/assets/seckillActivity/count-down.png" /> 新增一项
</el-button>
</div>
<div :class="['form-show-block', arrowFlagObj.activityCommoditys == 'close' ? 'form-close' : 'form-open']">
<div v-for="(item, index) in editForm.activityCommoditys" :key="index" :class="['form-show-item', editForm.activityCommoditys.length > index + 1 ? 'line' : '']">
<glsx-combi-form class="p-t-20" ref="commoditysEditFormRef" :formRef="editChildRef" :isEdit="true" :isBlock="true" :formObj="item" :formData="commoditysEditFormData" :formRules="commoditysEditRule"></glsx-combi-form>
<el-button :class="['btn-basic', 'btn-delete', index == editForm.activityCommoditys.length - 1 ? 'last-btn-delete' : '']" :size="size" type="text" @click="handleDeleteItem('commoditys', 'activityCommoditys', index)">
<img class="icon-add" src="@/assets/icon-delete.png" />
</el-button>
</div>
</div>
</div> </div>
<div class="w-100-percent txt-center"> </div>
<img class="crowd-jdt" src="@/assets/seckillActivity/crowd-jdt.png" /> <!-- 玩家心得 -->
<div slot="activityExperienceDTOs" id="activityExperienceDTOs" class="flex-default">
<span class="custom-label arrow" slot="label" @click="handleArrow('activityExperienceDTOs')" :style="{ width: defaultLabelWidth }">
<i :class="[arrowFlagObj.activityExperienceDTOs == 'open' ? 'el-icon-caret-bottom' : 'el-icon-caret-right']"></i>
玩家心得:
</span>
<div class="form-show-box">
<div :class="['btn-box', arrowFlagObj.activityExperienceDTOs == 'open' && editForm.activityExperienceDTOs.length ? 'line' : '']">
<el-button :class="[editForm.activityExperienceDTOs.length < 9 ? 'btn-basic' : 'btn-disable']" :size="size" type="text" @click="handleAddItem('experiences', 'activityExperienceDTOs', 9)">
<img class="icon-add" src="@/assets/seckillActivity/icon-add.png" />
新增一项
</el-button>
</div>
<div :class="['form-show-block', arrowFlagObj.activityExperienceDTOs == 'close' ? 'form-close' : 'form-open']">
<div v-for="(item, index) in editForm.activityExperienceDTOs" :key="index" :class="['form-show-item', editForm.activityExperienceDTOs.length > index + 1 ? 'line' : '']">
<div class="head-box">
<img class="icon-head" src="@/assets/seckillActivity/icon-default-head.png" />
<span>虚拟人物{{ index + 1 }}</span>
</div>
<glsx-combi-form class="p-t-20" :formRef="editChildRef" :isEdit="true" :isBlock="true" :formObj="item" :formData="experiencesEditFormData" :formRules="editRule">
<div slot="activityExperienceImgs" class="edit-tips m-t-8">建议尺寸:图片大小不超过5m,最多可添加9张图片</div>
</glsx-combi-form>
<el-button :class="['btn-basic', 'btn-delete', index == editForm.activityExperienceDTOs.length - 1 ? 'last-btn-delete' : '']" :size="size" type="text" @click="handleDeleteItem('experiences', 'activityExperienceDTOs', index)">
<img class="icon-add" src="@/assets/icon-delete.png" />
</el-button>
</div>
</div>
</div> </div>
<div v-html="editForm.activityDetail"></div>
</div> </div>
</div> </glsx-combi-form>
<img class="wechat-footer" src="@/assets/seckillActivity/crowd-footer.png" />
</div> </div>
<GLFooter>
<el-button @click="handleCancel" size="medium">{{ routeInfo.addOrEdit != 'detail' ? '取消' : '返回' }}</el-button>
<el-button @click="handleWechat" size="medium">预览</el-button>
<el-button v-if="routeInfo.addOrEdit != 'detail'" type="primary" @click="handleConfirm" size="medium" :loading="loading">提交</el-button>
</GLFooter>
<!-- 展示 -->
<GLDialog bigTitle="预览" mode="big" :visible.sync="wechatVisible" @onOk="handleWechat" @onCancel="handleWechat">
<crowdEditWechat ref="crowdEditWechat" :editForm="editForm" :countDownObj="countDownObj"></crowdEditWechat>
</GLDialog>
<select-single-pro-dialog v-if="isSingleSelectVisible" :isSingleSelectVisible="isSingleSelectVisible" :selectedProInfo="selectedProInfo" @handleSingleSelectConfirm="handleSingleSelectConfirm" @handleSingleSelectClose="handleSingleSelectClose(true)"></select-single-pro-dialog>
</div> </div>
<GLFooter>
<el-button @click="handleCancel" size="medium">{{ routeInfo.addOrEdit != 'detail' ? '取消' : '返回' }}</el-button>
<el-button v-if="routeInfo.addOrEdit != 'detail'" type="primary" @click="handleConfirm" size="medium" :loading="loading">提交</el-button>
</GLFooter>
<select-single-pro-dialog v-if="isSingleSelectVisible" :isSingleSelectVisible="isSingleSelectVisible" :selectedProInfo="selectedProInfo" @handleSingleSelectConfirm="handleSingleSelectConfirm" @handleSingleSelectClose="handleSingleSelectClose(true)"></select-single-pro-dialog>
</div> </div>
</template> </template>
<script> <script>
import { limitPrice } from '@/common/constant' import { limitPrice } from '@/common/constant'
import crowdEditWechat from './crowdEditWechat.vue'
export default { export default {
name: 'editActivity', name: 'editActivity',
components: {
crowdEditWechat
},
data() { data() {
var validatorPhone = function (rule, value, callback) { var validatorPhone = function (rule, value, callback) {
if (value && !/^(0|86|17951)?(13[0-9]|15[0123456789]|17[678]|18[0-9]|14[57])[0-9]{8}$/.test(value)) { if (value && !/^(0|86|17951)?(13[0-9]|15[0123456789]|17[678]|18[0-9]|14[57])[0-9]{8}$/.test(value)) {
...@@ -212,12 +265,12 @@ export default { ...@@ -212,12 +265,12 @@ export default {
editChildRef: 'editChildRef', editChildRef: 'editChildRef',
loading: false, loading: false,
userInfo: {}, userInfo: {},
pickerOptions: { // pickerOptions: {
disabledDate(v) { // disabledDate(v) {
//禁用当前之前的日期 // //禁用当前之前的日期
return v.getTime() < new Date().getTime() - 86400000 // return v.getTime() < new Date().getTime() - 86400000
} // }
}, // },
routeInfo: { routeInfo: {
// 1-新增;2-编辑;3-查看 // 1-新增;2-编辑;3-查看
// add-新增;edit-编辑;detail-详情 // add-新增;edit-编辑;detail-详情
...@@ -226,13 +279,27 @@ export default { ...@@ -226,13 +279,27 @@ export default {
activityStatus: '' activityStatus: ''
}, },
editStatus: false, editStatus: false,
// 导航
tabPosition: 'right',
tabName: 'basic',
/* eslint-disable */ /* eslint-disable */
reg: { reg: {
priceReg: /^\d[\d\.]*$/, priceReg: /^\d[\d\.]*$/,
numReg: /^[1-9]\d*$/ numReg: /^[1-9]\d*$/
}, },
/* eslint-enable */ /* eslint-enable */
// 倒计时
countDownObj: {
typeTxt: '距离活动开始',
activityStatus: 1,
d: '',
h: '',
m: '',
s: ''
},
isDisabled: false, isDisabled: false,
// 预览
wechatVisible: false,
// 商品选择 // 商品选择
isSingleSelectVisible: false, isSingleSelectVisible: false,
selectedProInfo: {}, selectedProInfo: {},
...@@ -274,7 +341,10 @@ export default { ...@@ -274,7 +341,10 @@ export default {
// 1-否,2-是 // 1-否,2-是
selectCarNumberFlag: 2, selectCarNumberFlag: 2,
selectVehicleTypeFlag: 2, selectVehicleTypeFlag: 2,
formDescribeCheck: ['selectCarNumberFlag', 'selectVehicleTypeFlag'] formDescribeCheck: ['selectCarNumberFlag', 'selectVehicleTypeFlag'],
activityServices: [],
activityCommoditys: [],
activityExperienceDTOs: []
// formDescribeFirst: '', // formDescribeFirst: '',
// formDescribeSecond: '', // formDescribeSecond: '',
// formDescribeThird: '' // formDescribeThird: ''
...@@ -372,22 +442,12 @@ export default { ...@@ -372,22 +442,12 @@ export default {
value: '' value: ''
} }
], ],
// 倒计时
countDownObj: {
typeTxt: '距离活动开始',
activityStatus: 1,
d: '',
h: '',
m: '',
s: ''
},
fileList: [], fileList: [],
// 基本信息 // 基本信息
editFormData: [ editFormData: [
{ {
label: '活动名称', label: '活动名称',
name: 'activityName', name: 'activityName',
width: '474px',
type: 'input', type: 'input',
maxlength: 20, maxlength: 20,
tips: '如XX店车主关怀活动', tips: '如XX店车主关怀活动',
...@@ -405,16 +465,21 @@ export default { ...@@ -405,16 +465,21 @@ export default {
handleUpload: (e, file, targetItem) => { handleUpload: (e, file, targetItem) => {
const imgFile = e.target.result const imgFile = e.target.result
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1] const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1]
this.$apis.common.uploadImgApi({ file: base64, fileType: 'image' }).then(res => { this.loading = true
this.editForm[targetItem.name] = res this.$apis.common
this.$refs.editFormRef.$refs[this.editChildRef].validateField(targetItem.name) .uploadImgApi({ file: base64, fileType: 'image' })
}) .then(res => {
this.editForm[targetItem.name] = res
this.$refs.editFormRef.$refs[this.editChildRef].validateField(targetItem.name)
})
.finally(() => {
this.loading = false
})
} }
}, },
{ {
label: '活动宣传语', label: '活动宣传语',
name: 'promotion', name: 'promotion',
width: '474px',
type: 'input', type: 'input',
maxlength: 20, maxlength: 20,
tips: '比如车主关怀,0元秒杀', tips: '比如车主关怀,0元秒杀',
...@@ -457,7 +522,7 @@ export default { ...@@ -457,7 +522,7 @@ export default {
} }
], ],
// 客服设置 // 客服设置
serviceEditFormData: [ customerEditFormData: [
{ {
label: '客服名称', label: '客服名称',
name: 'customerServiceName', name: 'customerServiceName',
...@@ -482,10 +547,120 @@ export default { ...@@ -482,10 +547,120 @@ export default {
handleUpload: (e, file, targetItem) => { handleUpload: (e, file, targetItem) => {
const imgFile = e.target.result const imgFile = e.target.result
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1] const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1]
this.$apis.common.uploadImgApi({ file: base64, fileType: 'image' }).then(res => { this.loading = true
this.editForm[targetItem.name] = res this.$apis.common
this.$refs.editFormRef.$refs[this.editChildRef].validateField(targetItem.name) .uploadImgApi({ file: base64, fileType: 'image' })
}) .then(res => {
this.editForm[targetItem.name] = res
this.$refs.editFormRef.$refs[this.editChildRef].validateField(targetItem.name)
})
.finally(() => {
this.loading = false
})
}
}
],
// 服务说明Obj
servicesObj: {
title: '',
content: ''
},
serviceEditRule: {
title: [{ required: true, message: '请输入标题', trigger: 'change' }],
content: [{ required: true, message: '请输入内容', trigger: 'change' }]
},
// 服务说明
serviceEditFormData: [
{
label: '标题',
name: 'title',
type: 'input',
maxlength: 20
},
{
label: '内容',
name: 'content',
type: 'input',
inputType: 'textarea',
rows: 3,
maxlength: 50
}
],
// 商品答疑Obj
commoditysObj: {
question: '',
answer: ''
},
commoditysEditRule: {
question: [{ required: true, message: '请输入问题', trigger: 'change' }],
answer: [{ required: true, message: '请输入答案', trigger: 'change' }]
},
// 商品答疑
commoditysEditFormData: [
{
label: '问题',
name: 'question',
type: 'input',
maxlength: 50
},
{
label: '答案',
name: 'answer',
type: 'input',
inputType: 'textarea',
rows: 3,
maxlength: 80
}
],
// 玩家心得Obj
experiencesObj: {
name: '',
imageUrl: '',
experience: '',
activityExperienceImgs: []
},
// 玩家心得
experiencesEditFormData: [
{
label: '心得内容',
name: 'experience',
type: 'input',
inputType: 'textarea',
rows: 3,
maxlength: 80
},
{
label: '图片',
name: 'activityExperienceImgs',
type: 'upload',
limitSize: 5,
maxPhotoNum: 9,
suffixSlot: 'activityExperienceImgs',
isDisabled: false,
uploadStyle: {
imgWH: {
width: '56px',
height: '56px'
},
fontSize: {
'font-size': '12px'
},
addStyle: {
'font-size': '26px'
}
},
handleUpload: (e, file, targetItem, formObj) => {
const imgFile = e.target.result
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1]
this.loading = true
this.$apis.common
.uploadImgApi({ file: base64, fileType: 'image' })
.then(res => {
this.editForm.activityExperienceDTOs[formObj.idx][targetItem.name].push(res)
})
.finally(() => {
this.loading = false
})
} }
} }
], ],
...@@ -512,6 +687,12 @@ export default { ...@@ -512,6 +687,12 @@ export default {
isCheck: false isCheck: false
} }
], ],
// 服务说明open-展开,close-收起
arrowFlagObj: {
activityServices: 'open',
activityCommoditys: 'open',
activityExperienceDTOs: 'open'
},
// 活动配置 // 活动配置
configEditFormData: [ configEditFormData: [
{ {
...@@ -534,7 +715,6 @@ export default { ...@@ -534,7 +715,6 @@ export default {
{ {
label: '主办方', label: '主办方',
name: 'sponsorName', name: 'sponsorName',
width: '474px',
type: 'input', type: 'input',
maxlength: 100, maxlength: 100,
tips: '默认展示门店名称' tips: '默认展示门店名称'
...@@ -579,6 +759,12 @@ export default { ...@@ -579,6 +759,12 @@ export default {
} }
}, },
{ {
label: '活动分享语',
name: 'activitySharingWords',
type: 'input',
maxlength: 30
},
{
label: '活动视频', label: '活动视频',
name: 'activityVideoList', name: 'activityVideoList',
type: 'upload', type: 'upload',
...@@ -593,6 +779,11 @@ export default { ...@@ -593,6 +779,11 @@ export default {
handleUpload: (e, file, targetItem) => { handleUpload: (e, file, targetItem) => {
const imgFile = e.target.result const imgFile = e.target.result
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1] const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1]
const fileSuffix = file.name.split('.')[file.name.split('.').length - 1]
if (fileSuffix.toLowerCase() != 'mp4') {
this.$message.error('上传视频不是MP4的格式!')
return true
}
this.loading = true this.loading = true
this.$apis.common this.$apis.common
.uploadFundingVideoApi({ file: base64 }) .uploadFundingVideoApi({ file: base64 })
...@@ -624,12 +815,11 @@ export default { ...@@ -624,12 +815,11 @@ export default {
addHtml: 'activityMusic' addHtml: 'activityMusic'
}, },
{ {
label: '预估销量', label: '预估销量/元',
name: 'predictVolume', name: 'predictVolume',
width: '474px',
type: 'input', type: 'input',
append: '元',
maxlength: 20, maxlength: 20,
placeholder: '请输入预估销量',
tips: '用作战报的销量展示' tips: '用作战报的销量展示'
}, },
{ {
...@@ -640,7 +830,6 @@ export default { ...@@ -640,7 +830,6 @@ export default {
{ {
label: '转发标题', label: '转发标题',
name: 'forwardTitle', name: 'forwardTitle',
width: '474px',
type: 'input', type: 'input',
maxlength: 50 maxlength: 50
}, },
...@@ -655,23 +844,45 @@ export default { ...@@ -655,23 +844,45 @@ export default {
handleUpload: (e, file, targetItem) => { handleUpload: (e, file, targetItem) => {
const imgFile = e.target.result const imgFile = e.target.result
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1] const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1]
this.$apis.common.uploadImgApi({ file: base64, fileType: 'image' }).then(res => { this.loading = true
this.editForm[targetItem.name] = res this.$apis.common
this.$refs.configEditFormRef.$refs[this.editChildRef].validateField(targetItem.name) .uploadImgApi({ file: base64, fileType: 'image' })
}) .then(res => {
this.editForm[targetItem.name] = res
this.$refs.configEditFormRef.$refs[this.editChildRef].validateField(targetItem.name)
})
.finally(() => {
this.loading = false
})
} }
}, },
{ {
label: '表单设置', label: '表单设置',
name: 'formDescribe', name: 'formDescribe',
addHtml: 'formDescribe' addHtml: 'formDescribe'
},
{
label: '',
name: 'activityServices',
addHtml: 'activityServices',
labelSlot: 'servicesLabel'
},
{
label: '',
name: 'activityCommoditys',
addHtml: 'activityCommoditys'
},
{
label: '',
name: 'activityExperienceDTOs',
addHtml: 'activityExperienceDTOs'
} }
] ]
} }
}, },
mounted() { mounted() {
this.setMinHeight() 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() : this.getMerchantInfo()
var id = this.routeInfo.id var id = this.routeInfo.id
...@@ -757,6 +968,7 @@ export default { ...@@ -757,6 +968,7 @@ export default {
return i < 10 ? `0${i}` : `${i}` return i < 10 ? `0${i}` : `${i}`
}, },
findCountDownTime() { findCountDownTime() {
let startTime = new Date(this.editForm.activityTime[0]) let startTime = new Date(this.editForm.activityTime[0])
let endTime = new Date(this.editForm.activityTime[1]) let endTime = new Date(this.editForm.activityTime[1])
...@@ -1061,6 +1273,48 @@ export default { ...@@ -1061,6 +1273,48 @@ export default {
}) })
}, },
listAddIdx(list) {
list.forEach((item, index) => {
item.idx = index
})
},
dealItem(attr, formAttr) {
switch (attr) {
case 'services':
break
case 'commoditys':
break
case 'experiences':
this.listAddIdx(this.editForm[formAttr])
break
}
},
// 服务说明,商品答疑,玩家心得
handleAddItem(attr, formAttr, limitNum) {
if (this.editForm[formAttr].length >= limitNum) {
return true
}
this.arrowFlagObj[formAttr] = 'open'
this.editForm[formAttr].push(JSON.parse(JSON.stringify(this[attr + 'Obj'])))
this.dealItem(attr, formAttr)
},
handleDeleteItem(attr, formAttr, idx) {
this.$confirm('是否删除该项?', '删除', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
callback: action => {
if (action == 'confirm') {
this.editForm[formAttr].splice(idx, 1)
this.dealItem(attr, formAttr)
}
}
})
},
getMerchantInfo() { getMerchantInfo() {
this.loading = true this.loading = true
let merchantId = this.$globalState.session.merchantId let merchantId = this.$globalState.session.merchantId
...@@ -1159,6 +1413,13 @@ export default { ...@@ -1159,6 +1413,13 @@ export default {
if (!this.formDescribeList.length) { if (!this.formDescribeList.length) {
this.formDescribeList = [{ value: '' }] this.formDescribeList = [{ value: '' }]
} }
// 玩家心得
if (this.editForm.activityExperienceDTOs.length) {
this.editForm.activityExperienceDTOs.forEach((item, index) => {
item.idx = index
item.activityExperienceImgs = item.activityExperienceImgs.map(item => item.imageUrl)
})
}
this.$nextTick(() => { this.$nextTick(() => {
this.editStatus = false this.editStatus = false
}) })
...@@ -1231,6 +1492,15 @@ export default { ...@@ -1231,6 +1492,15 @@ export default {
return param return param
}, },
// 服务说明
handleArrow(attr) {
this.arrowFlagObj[attr] = this.arrowFlagObj[attr] == 'open' ? 'close' : 'open'
},
handleWechat() {
this.wechatVisible = !this.wechatVisible
},
// 跳转 // 跳转
whereToGo(id) { whereToGo(id) {
document.getElementById(id).scrollIntoView() document.getElementById(id).scrollIntoView()
...@@ -1267,8 +1537,35 @@ export default { ...@@ -1267,8 +1537,35 @@ export default {
}) })
}, },
// 去掉list空值
delListAllEmpty(listName, attrParamsList) {
if (!this.editForm[listName].length) {
return this.editForm[listName]
}
var list = []
var attrList = attrParamsList || Object.keys(this.editForm[listName][0])
this.editForm[listName].forEach(item => {
for (let i = 0; i < attrList.length; i++) {
let attrItem = attrList[i]
if (Array.isArray(item[attrItem])) {
if (item[attrItem].length) {
list.push(item)
break
}
} else if (item[attrItem]) {
list.push(item)
break
}
}
})
return list
},
handleConfirm() { handleConfirm() {
this.stopMusic() this.stopMusic()
this.editForm.activityServices = this.delListAllEmpty('activityServices', ['title', 'content'])
this.editForm.activityCommoditys = this.delListAllEmpty('activityCommoditys', ['question', 'answer'])
this.editForm.activityExperienceDTOs = this.delListAllEmpty('activityExperienceDTOs', ['experience', 'activityExperienceImgs'])
this.validateRules() this.validateRules()
var flag = true var flag = true
if (this.nameToValSpecsList && this.nameToValSpecsList.length > 0) { if (this.nameToValSpecsList && this.nameToValSpecsList.length > 0) {
...@@ -1294,25 +1591,55 @@ export default { ...@@ -1294,25 +1591,55 @@ export default {
} }
} }
let validList = [] let validList = []
this.$refs.editFormRef.$refs[this.editChildRef].validate((valid, errorObj) => { var validFlag = true
validList = [ this.$nextTick(() => {
{ valid: !valid, errorObj: errorObj }, this.$refs.editFormRef.$refs[this.editChildRef].validate((valid, errorObj) => {
{ valid: !flag, errorObj: { goodsId: '' } } validList = [
] { valid: !valid, errorObj: errorObj },
this.$refs.configEditFormRef.$refs[this.editChildRef].validate((configValid, configErrorObj) => { { valid: !flag, errorObj: { goodsId: '' } }
validList.push({ valid: !configValid, errorObj: configErrorObj }) ]
if (this.checkValid(validList)) { this.$refs.configEditFormRef.$refs[this.editChildRef].validate((configValid, configErrorObj) => {
if (this.$refs.serviceEditFormRef) { validList.push({ valid: !configValid, errorObj: configErrorObj })
this.$refs.serviceEditFormRef.$refs[this.editChildRef].validate((serviceValid, serviceErrorObj) => { if (this.checkValid(validList)) {
validList.splice(2, 0, { valid: !serviceValid, errorObj: serviceErrorObj }) if (this.$refs.customerEditFormRef) {
if (this.checkValid(validList)) { this.$refs.customerEditFormRef.$refs[this.editChildRef].validate((customerValid, customerErrorObj) => {
this.addOrUpdate() validList.splice(2, 0, { valid: !customerValid, errorObj: customerErrorObj })
} // if (this.checkValid(validList)) {
}) // this.addOrUpdate()
// }
if (!this.checkValid(validList)) {
validFlag = false
}
})
}
if (this.$refs.serviceEditFormRef) {
this.$refs.serviceEditFormRef.forEach(item => {
item.$refs[this.editChildRef].validate((serviceValid, serviceErrorObj) => {
if (!serviceValid) {
validFlag = false
this.whereToGo('activityServices')
}
})
})
}
if (this.$refs.commoditysEditFormRef) {
this.$refs.commoditysEditFormRef.forEach(item => {
item.$refs[this.editChildRef].validate((commoditysValid, commoditysErrorObj) => {
if (!commoditysValid) {
validFlag = false
this.whereToGo('activityCommoditys')
}
})
})
}
// else {
// this.addOrUpdate()
// }
} else { } else {
this.addOrUpdate() validFlag = false
} }
} validFlag && this.addOrUpdate()
})
}) })
}) })
}, },
...@@ -1339,7 +1666,7 @@ export default { ...@@ -1339,7 +1666,7 @@ export default {
} }
} }
</script> </script>
<style scoped lang="scss"> <style lang="scss">
/* 规格 */ /* 规格 */
.edit-product-dh .spesc-label { .edit-product-dh .spesc-label {
padding: 1px 10px; padding: 1px 10px;
...@@ -1377,140 +1704,19 @@ export default { ...@@ -1377,140 +1704,19 @@ export default {
/* 规格 */ /* 规格 */
.edit-activity { .edit-activity {
position: relative; position: relative;
} .nav-tabs {
.edit-activity .edit-container { position: fixed;
min-height: 680px; right: 100px;
} top: 192px;
.edit-activity .wechat-box { z-index: 99;
width: 276px; .p-l-23 {
box-sizing: border-box; padding-left: 23px;
position: absolute;
top: 100px;
right: 20px;
}
.edit-activity .wechat-box .wechat-inner-box {
position: absolute;
top: 73px;
left: 20px;
width: 236px;
height: 424px;
background-color: #f7f8fa;
overflow-y: scroll;
overflow-x: hidden;
}
.edit-activity .wechat-box .wechat-footer {
position: absolute;
width: 236px;
height: 35px;
bottom: 20px;
left: 20px;
}
.edit-activity .wechat-box .wechat-head {
position: absolute;
width: 236px;
height: 53px;
top: 20px;
left: 20px;
}
.edit-activity .wechat-box .wechat-banner-img {
width: 100%;
height: 552px;
}
.edit-activity .wechat-box .icon-server {
position: absolute;
width: 34px;
height: 42px;
top: 320px;
right: 30px;
z-index: 999;
}
.edit-activity .wechat-box .wechat-banner-img img {
width: 100%;
height: 385px;
}
.edit-activity .wechat-box .wechat-video {
width: 160px;
height: 90px;
margin: 10px auto;
}
.edit-activity .wechat-box .wechat-banner-img .icon-music {
position: absolute;
width: 20px;
height: 20px;
top: 20px;
right: 10px;
}
.edit-activity .wechat-box .wechat-banner-img .wechat-customer {
position: absolute;
width: 100px;
height: 137px;
top: 240px;
left: 10px;
}
.edit-activity .wechat-box .wechat-banner-img {
.wechat-block-title {
text-align: center;
color: #fc5b32;
}
.wechat-block {
box-sizing: border-box;
background-color: #fff;
width: 205px;
font-size: 14px;
padding: 10px;
margin: 10px 12px;
.wechat-sub-addr {
font-size: 12px;
color: #656566;
}
.wechat-time {
font-size: 12px;
color: #fc5b32;
}
.icon-addr {
width: 34px;
height: 34px;
}
.wechat-count-down {
line-height: 22px;
padding: 15px;
border: 1px dotted #e3e3e3;
margin-top: 10px;
}
.wechat-txt {
color: #f13c3d;
background-color: #fff4f4;
padding: 4px;
margin: 0 4px;
}
.count-down-img {
margin-top: 10px;
width: 180px;
height: 188px;
} }
} }
} }
.edit-activity .wechat-box .wechat-banner-img .crowd-jdt { .edit-activity .edit-container {
width: 205px; min-height: 680px;
height: 80px;
margin-bottom: 6px;
}
.edit-activity .wechat-box .wechat-name {
position: absolute;
top: 50px;
left: 58px;
width: 138px;
color: #282829;
z-index: 99;
text-align: center;
} }
/* .edit-activity .wechat-box .wechat-limit-num {
position: absolute;
bottom: 93px;
left: 160px;
font-size: 10px;
width: 20px;
} */
.edit-activity .customer-service { .edit-activity .customer-service {
width: 656px; width: 656px;
padding: 20px 20px 0 20px; padding: 20px 20px 0 20px;
...@@ -1580,12 +1786,17 @@ export default { ...@@ -1580,12 +1786,17 @@ export default {
background: #f9f9f9; background: #f9f9f9;
padding: 20px; padding: 20px;
} }
.edit-activity .describe-btn { .edit-activity .btn-basic {
color: #5850ff; color: #5850ff;
cursor: pointer; cursor: pointer;
padding: 0; padding: 0;
} }
.edit-activity .form-describe-box .icon-add { .edit-activity .btn-disable {
opacity: 40%;
cursor: default;
padding: 0;
}
.edit-activity .icon-add {
width: 20px; width: 20px;
height: 20px; height: 20px;
vertical-align: middle; vertical-align: middle;
...@@ -1619,6 +1830,71 @@ export default { ...@@ -1619,6 +1830,71 @@ export default {
border-left: 1px solid rgb(220, 223, 230); border-left: 1px solid rgb(220, 223, 230);
} }
.edit-activity {
.custom-label {
display: inline-block;
text-align: right;
}
.arrow {
cursor: pointer;
}
.form-open {
max-height: 4000px;
transition: max-height 0.5s ease;
}
.form-close {
max-height: 0;
transition: max-height 0.5s ease;
overflow: hidden;
}
.form-show-box {
width: 866px;
background: #f9f9f9;
padding: 5px 0;
.form-show-block {
height: calc(100% - 35px);
}
.head-box {
display: flex;
align-items: center;
padding: 20px 0 0 20px;
color: #282829;
.icon-head {
width: 26px;
height: 26px;
margin-right: 4px;
}
}
.form-show-item {
position: relative;
.btn-delete {
position: absolute;
top: 0;
right: 0;
width: 40px;
height: 100%;
background: #f1f1f1;
}
.last-btn-delete {
height: calc(100% + 25px);
}
.btn-delete:hover {
background: #000000;
opacity: 0.1;
}
}
.btn-box {
padding: 0 20px 2px;
}
.line {
border-bottom: 1px dashed rgba(0, 0, 0, 0.15);
}
.el-form-item--small .el-form-item__content {
width: auto !important;
}
}
}
::-webkit-scrollbar { ::-webkit-scrollbar {
/*滚动条整体样式*/ /*滚动条整体样式*/
width: 6px; width: 6px;
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<template> <template>
<div class="marketing"> <div class="marketing">
<div class="m-b-20"> <div class="m-b-20">
<GLButton :size="size" class="default-blue-btn el-icon-plus" type="default" @click="addActivity()" fn="新增秒杀活动" mode="el-button">新增秒杀活动</GLButton> <GLButton :size="size" class="el-icon-plus" type="primary" @click="addActivity()" fn="新增秒杀活动" mode="el-button">新增秒杀活动</GLButton>
</div> </div>
<div class="container"> <div class="container">
<GLCombiForm ref="showSearch" :rowNumber="1" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm> <GLCombiForm ref="showSearch" :rowNumber="1" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
<div class="sop-base-info"> <div class="sop-base-info">
<div class="container m-b-20"> <div class="container m-b-20">
<p class="edit-title">{{ title }}</p> <p class="edit-title">{{ title }}</p>
<glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :labelWidth="labelWidth" defaultWidth="320px" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :labelWidth="labelWidth" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<div slot="startDate"> <div slot="startDate">
<el-input class="w-320" :placeholder="!editForm.eventList.length ? '设置营销事件后自动补充' : editForm.startDate + (editForm.endDate ? ' - ' + editForm.endDate : '')" disabled></el-input> <el-input class="w432" :placeholder="!editForm.eventList.length ? '设置营销事件后自动补充' : editForm.startDate + (editForm.endDate ? ' - ' + editForm.endDate : '')" disabled></el-input>
</div> </div>
<div slot="customerInfoList" slot-scope="scope"> <div slot="customerInfoList" slot-scope="scope">
<div v-if="!scope.scope.isDisabled"> <div v-if="!scope.scope.isDisabled">
......
...@@ -434,7 +434,7 @@ export default { ...@@ -434,7 +434,7 @@ export default {
deep: true deep: true
}, },
'editForm.reachesTypeSet'(newValue, oldValue) { 'editForm.reachesTypeSet'(newValue, oldValue) {
this.editForm.reachesTypeSet = limitPrice(newValue, oldValue, 5, 0, 1, 9999, 'zNumReg') this.editForm.reachesTypeSet = limitPrice(newValue + '', oldValue, 5, 0, 1, 9999, 'zNumReg')
}, },
'editForm.object.additionalType'(val) { 'editForm.object.additionalType'(val) {
var idx = this.editFormDataChannel.findIndex(item => item.name == 'pushChannelType') var idx = this.editFormDataChannel.findIndex(item => item.name == 'pushChannelType')
...@@ -719,12 +719,12 @@ export default { ...@@ -719,12 +719,12 @@ export default {
this.editForm.followerTypeName = this.baseData.staffTypeList.find(item => item.id).businessName this.editForm.followerTypeName = this.baseData.staffTypeList.find(item => item.id).businessName
// 预估可触达人数 // 预估可触达人数
this.editForm.predictCount = this.predictCountObj[this.editForm.pushChannelType == 2 ? 'phone' : 'qiwei'] this.editForm.predictCount = this.predictCountObj[this.editForm.pushChannelType == 2 ? 'phone' : 'qiwei']
console.log(this.editForm) // console.log(this.editForm)
if (this.editForm.repeatFlag == 'Y') { if (this.editForm.repeatFlag == 'Y') {
this.$apis.sop.parseEventCountApi(countParams).then(res => { this.$apis.sop.parseEventCountApi(countParams).then(res => {
// this.editForm.eventCount = res.eventStatistics.eventCount // this.editForm.eventCount = res.eventStatistics.eventCount
this.maxReachesTypeSet = res.eventStatistics.eventCount this.maxReachesTypeSet = res.eventStatistics.eventCount
if (this.maxReachesTypeSet < this.editForm.reachesTypeSet || this.editForm.reachesTypeSet < 2) { if (this.editForm.reachesType == 2 && (this.maxReachesTypeSet < this.editForm.reachesTypeSet || this.editForm.reachesTypeSet < 2)) {
this.whereToGo('reachesTypeSet') this.whereToGo('reachesTypeSet')
this.submit = false this.submit = false
return true return true
...@@ -849,4 +849,4 @@ export default { ...@@ -849,4 +849,4 @@ export default {
} }
} }
} }
</style> </style>
\ No newline at end of file \ No newline at end of file
...@@ -3,14 +3,14 @@ ...@@ -3,14 +3,14 @@
<div class="edit-zone marketing edit-box"> <div class="edit-zone marketing edit-box">
<div class="container edit-container"> <div class="container edit-container">
<p class="edit-title">{{ title }}</p> <p class="edit-title">{{ title }}</p>
<glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :labelWidth="labelWidth" defaultWidth="320px" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <glsx-combi-form class="edit-form-container m-r-20" ref="editFormRef" :isEdit="isEdit" :labelWidth="defaultLabelWidth" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<div slot="selectMerchant" slot-scope="scope" class="select-merchant"> <div slot="selectMerchant" slot-scope="scope" class="select-merchant">
<el-button type="default" @click="handleRelateStoreClose(scope)">{{ editForm.merchantList.length ? '更换门店' : '+选择门店' }}</el-button> <el-button type="default" @click="handleRelateStoreClose(scope)">{{ editForm.merchantList.length ? '更换门店' : '+选择门店' }}</el-button>
</div> </div>
<div slot="merchantTable" :style="{ 'margin-left': labelWidth, width: `calc(100% - ${labelWidth} )` }"> <div slot="merchantTable" :style="{ 'margin-left': defaultLabelWidth, width: `calc(100% - ${defaultLabelWidth} )` }">
<GLTable v-show="editForm.merchantList.length" ref="warehousListRef" :hasPage="false" :tableParams="tableParams" :tableData="editForm.merchantList"> <GLTable v-show="editForm.merchantList.length" ref="warehousListRef" :hasPage="false" :tableParams="tableParams" :tableData="editForm.merchantList">
<span slot="auth-button" slot-scope="scope"> <span slot="customBtn" slot-scope="scope">
<el-button type="text" @click="handleMerchantDelete(scope)">删除</el-button> <el-button class="p-0" type="text" @click="handleMerchantDelete(scope)">删除</el-button>
</span> </span>
</GLTable> </GLTable>
</div> </div>
...@@ -35,10 +35,6 @@ ...@@ -35,10 +35,6 @@
<el-button @click="handleCancel" size="medium">取消</el-button> <el-button @click="handleCancel" size="medium">取消</el-button>
<el-button type="primary" @click="handleConfirm" size="medium" :loading="loading">提交</el-button> <el-button type="primary" @click="handleConfirm" size="medium" :loading="loading">提交</el-button>
</GLFooter> </GLFooter>
<!-- <div class="footer" :style="{ left: footerLeft + 'px', width: footerWidth + 'px' }">
<el-button type="primary" @click="handleConfirm">确定</el-button>
<el-button type="default" @click="handleCancel">取消</el-button>
</div> -->
</div> </div>
</template> </template>
...@@ -60,7 +56,6 @@ export default { ...@@ -60,7 +56,6 @@ export default {
id: '' id: ''
}, },
editStatus: false, editStatus: false,
labelWidth: '144px',
editForm: { editForm: {
// 专区类型(1发现频道,2商城专区) // 专区类型(1发现频道,2商城专区)
zoneType: '2', zoneType: '2',
...@@ -120,11 +115,15 @@ export default { ...@@ -120,11 +115,15 @@ export default {
selectedList: [], selectedList: [],
// 门店表格 // 门店表格
tableParams: { tableParams: {
tableOption: true,
tableColumns: [ tableColumns: [
{ {
label: '门店名称', label: '门店名称',
prop: 'merchantName' prop: 'merchantName'
},
{
label: '操作',
prop: '',
addHtml: 'customBtn'
} }
] ]
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!