|
@@ -1,46 +1,58 @@
|
|
|
<template>
|
|
|
<div>
|
|
|
<div class="table-page-search-wrapper" v-show="showDescBox">
|
|
|
- <a-descriptions :column="4" v-if="descDetail">
|
|
|
- <a-descriptions-item label="促销类型">
|
|
|
+ <a-row v-if="descDetail" type="flex" justify="start">
|
|
|
+ <a-col span="6" style="padding: 6px;">
|
|
|
+ <span>促销类型:</span>
|
|
|
{{ descDetail.promotionRuleTypeDictValue||'--' }}
|
|
|
- </a-descriptions-item>
|
|
|
- <a-descriptions-item label="促销门槛" span="3">
|
|
|
- <div v-if="descDetail.gateFlag === '1'">
|
|
|
- <span v-if="descDetail.gateType==='RATIO_AMOUNT'">
|
|
|
- 购买门槛产品金额{{ descDetail.gateAmount*100 }}%作为配额
|
|
|
- </span>
|
|
|
- <span v-else-if="descDetail.gateType==='MIN_AMOUNT'">
|
|
|
- 购买门槛产品满最低金额{{ descDetail.gateAmount }}不限制配额。
|
|
|
- </span>
|
|
|
- <span v-else>购买满{{ descDetail.gateAmount }}元门槛产品,可使用 {{ descDetail.quotaAmount }}元配额,采购规则中的正价商品</span>
|
|
|
- </div>
|
|
|
- <span v-else>无</span>
|
|
|
- </a-descriptions-item>
|
|
|
- <a-descriptions-item label="促销规则">
|
|
|
- {{ descDetail.regularSameFlag==='1'?'同款,':'不同款,' }}
|
|
|
- <span v-if="descDetail.promotionRuleType == 'BUY_PROD_GIVE_PROD'">
|
|
|
- 购买满{{ descDetail.regularQty }}个正价产品,送{{ descDetail.promotionQty }}个促销产品
|
|
|
- {{ descDetail.accrualFlag ? ',数量叠加':',数量不叠加' }}
|
|
|
- </span>
|
|
|
- <span v-else-if="descDetail.promotionRuleType == 'BUY_PROD_GIVE_MONEY'">
|
|
|
- 购买满{{ descDetail.regularAmount }}元正价产品,送{{ descDetail.giveAmount }}元促销品采购额
|
|
|
- {{ descDetail.accrualFlag ? ',金额叠加':',金额不叠加' }}
|
|
|
- </span>
|
|
|
- <span v-else>
|
|
|
- 特价产品
|
|
|
- </span>
|
|
|
- </a-descriptions-item>
|
|
|
- <a-descriptions-item label="限制正价产品款数" v-if="descDetail.promotionRuleType!='PROMO_PROD'&&descDetail.promotionRuleType!='BUY_PROD_GIVE_MONEY'">
|
|
|
+ </a-col>
|
|
|
+ <a-col span="6" style="padding: 6px;" v-if="descDetail.promotionRuleType!='PROMO_PROD'&&descDetail.promotionRuleType!='BUY_PROD_GIVE_MONEY'">
|
|
|
+ <span>限制正价产品款数:</span>
|
|
|
{{ descDetail.restrictCategory||'--' }}
|
|
|
- </a-descriptions-item>
|
|
|
- <a-descriptions-item label="订单起订金额(元)">
|
|
|
+ </a-col>
|
|
|
+ <a-col span="6" style="padding: 6px;">
|
|
|
+ <span>订单起订金额(元):</span>
|
|
|
{{ descDetail.minOrderAmount||'无' }}
|
|
|
- </a-descriptions-item>
|
|
|
- <a-descriptions-item label="活动经费上线(元)">
|
|
|
+ </a-col>
|
|
|
+ <a-col span="6" style="padding: 6px;">
|
|
|
+ <span>活动经费上线(元):</span>
|
|
|
{{ descDetail.upperLimitAmount||'无' }}
|
|
|
- </a-descriptions-item>
|
|
|
- </a-descriptions>
|
|
|
+ </a-col>
|
|
|
+ <a-col span="24" style="padding: 6px;">
|
|
|
+ <div style="display: flex;">
|
|
|
+ <div style="min-width: 40%;display: flex;">
|
|
|
+ <span>促销门槛:</span>
|
|
|
+ <div v-if="descDetail.gateFlag === '1'">
|
|
|
+ <span v-if="descDetail.gateType==='RATIO_AMOUNT'">
|
|
|
+ 购买门槛产品金额{{ descDetail.gateAmount*100 }}%作为配额
|
|
|
+ </span>
|
|
|
+ <span v-else-if="descDetail.gateType==='MIN_AMOUNT'">
|
|
|
+ 购买门槛产品满最低金额{{ descDetail.gateAmount }}不限制配额。
|
|
|
+ </span>
|
|
|
+ <span v-else>购买满{{ descDetail.gateAmount }}元门槛产品,可使用 {{ descDetail.quotaAmount }}元配额,采购规则中的正价商品</span>
|
|
|
+ </div>
|
|
|
+ <span v-else>无</span>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div style="display: flex;padding-left: 24px;">
|
|
|
+ <span>促销规则:</span>
|
|
|
+ <span v-if="descDetail.promotionRuleType == 'BUY_PROD_GIVE_PROD'">
|
|
|
+ {{ descDetail.regularSameFlag==='1'?'同款,':'不同款,' }}
|
|
|
+ 购买满{{ descDetail.regularQty }}个正价产品,送{{ descDetail.promotionQty }}个促销产品
|
|
|
+ {{ descDetail.accrualFlag == 1 ? ',数量叠加':',数量不叠加' }}
|
|
|
+ </span>
|
|
|
+ <span v-else-if="descDetail.promotionRuleType == 'BUY_PROD_GIVE_MONEY'">
|
|
|
+ {{ descDetail.regularSameFlag==='1'?'同款,':'不同款,' }}
|
|
|
+ 购买满{{ descDetail.regularAmount }}元正价产品,送{{ descDetail.giveAmount }}元促销品采购额
|
|
|
+ {{ descDetail.accrualFlag == 1 ? ',金额叠加':',金额不叠加' }}
|
|
|
+ </span>
|
|
|
+ <span v-else>
|
|
|
+ 特价产品
|
|
|
+ </span>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </a-col>
|
|
|
+ </a-row>
|
|
|
</div>
|
|
|
<!-- 筛选条件 -->
|
|
|
<div class="table-page-search-wrapper" style="margin:0" v-show="showSearchBox">
|
|
@@ -148,7 +160,6 @@
|
|
|
<template slot="productCode" slot-scope="text, record">
|
|
|
<span style="padding-right: 15px;">{{ text }}</span>
|
|
|
<a-badge count="促" v-if="record.promotionFlag=='GIFT'" :number-style="{ backgroundColor: '#52c41a', zoom:'80%' }"></a-badge>
|
|
|
- <!-- <a-badge count="正" v-if="record.promotionFlag=='REGULAR'" :number-style="{ backgroundColor: '#108ee9', zoom:'80%' }"></a-badge> -->
|
|
|
<a-badge count="特" v-if="record.promotionFlag=='DISCOUNT'" :number-style="{ backgroundColor: '#faad14', zoom:'80%' }"></a-badge>
|
|
|
<a-badge count="缺" v-if="Number(record.stockQty||0) < Number(record.unpushedQty||0)" :number-style="{ zoom:'80%' }"></a-badge>
|
|
|
</template>
|
|
@@ -164,10 +175,14 @@
|
|
|
<a-badge :number-style="{ backgroundColor: '#52c41a' }" count="活动" v-if="record.promotableFlag == 1"></a-badge>
|
|
|
</div>
|
|
|
</template>
|
|
|
-
|
|
|
+ <!-- 销售价 -->
|
|
|
+ <template slot="price" slot-scope="text, record">
|
|
|
+ {{ toThousands(text) }}
|
|
|
+ <span v-if="record.promotionFlag=='GIFT'" title="原价">({{ toThousands(record.origPrice) }})</span>
|
|
|
+ </template>
|
|
|
<!-- 促销价 -->
|
|
|
<template slot="discountPrice" slot-scope="text, record">
|
|
|
- <span>{{ record.discountedPrice }}</span>
|
|
|
+ <span>{{ toThousands(record.discountedPrice) }}</span>
|
|
|
({{ record.discountRate }}%)
|
|
|
</template>
|
|
|
<!-- 销售数量 -->
|
|
@@ -394,7 +409,7 @@
|
|
|
{ title: '操作', scopedSlots: { customRender: 'action' }, width: '10%', align: 'center' }
|
|
|
]
|
|
|
if (this.$hasPermissions('B_salesEdit_salesPrice')) { // 售价权限
|
|
|
- arr.splice(3, 0, { title: '售价', dataIndex: 'price', width: '8%', align: 'right', customRender: text => ((text || text == 0) ? this.toThousands(text) : '--') })
|
|
|
+ arr.splice(3, 0, { title: '售价', dataIndex: 'price', width: '8%', align: 'right', scopedSlots: { customRender: 'price' } })
|
|
|
// 如果是特价活动
|
|
|
if(this.promo.promotionRule.promotionRuleType=='PROMO_PROD'){
|
|
|
arr.splice(4, 0, { title: '促销价', dataIndex: 'discountPrice', width: '8%', align: 'right', scopedSlots: { customRender: 'discountPrice' }})
|
|
@@ -722,8 +737,9 @@
|
|
|
|
|
|
salesBatchInsert(params).then(res => {
|
|
|
if (res.status == 200) {
|
|
|
- this.$refs.table.refresh(true)
|
|
|
- this.getOrderDetail(false)
|
|
|
+ this.resetSearchForm()
|
|
|
+ this.$message.success('产品导入成功', 2.5)
|
|
|
+ this.$emit('insterOk','promo')
|
|
|
}
|
|
|
})
|
|
|
},
|