分销:根据商品,计算推广员可以得到的佣金

pull/2/head
owen 2023-09-24 22:27:23 +08:00
parent 7b35a39618
commit b076f61c58
2 changed files with 9 additions and 5 deletions

View File

@ -1,5 +1,5 @@
<template> <template>
<view class='sharing-packets' :class='!sharePacket.enabled ? "on":""'> <view class='sharing-packets' :class='!enabled ? "on":""'>
<view class='iconfont icon-guanbi' @click="closeShare"></view> <view class='iconfont icon-guanbi' @click="closeShare"></view>
<view class='line'></view> <view class='line'></view>
<view class='sharing-con' @click='goShare'> <view class='sharing-con' @click='goShare'>
@ -41,7 +41,11 @@
return { return {
}; };
}, },
computed: {
enabled() {
return this.sharePacket.enabled && (this.sharePacket.brokerageMinPrice || this.sharePacket.brokerageMaxPrice)
}
},
methods: { methods: {
closeShare:function(){ closeShare:function(){
this.$emit('closeChange'); this.$emit('closeChange');
@ -64,7 +68,7 @@
.sharing-packets .sharing-con{width:187rpx;height:210rpx;position:relative;} .sharing-packets .sharing-con{width:187rpx;height:210rpx;position:relative;}
.sharing-packets .sharing-con image{width:100%;height:100%;} .sharing-packets .sharing-con image{width:100%;height:100%;}
.sharing-packets .sharing-con .text{position:absolute;top:30rpx;font-size:20rpx;width:100%;text-align:center;} .sharing-packets .sharing-con .text{position:absolute;top:30rpx;font-size:20rpx;width:100%;text-align:center;}
.sharing-packets .sharing-con .text .money{font-size:32rpx;font-weight:bold;margin-top:5rpx;} .sharing-packets .sharing-con .text .money{font-size:32rpx;font-weight:bold;margin-top:5rpx;white-space: nowrap}
.sharing-packets .sharing-con .text .money .label{font-size:20rpx;} .sharing-packets .sharing-con .text .money .label{font-size:20rpx;}
.sharing-packets .sharing-con .text .tip{font-size:18rpx;color:#999;margin-top:5rpx;} .sharing-packets .sharing-con .text .tip{font-size:18rpx;color:#999;margin-top:5rpx;}
.sharing-packets .sharing-con .text .shareBut{font-size:22rpx;color:#fff;margin-top:18rpx;height:50rpx;line-height:50rpx;} .sharing-packets .sharing-con .text .shareBut{font-size:22rpx;color:#fff;margin-top:18rpx;height:50rpx;line-height:50rpx;}

View File

@ -572,7 +572,7 @@
}) })
}, },
getBrokeragePrice: function() { getBrokeragePrice: function() {
BrokerageAPI.getProductBrokeragePrice(this.id).then(res => { BrokerageAPI.getProductBrokeragePrice(this.activity.spuId).then(res => {
this.sharePacket = res.data this.sharePacket = res.data
}); });
}, },