Commit a684207d by chenwq

首页设置-优惠政策;编辑商品-带货模式。

1 parent 7403f491
...@@ -207,7 +207,7 @@ export default { ...@@ -207,7 +207,7 @@ export default {
editForm: { editForm: {
merchantQrcode: '', merchantQrcode: '',
noticeContent: '', noticeContent: '',
// preferentialPolicy: '', preferentialPolicy: '',
clueList: [], clueList: [],
customerServerUserId: '', customerServerUserId: '',
bannerList: [] bannerList: []
...@@ -272,19 +272,19 @@ export default { ...@@ -272,19 +272,19 @@ export default {
} }
] ]
}, },
// { {
// title: '新车优惠政策', title: '新车优惠政策',
// editFormData: [ editFormData: [
// { {
// label: '优惠政策', label: '优惠政策',
// name: 'preferentialPolicy', name: 'preferentialPolicy',
// type: 'input', type: 'input',
// rows: '4', rows: '4',
// inputType: 'textarea', inputType: 'textarea',
// maxlength: '300' maxlength: '300'
// } }
// ] ]
// }, },
{ {
title: '金刚区管理', title: '金刚区管理',
editFormData: [ editFormData: [
...@@ -373,7 +373,7 @@ export default { ...@@ -373,7 +373,7 @@ export default {
this.editForm.noticeContent = res.noticeContent this.editForm.noticeContent = res.noticeContent
this.editForm.merchantQrcode = res.merchantQrcode this.editForm.merchantQrcode = res.merchantQrcode
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.customerServerList = [] this.customerServerList = []
......
...@@ -143,7 +143,7 @@ ...@@ -143,7 +143,7 @@
<tr style="border-bottom: 1px solid rgb(235, 235, 235); height: 54px; line-height: 54px;" v-for="(subItem, subIndex) in nameToValSpecsList" :key="subIndex"> <tr style="border-bottom: 1px solid rgb(235, 235, 235); height: 54px; line-height: 54px;" v-for="(subItem, subIndex) in nameToValSpecsList" :key="subIndex">
<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.takeGoodMode == 2"> <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="{ '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>
...@@ -177,20 +177,20 @@ ...@@ -177,20 +177,20 @@
<template slot="memberPrice"> <template slot="memberPrice">
<p class="edit-tips">作为会员商城购买的价格</p> <p class="edit-tips">作为会员商城购买的价格</p>
</template> </template>
<template slot="takeGoodMode" slot-scope="scope"> <template slot="takeType" slot-scope="scope">
<el-radio-group :disabled="isDisabled" v-model="editForm[scope.scope.name]"> <el-radio-group :disabled="isDisabled" v-model="editForm[scope.scope.name]">
<div v-for="(n, idx) in baseData.takeGoodModeList" :key="idx"> <div v-for="(n, idx) in baseData.takeTypeList" :key="idx">
<el-radio :label="n.confId" class="take-good-mode-block"> <el-radio :label="n.confId" class="take-good-mode-block">
<div> <div>
<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 == '1'" prop="profitRatio" label="分润比例:"> <el-form-item v-show="n.confId == '0'" prop="profitRatio" label="分润比例:">
<el-input v-model="editForm.profitRatio" :disabled="editForm[scope.scope.name] != '1'" placeholder="请输入分润比例"><span slot="append">%</span></el-input> <el-input v-model="editForm.profitRatio" :disabled="editForm[scope.scope.name] != '0'" placeholder="请输入分润比例"><span slot="append">%</span></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 == '2'" prop="supplyPrice" label="供货价:"> <el-form-item v-show="n.confId == '1'" prop="supplyPrice" label="供货价:">
<el-input v-model="editForm.supplyPrice" :disabled="editForm[scope.scope.name] != '2'" placeholder="请输入供货价"><span slot="append">元</span></el-input> <el-input v-model="editForm.supplyPrice" :disabled="editForm[scope.scope.name] != '1'" placeholder="请输入供货价"><span slot="append">元</span></el-input>
<p class="edit-tips">作为货源供给门店的价格</p> <p class="edit-tips">作为货源供给门店的价格</p>
</el-form-item> </el-form-item>
</el-radio> </el-radio>
...@@ -493,7 +493,7 @@ export default { ...@@ -493,7 +493,7 @@ export default {
// specificationDetailList: [], // specificationDetailList: [],
retailPrice: '', retailPrice: '',
originalPrice: '', originalPrice: '',
takeGoodMode: 2, takeType: 1,
supplyPrice: '', supplyPrice: '',
profitRatio: '', profitRatio: '',
memberPrice: '', memberPrice: '',
...@@ -721,11 +721,11 @@ export default { ...@@ -721,11 +721,11 @@ export default {
}, },
{ {
label: '带货模式', label: '带货模式',
name: 'takeGoodMode', name: 'takeType',
addHtml: 'takeGoodMode', addHtml: 'takeType',
tipObj: { tipObj: {
'1': '集团上架自己的商品分发到门店,每个月安装分润比例分成给门店', '0': '集团上架自己的商品分发到门店,每个月安装分润比例分成给门店',
'2': '门店需要配置零售价并上架商品,需要集团设置供货价给门店' '1': '门店需要配置零售价并上架商品,需要集团设置供货价给门店'
}, },
isHide: false, isHide: false,
isDisabled: false isDisabled: false
...@@ -832,13 +832,13 @@ export default { ...@@ -832,13 +832,13 @@ export default {
baseData: { baseData: {
classifyList: [], classifyList: [],
zoneList: [], zoneList: [],
takeGoodModeList: [ takeTypeList: [
{ {
confId: 1, confId: 0,
confName: '集团总控' confName: '集团总控'
}, },
{ {
confId: 2, confId: 1,
confName: '门店总控' confName: '门店总控'
} }
] ]
...@@ -908,6 +908,7 @@ export default { ...@@ -908,6 +908,7 @@ export default {
created() { created() {
this.routeInfo = this.$route.query this.routeInfo = this.$route.query
this.diffHost()
this.businessGetBusinessTypeById() this.businessGetBusinessTypeById()
}, },
...@@ -936,6 +937,13 @@ export default { ...@@ -936,6 +937,13 @@ export default {
this.externalFormList[0].editFormData[idx].businessTypeList = res this.externalFormList[0].editFormData[idx].businessTypeList = res
}) })
}, },
// 从域名判断是不是广汇的
diffHost() {
let href = window.location.host
this.showGh = href.indexOf('cgacar') != -1
this.hideGHAttr()
},
hideGHAttr() {},
del() { del() {
this.editForm.relatedCouponId = '' this.editForm.relatedCouponId = ''
this.editForm.relatedCouponName = '' this.editForm.relatedCouponName = ''
...@@ -1025,7 +1033,7 @@ export default { ...@@ -1025,7 +1033,7 @@ export default {
pIdx: 0 pIdx: 0
}, },
{ {
name: 'takeGoodMode', name: 'takeType',
pIdx: 1 pIdx: 1
} }
] ]
...@@ -1311,7 +1319,7 @@ export default { ...@@ -1311,7 +1319,7 @@ export default {
classifyIdList: res.classifyList.map(item => item.id), classifyIdList: res.classifyList.map(item => item.id),
originalPrice: (res.originalPrice / 100).toFixed(2), originalPrice: (res.originalPrice / 100).toFixed(2),
retailPrice: '', retailPrice: '',
takeGoodMode: res.takeGoodMode || 2, takeType: res.takeType || 1,
memberPrice: res.memberPrice ? (res.memberPrice / 100).toFixed(2) : '', memberPrice: res.memberPrice ? (res.memberPrice / 100).toFixed(2) : '',
goodsStock: res.goodsStock + '', goodsStock: res.goodsStock + '',
supplyPrice: res.supplyPrice ? (res.supplyPrice / 100).toFixed(2) : '', supplyPrice: res.supplyPrice ? (res.supplyPrice / 100).toFixed(2) : '',
...@@ -1452,7 +1460,7 @@ export default { ...@@ -1452,7 +1460,7 @@ export default {
isJump = true isJump = true
break break
} }
if (this.routeInfo.groupOrStore == 1 && this.editForm.takeGoodMode == 2 && +item.retailPrice < +this.editForm.supplyPrice) { if (this.routeInfo.groupOrStore == 1 && this.editForm.takeType == 1 && +item.retailPrice < +this.editForm.supplyPrice) {
this.whereToGo('specificationDetailList') this.whereToGo('specificationDetailList')
isJump = true isJump = true
break break
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!