This commit is contained in:
parent
d69560e61d
commit
c6baaf7555
|
@ -21,7 +21,7 @@
|
||||||
<view v-else class="money">
|
<view v-else class="money">
|
||||||
<view class="acea-row row-middle">
|
<view class="acea-row row-middle">
|
||||||
<view class="acea-row row-middle">
|
<view class="acea-row row-middle">
|
||||||
<text>¥</text><text class="num">{{ attr.productSelect.procure_price }}</text>
|
<text>¥</text><text class="num">{{ attr.productSelect.wholesale_price }}</text>
|
||||||
<view v-if="attr.productSelect && attr.productSelect.svip_price>0" class="acea-row row-middle">
|
<view v-if="attr.productSelect && attr.productSelect.svip_price>0" class="acea-row row-middle">
|
||||||
<text class='vip-money'>¥{{attr.productSelect.svip_price}}</text>
|
<text class='vip-money'>¥{{attr.productSelect.svip_price}}</text>
|
||||||
<view class="vipImg">
|
<view class="vipImg">
|
||||||
|
|
|
@ -119,10 +119,10 @@
|
||||||
},
|
},
|
||||||
computed:{
|
computed:{
|
||||||
leftPrice(){
|
leftPrice(){
|
||||||
return this.sku[this.changeSkuKey]?.procure_price?.split('.')[0]||'0';
|
return this.sku[this.changeSkuKey]?.wholesale_price?.split('.')[0]||'0';
|
||||||
},
|
},
|
||||||
rightPrice(){
|
rightPrice(){
|
||||||
return this.sku[this.changeSkuKey]?.procure_price?.split('.')[1]||'00';
|
return this.sku[this.changeSkuKey]?.wholesale_price?.split('.')[1]||'00';
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
@ -247,7 +247,7 @@
|
||||||
// return console.log(this.sku[this.changeSkuKey]);
|
// return console.log(this.sku[this.changeSkuKey]);
|
||||||
if(this.cart_num<this.once_min_count) return Toast(`至少要购买${this.once_min_count}件哦`);
|
if(this.cart_num<this.once_min_count) return Toast(`至少要购买${this.once_min_count}件哦`);
|
||||||
if(!this.sku[this.changeSkuKey]) return Toast('该规格有错误, 请选择其他规格');
|
if(!this.sku[this.changeSkuKey]) return Toast('该规格有错误, 请选择其他规格');
|
||||||
if(+this.sku[this.changeSkuKey].procure_price * +this.cart_num<=0) return Toast('无法购买价格小于等于0的商品');
|
if(+this.sku[this.changeSkuKey].wholesale_price * +this.cart_num<=0) return Toast('无法购买价格小于等于0的商品');
|
||||||
if (this.sku[this.changeSkuKey]) {
|
if (this.sku[this.changeSkuKey]) {
|
||||||
if (this.cart_num > this.sku[this.changeSkuKey].stock) return uni.showToast({
|
if (this.cart_num > this.sku[this.changeSkuKey].stock) return uni.showToast({
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
|
|
4
main.js
4
main.js
|
@ -25,10 +25,10 @@ Vue.component('BaseMoney', BaseMoney)
|
||||||
Vue.component('barcode', barcode)
|
Vue.component('barcode', barcode)
|
||||||
Vue.prototype.$util = util;
|
Vue.prototype.$util = util;
|
||||||
Vue.prototype.$Cache = Cache;
|
Vue.prototype.$Cache = Cache;
|
||||||
Vue.prototype.$procure_price = (item)=>{
|
Vue.prototype.$wholesale_price = (item)=>{
|
||||||
if(item.sku){
|
if(item.sku){
|
||||||
let key = Object.keys(item.sku)||[''];
|
let key = Object.keys(item.sku)||[''];
|
||||||
return item.sku[key[0]]?.procure_price;
|
return item.sku[key[0]]?.wholesale_price;
|
||||||
}
|
}
|
||||||
else return '无批发价';
|
else return '无批发价';
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,8 +17,8 @@
|
||||||
<view class="c-body-text">
|
<view class="c-body-text">
|
||||||
<view class="price">{{info.subsidy_amount}}元</view>
|
<view class="price">{{info.subsidy_amount}}元</view>
|
||||||
<view>
|
<view>
|
||||||
<text v-if="info.subsidy_status" class="price">已到账</text>
|
<text v-if="info.subsidy_status" class="price">{{info.subsidy_status_name}}</text>
|
||||||
<text v-else>未激活</text>
|
<text v-else>{{info.subsidy_status_name}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -108,13 +108,14 @@
|
||||||
<view>状态</view>
|
<view>状态</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="list-b-text" v-for="(item,index) in list" :key="index">
|
<view class="list-b-text" v-for="(item,index) in list" :key="index">
|
||||||
<view class="item1">¥{{ item.extra.purchase_amount }}</view>
|
<view class="item1">¥{{ cPrice2(item.extra.official_purchase_target, item.extra.purchase_target) }}</view>
|
||||||
<view class="item2">¥{{ item.extra.sale_amount }}</view>
|
<view class="item2">¥{{ item.extra.sale_target }}</view>
|
||||||
<view class="item3" v-if="item.status!=1">¥{{ cPrice(item.coupon_price) }}</view>
|
<view class="item3" v-if="item.status!=1">¥{{ cPrice(item.coupon_price) }}</view>
|
||||||
<view class="item3" v-else>¥{{ item.coupon_price }}</view>
|
<view class="item3" v-else>¥{{ item.coupon_price }}</view>
|
||||||
<view class="item4">
|
<view class="item4">
|
||||||
<text v-if="item.status!=1">未激活</text>
|
<!-- send_status 发放状态:-1未激活,0待审核,1待领取,2已完成 -->
|
||||||
<text v-else style="color: #FF5E0C;">已到账</text>
|
<text v-if="item.send_status==2" style="color: #FF5E0C;">{{item.send_status_cn}}</text>
|
||||||
|
<text v-else>{{item.send_status_cn}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="list-b-text" style="align-items: center;" v-if="list.length == 0">
|
<view class="list-b-text" style="align-items: center;" v-if="list.length == 0">
|
||||||
|
@ -182,6 +183,11 @@
|
||||||
t/=3*100;
|
t/=3*100;
|
||||||
t==0?t=1:null;
|
t==0?t=1:null;
|
||||||
return (+n*t).toFixed(2);
|
return (+n*t).toFixed(2);
|
||||||
|
},
|
||||||
|
cPrice2(a,b){
|
||||||
|
a = Number(a);
|
||||||
|
b = Number(b);
|
||||||
|
return (a+b).toFixed(2)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onPullDownRefresh() {
|
onPullDownRefresh() {
|
||||||
|
|
|
@ -137,7 +137,7 @@
|
||||||
<view class="info" v-if="item.cart_info && item.cart_info.product">
|
<view class="info" v-if="item.cart_info && item.cart_info.product">
|
||||||
<view class="name line2">{{item.cart_info.product.store_name}}</view>
|
<view class="name line2">{{item.cart_info.product.store_name}}</view>
|
||||||
<view class="info_sku" v-if="item.cart_info && item.cart_info.productAttr">{{item.cart_info.productAttr.sku}}</view>
|
<view class="info_sku" v-if="item.cart_info && item.cart_info.productAttr">{{item.cart_info.productAttr.sku}}</view>
|
||||||
<view class="info_price" v-if="item.cart_info && item.cart_info.productAttr">¥<text>{{item.cart_info.productAttr.procure_price}}</text></view>
|
<view class="info_price" v-if="item.cart_info && item.cart_info.productAttr">¥<text>{{item.cart_info.productAttr.wholesale_price}}</text></view>
|
||||||
<view class='carnum acea-row row-center-wrapper'>
|
<view class='carnum acea-row row-center-wrapper'>
|
||||||
<view class="reduce" :class="item.numSub ? 'on' : ''" @click.stop='subCart(item)'>-</view>
|
<view class="reduce" :class="item.numSub ? 'on' : ''" @click.stop='subCart(item)'>-</view>
|
||||||
<view class='num'>{{item.split_num}}</view>
|
<view class='num'>{{item.split_num}}</view>
|
||||||
|
@ -161,7 +161,7 @@
|
||||||
<view class="info_sku" v-if="item.cart_info && item.cart_info.productAttr">{{item.cart_info.productAttr.sku}}</view>
|
<view class="info_sku" v-if="item.cart_info && item.cart_info.productAttr">{{item.cart_info.productAttr.sku}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="pro_price" v-if="item.cart_info && item.cart_info.productAttr">
|
<view class="pro_price" v-if="item.cart_info && item.cart_info.productAttr">
|
||||||
<view class="info_price">¥{{item.cart_info.productAttr.procure_price}}</view>
|
<view class="info_price">¥{{item.cart_info.productAttr.wholesale_price}}</view>
|
||||||
<view class="info_num">x{{item.product_num}}</view>
|
<view class="info_num">x{{item.product_num}}</view>
|
||||||
<view class="refund_num" v-if="item.product_num-item.refund_num>0">{{item.product_num-item.refund_num}}件{{item.is_refund==1?'退款中' : item.is_refund==2 ? '已退款' : item.is_refund==3?'全部退款':''}}</view>
|
<view class="refund_num" v-if="item.product_num-item.refund_num>0">{{item.product_num-item.refund_num}}件{{item.is_refund==1?'退款中' : item.is_refund==2 ? '已退款' : item.is_refund==3?'全部退款':''}}</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
|
@ -51,7 +51,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="money">
|
<view class="money">
|
||||||
<view class="x-money">¥{{ item.cart_info.productAttr.procure_price }}</view>
|
<view class="x-money">¥{{ item.cart_info.productAttr.wholesale_price }}</view>
|
||||||
<view class="num">x{{ item.product_num }}
|
<view class="num">x{{ item.product_num }}
|
||||||
<text class="font-color refund_num" v-if="item.product_num-item.refund_num>0">(-{{item.product_num-item.refund_num}})</text>
|
<text class="font-color refund_num" v-if="item.product_num-item.refund_num>0">(-{{item.product_num-item.refund_num}})</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
|
@ -125,7 +125,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="money">
|
<view class="money">
|
||||||
<view class="x-money">¥{{ val.cart_info.productAttr.procure_price }}</view>
|
<view class="x-money">¥{{ val.cart_info.productAttr.wholesale_price }}</view>
|
||||||
<view class="num">x{{ val.product_num }}</view>
|
<view class="num">x{{ val.product_num }}</view>
|
||||||
<!-- <view class="refund-num" v-if="val.product_num-val.refund_num>0">{{val.product_num-val.refund_num}}件{{val.is_refund==1?'退款中' : val.is_refund==2 ? '已退款' : val.is_refund==3?'全部退款':''}}</view> -->
|
<!-- <view class="refund-num" v-if="val.product_num-val.refund_num>0">{{val.product_num-val.refund_num}}件{{val.is_refund==1?'退款中' : val.is_refund==2 ? '已退款' : val.is_refund==3?'全部退款':''}}</view> -->
|
||||||
</view>
|
</view>
|
||||||
|
|
|
@ -78,8 +78,8 @@
|
||||||
<view :class="{'active': storeParam.order=='sales'}" @click="set_where('sales')">销量</view>
|
<view :class="{'active': storeParam.order=='sales'}" @click="set_where('sales')">销量</view>
|
||||||
<!-- <view :class="{'active': storeParam.order.includes('price')}" @click="set_where(price_order)">
|
<!-- <view :class="{'active': storeParam.order.includes('price')}" @click="set_where(price_order)">
|
||||||
<text style="margin-right: 5rpx;">价格</text>
|
<text style="margin-right: 5rpx;">价格</text>
|
||||||
<image class="icon" v-if="price_order=='procure_price_asc'&&storeParam.order.includes('price')" :src="domain+'/static/diy/up'+keyColor+'.png'"></image>
|
<image class="icon" v-if="price_order=='wholesale_price_asc'&&storeParam.order.includes('price')" :src="domain+'/static/diy/up'+keyColor+'.png'"></image>
|
||||||
<image class="icon" v-else-if="price_order=='procure_price_desc'&&storeParam.order.includes('price')" :src="domain+'/static/diy/down'+keyColor+'.png'"></image>
|
<image class="icon" v-else-if="price_order=='wholesale_price_desc'&&storeParam.order.includes('price')" :src="domain+'/static/diy/down'+keyColor+'.png'"></image>
|
||||||
<image class="icon" v-else src='/static/images/horn.png'></image>
|
<image class="icon" v-else src='/static/images/horn.png'></image>
|
||||||
</view> -->
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
|
@ -104,7 +104,7 @@
|
||||||
<view v-else-if="item.unit_name">{{item.unit_name}}</view>
|
<view v-else-if="item.unit_name">{{item.unit_name}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="r_btn" v-if="getAttr(item)">
|
<view class="r_btn" v-if="getAttr(item)">
|
||||||
<view>¥<text style="font-size: 33rpx;">{{ getAttr(item).procure_price.split('.')[0] }}.</text>{{getAttr(item).procure_price.split('.')[1]}}</view>
|
<view>¥<text style="font-size: 33rpx;">{{ getAttr(item).wholesale_price.split('.')[0] }}.</text>{{getAttr(item).wholesale_price.split('.')[1]}}</view>
|
||||||
<image src="@/static/images/icon/plus.png" style="width: 40rpx;height: 40rpx;border-radius: 40rpx;"></image>
|
<image src="@/static/images/icon/plus.png" style="width: 40rpx;height: 40rpx;border-radius: 40rpx;"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -254,7 +254,7 @@
|
||||||
street: "",
|
street: "",
|
||||||
showPicker: false,
|
showPicker: false,
|
||||||
status: "loadmore",
|
status: "loadmore",
|
||||||
price_order: 'procure_price_asc', //价格排序方式(升降), procure_price_asc, procure_price_desc
|
price_order: 'wholesale_price_asc', //价格排序方式(升降), wholesale_price_asc, wholesale_price_desc
|
||||||
// 下拉菜单
|
// 下拉菜单
|
||||||
downMenu: [{
|
downMenu: [{
|
||||||
title: '默认',
|
title: '默认',
|
||||||
|
@ -685,8 +685,8 @@
|
||||||
// this.storeParam.order = 'location' //使用距离进行排序
|
// this.storeParam.order = 'location' //使用距离进行排序
|
||||||
this.storeParam.order = e //选择排序方式
|
this.storeParam.order = e //选择排序方式
|
||||||
this.getStoreList();
|
this.getStoreList();
|
||||||
if(e=='procure_price_asc') return this.price_order = 'procure_price_desc';
|
if(e=='wholesale_price_asc') return this.price_order = 'wholesale_price_desc';
|
||||||
if(e=='procure_price_desc') return this.price_order = 'procure_price_asc';
|
if(e=='wholesale_price_desc') return this.price_order = 'wholesale_price_asc';
|
||||||
},
|
},
|
||||||
backjJump() {
|
backjJump() {
|
||||||
uni.navigateBack({
|
uni.navigateBack({
|
||||||
|
@ -785,7 +785,7 @@
|
||||||
this.cartList = res.data.list
|
this.cartList = res.data.list
|
||||||
this.cartList.forEach(e => {
|
this.cartList.forEach(e => {
|
||||||
e.list.forEach(item => {
|
e.list.forEach(item => {
|
||||||
this.totalMoney += item.cart_num * item.productAttr.procure_price
|
this.totalMoney += item.cart_num * item.productAttr.wholesale_price
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
this.totalMoney = this.totalMoney.toFixed(2)
|
this.totalMoney = this.totalMoney.toFixed(2)
|
||||||
|
|
|
@ -78,8 +78,8 @@
|
||||||
<view :class="{'active': storeParam.order=='sales'}" @click="set_where('sales')">销量</view>
|
<view :class="{'active': storeParam.order=='sales'}" @click="set_where('sales')">销量</view>
|
||||||
<!-- <view :class="{'active': storeParam.order.includes('price')}" @click="set_where(price_order)">
|
<!-- <view :class="{'active': storeParam.order.includes('price')}" @click="set_where(price_order)">
|
||||||
<text style="margin-right: 5rpx;">价格</text>
|
<text style="margin-right: 5rpx;">价格</text>
|
||||||
<image class="icon" v-if="price_order=='procure_price_asc'&&storeParam.order.includes('price')" :src="domain+'/static/diy/up'+keyColor+'.png'"></image>
|
<image class="icon" v-if="price_order=='wholesale_price_asc'&&storeParam.order.includes('price')" :src="domain+'/static/diy/up'+keyColor+'.png'"></image>
|
||||||
<image class="icon" v-else-if="price_order=='procure_price_desc'&&storeParam.order.includes('price')" :src="domain+'/static/diy/down'+keyColor+'.png'"></image>
|
<image class="icon" v-else-if="price_order=='wholesale_price_desc'&&storeParam.order.includes('price')" :src="domain+'/static/diy/down'+keyColor+'.png'"></image>
|
||||||
<image class="icon" v-else src='/static/images/horn.png'></image>
|
<image class="icon" v-else src='/static/images/horn.png'></image>
|
||||||
</view> -->
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
|
@ -104,7 +104,7 @@
|
||||||
<view v-else-if="item.unit_name">{{item.unit_name}}</view>
|
<view v-else-if="item.unit_name">{{item.unit_name}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="r_btn" v-if="getAttr(item)">
|
<view class="r_btn" v-if="getAttr(item)">
|
||||||
<view>¥<text style="font-size: 33rpx;">{{ getAttr(item).procure_price.split('.')[0] }}.</text>{{getAttr(item).procure_price.split('.')[1]}}</view>
|
<view>¥<text style="font-size: 33rpx;">{{ getAttr(item).wholesale_price.split('.')[0] }}.</text>{{getAttr(item).wholesale_price.split('.')[1]}}</view>
|
||||||
<image src="@/static/images/icon/plus.png" style="width: 40rpx;height: 40rpx;border-radius: 40rpx;"></image>
|
<image src="@/static/images/icon/plus.png" style="width: 40rpx;height: 40rpx;border-radius: 40rpx;"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -253,7 +253,7 @@
|
||||||
street: "",
|
street: "",
|
||||||
showPicker: false,
|
showPicker: false,
|
||||||
status: "loadmore",
|
status: "loadmore",
|
||||||
price_order: 'procure_price_asc', //价格排序方式(升降), procure_price_asc, procure_price_desc
|
price_order: 'wholesale_price_asc', //价格排序方式(升降), wholesale_price_asc, wholesale_price_desc
|
||||||
// 下拉菜单
|
// 下拉菜单
|
||||||
downMenu: [{
|
downMenu: [{
|
||||||
title: '默认',
|
title: '默认',
|
||||||
|
@ -681,8 +681,8 @@
|
||||||
// this.storeParam.order = 'location' //使用距离进行排序
|
// this.storeParam.order = 'location' //使用距离进行排序
|
||||||
this.storeParam.order = e //选择排序方式
|
this.storeParam.order = e //选择排序方式
|
||||||
this.getStoreList();
|
this.getStoreList();
|
||||||
if(e=='procure_price_asc') return this.price_order = 'procure_price_desc';
|
if(e=='wholesale_price_asc') return this.price_order = 'wholesale_price_desc';
|
||||||
if(e=='procure_price_desc') return this.price_order = 'procure_price_asc';
|
if(e=='wholesale_price_desc') return this.price_order = 'wholesale_price_asc';
|
||||||
},
|
},
|
||||||
backjJump() {
|
backjJump() {
|
||||||
uni.navigateBack({
|
uni.navigateBack({
|
||||||
|
@ -780,7 +780,7 @@
|
||||||
this.cartList = res.data.list
|
this.cartList = res.data.list
|
||||||
this.cartList.forEach(e => {
|
this.cartList.forEach(e => {
|
||||||
e.list.forEach(item => {
|
e.list.forEach(item => {
|
||||||
this.totalMoney += item.cart_num * item.productAttr.procure_price
|
this.totalMoney += item.cart_num * item.productAttr.wholesale_price
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
this.totalMoney = this.totalMoney.toFixed(2)
|
this.totalMoney = this.totalMoney.toFixed(2)
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
<view class="right_goods_msg">
|
<view class="right_goods_msg">
|
||||||
<view class="num">
|
<view class="num">
|
||||||
<text style="margin-right: 5rpx;">¥</text>
|
<text style="margin-right: 5rpx;">¥</text>
|
||||||
<text>{{$procure_price(item)}}</text>
|
<text>{{$wholesale_price(item)}}</text>
|
||||||
</view>
|
</view>
|
||||||
<!-- <view class="add_goods" @click="getGoodsDetails(item)">加入购物单</view> -->
|
<!-- <view class="add_goods" @click="getGoodsDetails(item)">加入购物单</view> -->
|
||||||
</view>
|
</view>
|
||||||
|
|
|
@ -58,7 +58,7 @@
|
||||||
v-if="goods.product.once_max_count>0">最多{{goods.product.once_max_count}}件</text>
|
v-if="goods.product.once_max_count>0">最多{{goods.product.once_max_count}}件</text>
|
||||||
</view>
|
</view>
|
||||||
<view class='money acea-row row-middle'>
|
<view class='money acea-row row-middle'>
|
||||||
<text>¥{{goods.productAttr.procure_price}}</text>
|
<text>¥{{goods.productAttr.wholesale_price}}</text>
|
||||||
<view v-if="goods.productAttr.show_svip_price" class="vipImg">
|
<view v-if="goods.productAttr.show_svip_price" class="vipImg">
|
||||||
<image src="/static/images/svip.png"></image>
|
<image src="/static/images/svip.png"></image>
|
||||||
</view>
|
</view>
|
||||||
|
@ -238,7 +238,7 @@
|
||||||
cartAttr: false,
|
cartAttr: false,
|
||||||
productAttr: [],
|
productAttr: [],
|
||||||
productSelect: {
|
productSelect: {
|
||||||
procure_price: ''
|
wholesale_price: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
isOpen: false, //是否打开属性组件
|
isOpen: false, //是否打开属性组件
|
||||||
|
@ -428,7 +428,7 @@
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : goods.product
|
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : goods.product
|
||||||
.image);
|
.image);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
|
@ -448,7 +448,7 @@
|
||||||
);
|
);
|
||||||
this.$set(this.attr.productSelect, "image", goods.product.image);
|
this.$set(this.attr.productSelect, "image", goods.product.image);
|
||||||
this.$set(this.attr.productSelect, "price", goods.product.price);
|
this.$set(this.attr.productSelect, "price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", goods.product.price);
|
this.$set(this.attr.productSelect, "wholesale_price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", 0);
|
this.$set(this.attr.productSelect, "stock", 0);
|
||||||
this.$set(this.attr.productSelect, "unique", "");
|
this.$set(this.attr.productSelect, "unique", "");
|
||||||
|
@ -464,7 +464,7 @@
|
||||||
);
|
);
|
||||||
this.$set(this.attr.productSelect, "image", goods.product.image);
|
this.$set(this.attr.productSelect, "image", goods.product.image);
|
||||||
this.$set(this.attr.productSelect, "price", goods.product.price);
|
this.$set(this.attr.productSelect, "price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", goods.product.price);
|
this.$set(this.attr.productSelect, "wholesale_price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", goods.product.stock);
|
this.$set(this.attr.productSelect, "stock", goods.product.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", goods.product.unique || "");
|
this.$set(this.attr.productSelect, "unique", goods.product.unique || "");
|
||||||
|
@ -476,7 +476,7 @@
|
||||||
this.$set(this.attr.productSelect, "store_name", goods.product.store_name);
|
this.$set(this.attr.productSelect, "store_name", goods.product.store_name);
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image);
|
this.$set(this.attr.productSelect, "image", productSelect.image);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
|
@ -551,7 +551,7 @@
|
||||||
if (productSelect && productSelect.stock > 0) {
|
if (productSelect && productSelect.stock > 0) {
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
this.$set(this, "uniqueValue", productSelect.unique);
|
this.$set(this, "uniqueValue", productSelect.unique);
|
||||||
|
@ -560,7 +560,7 @@
|
||||||
} else {
|
} else {
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "stock", 0);
|
this.$set(this.attr.productSelect, "stock", 0);
|
||||||
this.$set(this.attr.productSelect, "unique", "");
|
this.$set(this.attr.productSelect, "unique", "");
|
||||||
this.$set(this.attr.productSelect, "cart_num", 0);
|
this.$set(this.attr.productSelect, "cart_num", 0);
|
||||||
|
@ -849,7 +849,7 @@
|
||||||
// 总金额 //总数
|
// 总金额 //总数
|
||||||
el.list.forEach(e => {
|
el.list.forEach(e => {
|
||||||
if (e.check) {
|
if (e.check) {
|
||||||
totalMoney = this.$util.$h.Add(totalMoney, this.$util.$h.Mul(e.productAttr.procure_price, e.cart_num))
|
totalMoney = this.$util.$h.Add(totalMoney, this.$util.$h.Mul(e.productAttr.wholesale_price, e.cart_num))
|
||||||
totalNum += +e.cart_num
|
totalNum += +e.cart_num
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -52,7 +52,7 @@
|
||||||
v-if="goods.product.once_max_count>0">,最多{{goods.product.once_max_count}}件</text>
|
v-if="goods.product.once_max_count>0">,最多{{goods.product.once_max_count}}件</text>
|
||||||
</view>
|
</view>
|
||||||
<view class='money acea-row row-middle'>
|
<view class='money acea-row row-middle'>
|
||||||
<text>¥{{goods.productAttr.procure_price}}</text>
|
<text>¥{{goods.productAttr.wholesale_price}}</text>
|
||||||
<view v-if="goods.productAttr.show_svip_price" class="vipImg">
|
<view v-if="goods.productAttr.show_svip_price" class="vipImg">
|
||||||
<image src="/static/images/svip.png"></image>
|
<image src="/static/images/svip.png"></image>
|
||||||
</view>
|
</view>
|
||||||
|
@ -232,7 +232,7 @@
|
||||||
cartAttr: false,
|
cartAttr: false,
|
||||||
productAttr: [],
|
productAttr: [],
|
||||||
productSelect: {
|
productSelect: {
|
||||||
procure_price: ''
|
wholesale_price: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
isOpen: false, //是否打开属性组件
|
isOpen: false, //是否打开属性组件
|
||||||
|
@ -422,7 +422,7 @@
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : goods.product
|
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : goods.product
|
||||||
.image);
|
.image);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
|
@ -442,7 +442,7 @@
|
||||||
);
|
);
|
||||||
this.$set(this.attr.productSelect, "image", goods.product.image);
|
this.$set(this.attr.productSelect, "image", goods.product.image);
|
||||||
this.$set(this.attr.productSelect, "price", goods.product.price);
|
this.$set(this.attr.productSelect, "price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", goods.product.price);
|
this.$set(this.attr.productSelect, "wholesale_price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", 0);
|
this.$set(this.attr.productSelect, "stock", 0);
|
||||||
this.$set(this.attr.productSelect, "unique", "");
|
this.$set(this.attr.productSelect, "unique", "");
|
||||||
|
@ -458,7 +458,7 @@
|
||||||
);
|
);
|
||||||
this.$set(this.attr.productSelect, "image", goods.product.image);
|
this.$set(this.attr.productSelect, "image", goods.product.image);
|
||||||
this.$set(this.attr.productSelect, "price", goods.product.price);
|
this.$set(this.attr.productSelect, "price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", goods.product.price);
|
this.$set(this.attr.productSelect, "wholesale_price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", goods.product.stock);
|
this.$set(this.attr.productSelect, "stock", goods.product.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", goods.product.unique || "");
|
this.$set(this.attr.productSelect, "unique", goods.product.unique || "");
|
||||||
|
@ -470,7 +470,7 @@
|
||||||
this.$set(this.attr.productSelect, "store_name", goods.product.store_name);
|
this.$set(this.attr.productSelect, "store_name", goods.product.store_name);
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image);
|
this.$set(this.attr.productSelect, "image", productSelect.image);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
|
@ -545,7 +545,7 @@
|
||||||
if (productSelect && productSelect.stock > 0) {
|
if (productSelect && productSelect.stock > 0) {
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
this.$set(this, "uniqueValue", productSelect.unique);
|
this.$set(this, "uniqueValue", productSelect.unique);
|
||||||
|
@ -554,7 +554,7 @@
|
||||||
} else {
|
} else {
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "stock", 0);
|
this.$set(this.attr.productSelect, "stock", 0);
|
||||||
this.$set(this.attr.productSelect, "unique", "");
|
this.$set(this.attr.productSelect, "unique", "");
|
||||||
this.$set(this.attr.productSelect, "cart_num", 0);
|
this.$set(this.attr.productSelect, "cart_num", 0);
|
||||||
|
@ -836,7 +836,7 @@
|
||||||
// 总金额 //总数
|
// 总金额 //总数
|
||||||
el.list.forEach(e => {
|
el.list.forEach(e => {
|
||||||
if (e.check) {
|
if (e.check) {
|
||||||
totalMoney = this.$util.$h.Add(totalMoney, this.$util.$h.Mul(e.productAttr.procure_price, e.cart_num))
|
totalMoney = this.$util.$h.Add(totalMoney, this.$util.$h.Mul(e.productAttr.wholesale_price, e.cart_num))
|
||||||
totalNum += +e.cart_num
|
totalNum += +e.cart_num
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -52,7 +52,7 @@
|
||||||
v-if="goods.product.once_max_count>0">最多{{goods.product.once_max_count}}件</text>
|
v-if="goods.product.once_max_count>0">最多{{goods.product.once_max_count}}件</text>
|
||||||
</view>
|
</view>
|
||||||
<view class='money acea-row row-middle'>
|
<view class='money acea-row row-middle'>
|
||||||
<text>¥{{goods.productAttr.procure_price}}</text>
|
<text>¥{{goods.productAttr.wholesale_price}}</text>
|
||||||
<view v-if="goods.productAttr.show_svip_price" class="vipImg">
|
<view v-if="goods.productAttr.show_svip_price" class="vipImg">
|
||||||
<image src="/static/images/svip.png"></image>
|
<image src="/static/images/svip.png"></image>
|
||||||
</view>
|
</view>
|
||||||
|
@ -232,7 +232,7 @@
|
||||||
cartAttr: false,
|
cartAttr: false,
|
||||||
productAttr: [],
|
productAttr: [],
|
||||||
productSelect: {
|
productSelect: {
|
||||||
procure_price: ''
|
wholesale_price: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
isOpen: false, //是否打开属性组件
|
isOpen: false, //是否打开属性组件
|
||||||
|
@ -424,7 +424,7 @@
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : goods.product
|
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : goods.product
|
||||||
.image);
|
.image);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
|
@ -444,7 +444,7 @@
|
||||||
);
|
);
|
||||||
this.$set(this.attr.productSelect, "image", goods.product.image);
|
this.$set(this.attr.productSelect, "image", goods.product.image);
|
||||||
this.$set(this.attr.productSelect, "price", goods.product.price);
|
this.$set(this.attr.productSelect, "price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", goods.product.price);
|
this.$set(this.attr.productSelect, "wholesale_price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", 0);
|
this.$set(this.attr.productSelect, "stock", 0);
|
||||||
this.$set(this.attr.productSelect, "unique", "");
|
this.$set(this.attr.productSelect, "unique", "");
|
||||||
|
@ -460,7 +460,7 @@
|
||||||
);
|
);
|
||||||
this.$set(this.attr.productSelect, "image", goods.product.image);
|
this.$set(this.attr.productSelect, "image", goods.product.image);
|
||||||
this.$set(this.attr.productSelect, "price", goods.product.price);
|
this.$set(this.attr.productSelect, "price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", goods.product.price);
|
this.$set(this.attr.productSelect, "wholesale_price", goods.product.price);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", goods.product.stock);
|
this.$set(this.attr.productSelect, "stock", goods.product.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", goods.product.unique || "");
|
this.$set(this.attr.productSelect, "unique", goods.product.unique || "");
|
||||||
|
@ -472,7 +472,7 @@
|
||||||
this.$set(this.attr.productSelect, "store_name", goods.product.store_name);
|
this.$set(this.attr.productSelect, "store_name", goods.product.store_name);
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image);
|
this.$set(this.attr.productSelect, "image", productSelect.image);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
|
@ -547,7 +547,7 @@
|
||||||
if (productSelect && productSelect.stock > 0) {
|
if (productSelect && productSelect.stock > 0) {
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
this.$set(this, "uniqueValue", productSelect.unique);
|
this.$set(this, "uniqueValue", productSelect.unique);
|
||||||
|
@ -556,7 +556,7 @@
|
||||||
} else {
|
} else {
|
||||||
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
this.$set(this.attr.productSelect, "image", productSelect.image ? productSelect.image : this.attrImage);
|
||||||
this.$set(this.attr.productSelect, "price", productSelect.price);
|
this.$set(this.attr.productSelect, "price", productSelect.price);
|
||||||
this.$set(this.attr.productSelect, "procure_price", productSelect.procure_price);
|
this.$set(this.attr.productSelect, "wholesale_price", productSelect.wholesale_price);
|
||||||
this.$set(this.attr.productSelect, "stock", 0);
|
this.$set(this.attr.productSelect, "stock", 0);
|
||||||
this.$set(this.attr.productSelect, "unique", "");
|
this.$set(this.attr.productSelect, "unique", "");
|
||||||
this.$set(this.attr.productSelect, "cart_num", 0);
|
this.$set(this.attr.productSelect, "cart_num", 0);
|
||||||
|
@ -844,7 +844,7 @@
|
||||||
// 总金额 //总数
|
// 总金额 //总数
|
||||||
el.list.forEach(e => {
|
el.list.forEach(e => {
|
||||||
if (e.check) {
|
if (e.check) {
|
||||||
totalMoney = this.$util.$h.Add(totalMoney, this.$util.$h.Mul(e.productAttr.procure_price, e.cart_num))
|
totalMoney = this.$util.$h.Add(totalMoney, this.$util.$h.Mul(e.productAttr.wholesale_price, e.cart_num))
|
||||||
totalNum += +e.cart_num
|
totalNum += +e.cart_num
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -933,8 +933,8 @@
|
||||||
});
|
});
|
||||||
getOtherOrderDetail(that.order_id).then(res => {
|
getOtherOrderDetail(that.order_id).then(res => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
res.data.orderProduct[0].cart_info.productAttr.price = res.data.orderProduct[0].cart_info.productAttr.procure_price;
|
res.data.orderProduct[0].cart_info.productAttr.price = res.data.orderProduct[0].cart_info.productAttr.wholesale_price;
|
||||||
res.data.orderProduct[0].cart_info.product.price = res.data.orderProduct[0].cart_info.productAttr.procure_price;
|
res.data.orderProduct[0].cart_info.product.price = res.data.orderProduct[0].cart_info.productAttr.wholesale_price;
|
||||||
that.$set(that, 'orderInfo', res.data);
|
that.$set(that, 'orderInfo', res.data);
|
||||||
that.orderInfo.take = res.data.take;
|
that.orderInfo.take = res.data.take;
|
||||||
that.$set(that, 'cartInfo', res.data.orderProduct);
|
that.$set(that, 'cartInfo', res.data.orderProduct);
|
||||||
|
|
|
@ -346,7 +346,7 @@
|
||||||
// "cost": "1",
|
// "cost": "1",
|
||||||
// "stock": "11",
|
// "stock": "11",
|
||||||
// "ot_price": "",
|
// "ot_price": "",
|
||||||
// "procure_price": "",
|
// "wholesale_price": "",
|
||||||
// "bar_code": "666",
|
// "bar_code": "666",
|
||||||
// "weight": "10",
|
// "weight": "10",
|
||||||
// "volume": "5",
|
// "volume": "5",
|
||||||
|
@ -636,7 +636,7 @@
|
||||||
if (typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
if (typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
||||||
let showFlag = '';
|
let showFlag = '';
|
||||||
postData.attrValue.forEach(t => {
|
postData.attrValue.forEach(t => {
|
||||||
if (userInfo?.mer_info?.type_code == "TypeSupplyChain" && (!t.procure_price || +t.procure_price <= 0)) {
|
if (userInfo.mer_info.wholesale && (!t.wholesale_price || +t.wholesale_price <= 0)) {
|
||||||
showFlag = '批发价不能小于0'
|
showFlag = '批发价不能小于0'
|
||||||
}
|
}
|
||||||
if (!t.price || +t.price <= 0) showFlag = '零售价不能小于0';
|
if (!t.price || +t.price <= 0) showFlag = '零售价不能小于0';
|
||||||
|
|
|
@ -346,7 +346,7 @@
|
||||||
// "cost": "1",
|
// "cost": "1",
|
||||||
// "stock": "11",
|
// "stock": "11",
|
||||||
// "ot_price": "",
|
// "ot_price": "",
|
||||||
// "procure_price": "",
|
// "wholesale_price": "",
|
||||||
// "bar_code": "666",
|
// "bar_code": "666",
|
||||||
// "weight": "10",
|
// "weight": "10",
|
||||||
// "volume": "5",
|
// "volume": "5",
|
||||||
|
@ -636,7 +636,7 @@
|
||||||
if (typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
if (typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
||||||
let showFlag = '';
|
let showFlag = '';
|
||||||
postData.attrValue.forEach(t => {
|
postData.attrValue.forEach(t => {
|
||||||
if (userInfo?.mer_info?.type_code == "TypeSupplyChain" && (!t.procure_price || +t.procure_price <= 0)) {
|
if (userInfo.mer_info.wholesale && (!t.wholesale_price || +t.wholesale_price <= 0)) {
|
||||||
showFlag = '批发价不能小于0'
|
showFlag = '批发价不能小于0'
|
||||||
}
|
}
|
||||||
if (!t.price || +t.price <= 0) showFlag = '零售价不能小于0';
|
if (!t.price || +t.price <= 0) showFlag = '零售价不能小于0';
|
||||||
|
|
|
@ -365,7 +365,7 @@
|
||||||
// "cost": "1",
|
// "cost": "1",
|
||||||
// "stock": "11",
|
// "stock": "11",
|
||||||
// "ot_price": "",
|
// "ot_price": "",
|
||||||
// "procure_price": "",
|
// "wholesale_price": "",
|
||||||
// "bar_code": "666",
|
// "bar_code": "666",
|
||||||
// "weight": "10",
|
// "weight": "10",
|
||||||
// "volume": "5",
|
// "volume": "5",
|
||||||
|
@ -683,7 +683,7 @@
|
||||||
if (typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
if (typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
||||||
let showFlag = '';
|
let showFlag = '';
|
||||||
postData.attrValue.forEach(t => {
|
postData.attrValue.forEach(t => {
|
||||||
if (userInfo?.mer_info?.type_code == "TypeSupplyChain" && (!t.procure_price || +t.procure_price <= 0)) {
|
if (userInfo.mer_info.wholesale && (!t.wholesale_price || +t.wholesale_price <= 0)) {
|
||||||
showFlag = '结算价不能小于0'
|
showFlag = '结算价不能小于0'
|
||||||
}
|
}
|
||||||
if (!t.price || +t.price <= 0) showFlag = '零售价不能小于0';
|
if (!t.price || +t.price <= 0) showFlag = '零售价不能小于0';
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
cost: '', // 成本价
|
cost: '', // 成本价
|
||||||
stock: '', // 库存
|
stock: '', // 库存
|
||||||
ot_price: '', // 市场价
|
ot_price: '', // 市场价
|
||||||
procure_price: '', // 批发价
|
wholesale_price: '', // 批发价
|
||||||
bar_code: '', // 商品条码
|
bar_code: '', // 商品条码
|
||||||
weight: '', // 重量
|
weight: '', // 重量
|
||||||
volume: '', // 体积
|
volume: '', // 体积
|
||||||
|
@ -129,13 +129,13 @@
|
||||||
let userInfo = this.$store.state.app.userInfo;
|
let userInfo = this.$store.state.app.userInfo;
|
||||||
if(typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
if(typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
||||||
// 市级供应链才需填写批发价
|
// 市级供应链才需填写批发价
|
||||||
if(userInfo.mer_info?.type_code=="TypeSupplyChain"){
|
if(userInfo.mer_info?.wholesale){
|
||||||
this.formList.unshift({
|
this.formList.unshift({
|
||||||
id: 3,
|
id: 3,
|
||||||
label: '批发价',
|
label: '批发价',
|
||||||
type: 'digit',
|
type: 'digit',
|
||||||
holder: '请填写批发价',
|
holder: '请填写批发价',
|
||||||
model: 'procure_price',
|
model: 'wholesale_price',
|
||||||
require: true,
|
require: true,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
cost: '', // 成本价
|
cost: '', // 成本价
|
||||||
stock: '', // 库存
|
stock: '', // 库存
|
||||||
ot_price: '', // 市场价
|
ot_price: '', // 市场价
|
||||||
procure_price: '', // 批发价
|
wholesale_price: '', // 批发价
|
||||||
bar_code: '', // 商品条码
|
bar_code: '', // 商品条码
|
||||||
weight: '', // 重量
|
weight: '', // 重量
|
||||||
volume: '', // 体积
|
volume: '', // 体积
|
||||||
|
@ -137,7 +137,7 @@
|
||||||
label: '批发价',
|
label: '批发价',
|
||||||
type: 'digit',
|
type: 'digit',
|
||||||
holder: '请填写批发价',
|
holder: '请填写批发价',
|
||||||
model: 'procure_price',
|
model: 'wholesale_price',
|
||||||
require: true,
|
require: true,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,7 +34,7 @@
|
||||||
cost: '', // 成本价
|
cost: '', // 成本价
|
||||||
stock: '', // 库存
|
stock: '', // 库存
|
||||||
ot_price: '', // 市场价
|
ot_price: '', // 市场价
|
||||||
procure_price: '', // 结算价
|
wholesale_price: '', // 批发价
|
||||||
bar_code: '', // 商品条码
|
bar_code: '', // 商品条码
|
||||||
weight: '', // 重量
|
weight: '', // 重量
|
||||||
volume: '', // 体积
|
volume: '', // 体积
|
||||||
|
@ -61,10 +61,10 @@
|
||||||
require: true,
|
require: true,
|
||||||
},{
|
},{
|
||||||
id: 3,
|
id: 3,
|
||||||
label: '结算价',
|
label: '批发价',
|
||||||
type: 'digit',
|
type: 'digit',
|
||||||
holder: '请填写结算价',
|
holder: '请填写批发价',
|
||||||
model: 'procure_price',
|
model: 'wholesale_price',
|
||||||
require: true,
|
require: true,
|
||||||
}, {
|
}, {
|
||||||
id: 10,
|
id: 10,
|
||||||
|
@ -155,7 +155,7 @@
|
||||||
|
|
||||||
let userInfo = this.$store.state.app.userInfo;
|
let userInfo = this.$store.state.app.userInfo;
|
||||||
if(typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
if(typeof userInfo == 'string') userInfo = JSON.parse(userInfo);
|
||||||
// 市级供应链才需填写结算价
|
// 市级供应链才需填写批发价
|
||||||
// if(userInfo.mer_info?.type_code=="TypeSupplyChain"){
|
// if(userInfo.mer_info?.type_code=="TypeSupplyChain"){
|
||||||
// let list = []
|
// let list = []
|
||||||
// this.formList = [...list, ...this.formList]
|
// this.formList = [...list, ...this.formList]
|
||||||
|
|
|
@ -138,6 +138,7 @@
|
||||||
"cost": "",
|
"cost": "",
|
||||||
"ot_price": "",
|
"ot_price": "",
|
||||||
"price": "",
|
"price": "",
|
||||||
|
"wholesale_price": "",
|
||||||
"volume": "",
|
"volume": "",
|
||||||
"weight": "",
|
"weight": "",
|
||||||
},
|
},
|
||||||
|
@ -420,7 +421,7 @@
|
||||||
// flag = false;
|
// flag = false;
|
||||||
// str = '成本价不能小于等于0';
|
// str = '成本价不能小于等于0';
|
||||||
// }
|
// }
|
||||||
else if ((!item.procure_price||+item.procure_price<=0) && this.userInfo.mer_info.type_code == 'TypeSupplyChain') {
|
else if ((!item.wholesale_price||+item.wholesale_price<=0) && this.userInfo.mer_info.wholesale) {
|
||||||
flag = false;
|
flag = false;
|
||||||
str = '批发价不能小于等于0';
|
str = '批发价不能小于等于0';
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,7 +30,7 @@
|
||||||
cost: '', // 成本价
|
cost: '', // 成本价
|
||||||
stock: '', // 库存
|
stock: '', // 库存
|
||||||
ot_price: '', // 市场价
|
ot_price: '', // 市场价
|
||||||
procure_price: '', // 批发价
|
wholesale_price: '', // 批发价
|
||||||
bar_code: '', // 商品条码
|
bar_code: '', // 商品条码
|
||||||
weight: '', // 重量
|
weight: '', // 重量
|
||||||
volume: '', // 体积
|
volume: '', // 体积
|
||||||
|
@ -159,7 +159,7 @@
|
||||||
label: '批发价',
|
label: '批发价',
|
||||||
type: 'digit',
|
type: 'digit',
|
||||||
holder: '请填写批发价',
|
holder: '请填写批发价',
|
||||||
model: 'procure_price',
|
model: 'wholesale_price',
|
||||||
require: true,
|
require: true,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
@ -271,7 +271,7 @@
|
||||||
if(!postData.unit_name||postData.unit_name?.trim().length<=0)return Toast('请输入商品单位');
|
if(!postData.unit_name||postData.unit_name?.trim().length<=0)return Toast('请输入商品单位');
|
||||||
let userInfo = this.$store.state.app.userInfo;
|
let userInfo = this.$store.state.app.userInfo;
|
||||||
if(typeof userInfo == 'string')userInfo= JSON.parse(userInfo);
|
if(typeof userInfo == 'string')userInfo= JSON.parse(userInfo);
|
||||||
if(userInfo?.mer_info?.type_code=="TypeSupplyChain" && (!postData.attrValue[0]?.procure_price||postData.attrValue[0]?.procure_price<=0) )return Toast('批发价不能小于0');
|
if(userInfo?.mer_info?.type_code=="TypeSupplyChain" && (!postData.attrValue[0]?.wholesale_price||postData.attrValue[0]?.wholesale_price<=0) )return Toast('批发价不能小于0');
|
||||||
if(!postData.attrValue[0]?.price||postData.attrValue[0]?.price<=0)return Toast('零售价不能小于0');
|
if(!postData.attrValue[0]?.price||postData.attrValue[0]?.price<=0)return Toast('零售价不能小于0');
|
||||||
if(!postData.stock||postData.stock<0)return Toast('库存不能小于0');
|
if(!postData.stock||postData.stock<0)return Toast('库存不能小于0');
|
||||||
// if(!postData.attrValue[0]?.cost||postData.attrValue[0]?.cost<=0)return Toast('成本价不能小于0');
|
// if(!postData.attrValue[0]?.cost||postData.attrValue[0]?.cost<=0)return Toast('成本价不能小于0');
|
||||||
|
|
|
@ -47,7 +47,7 @@
|
||||||
<view class="shop_list_item_shop_con_price">
|
<view class="shop_list_item_shop_con_price">
|
||||||
<block v-if="mer_info.type_code=='TypeSupplyChain'">
|
<block v-if="mer_info.type_code=='TypeSupplyChain'">
|
||||||
<block v-if="item.attrValue[0]">
|
<block v-if="item.attrValue[0]">
|
||||||
<text class='price font-color'>¥{{item.attrValue[0].procure_price}}</text>
|
<text class='price font-color'>¥{{item.attrValue[0].wholesale_price}}</text>
|
||||||
<text class='ot_price'>零售价¥{{item.attrValue[0].price}}</text>
|
<text class='ot_price'>零售价¥{{item.attrValue[0].price}}</text>
|
||||||
</block>
|
</block>
|
||||||
<text v-else class='ot_price'>商品规格错误</text>
|
<text v-else class='ot_price'>商品规格错误</text>
|
||||||
|
|
|
@ -122,7 +122,7 @@
|
||||||
<view class='money-wrap'>
|
<view class='money-wrap'>
|
||||||
<block v-if="mer_info.type_code=='TypeSupplyChain'">
|
<block v-if="mer_info.type_code=='TypeSupplyChain'">
|
||||||
<block v-if="item.attrValue[0]">
|
<block v-if="item.attrValue[0]">
|
||||||
<text class='price font-color'>¥{{item.attrValue[0].procure_price}}</text>
|
<text class='price font-color'>¥{{item.attrValue[0].wholesale_price}}</text>
|
||||||
<text class='ot_price'>零售价¥{{item.attrValue[0].price}}</text>
|
<text class='ot_price'>零售价¥{{item.attrValue[0].price}}</text>
|
||||||
</block>
|
</block>
|
||||||
<text v-else class='ot_price'>商品规格错误</text>
|
<text v-else class='ot_price'>商品规格错误</text>
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view v-if="item.resale_type!=1" class="txt-b-b"
|
<view v-if="item.resale_type!=1" class="txt-b-b"
|
||||||
style="font-size: 28rpx;font-family: SF Pro Display-Regular, SF Pro Display;font-weight: 400;color: #999999;">
|
style="font-size: 28rpx;font-family: SF Pro Display-Regular, SF Pro Display;font-weight: 400;color: #999999;">
|
||||||
结算价:¥{{item.discount_price}}
|
批发价:¥{{item.discount_price}}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
|
|
@ -134,7 +134,7 @@
|
||||||
<view>x{{goods.product_num}}</view>
|
<view>x{{goods.product_num}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-else class='money'>
|
<view v-else class='money'>
|
||||||
<view>¥{{goods.cart_info.productAttr.procure_price}}</view>
|
<view>¥{{goods.cart_info.productAttr.wholesale_price}}</view>
|
||||||
<view>x{{goods.product_num}}</view>
|
<view>x{{goods.product_num}}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -239,7 +239,7 @@
|
||||||
<view>x{{goods.product_num}}</view>
|
<view>x{{goods.product_num}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class='money' v-else>
|
<view class='money' v-else>
|
||||||
<view>¥{{goods.cart_info.productAttr.procure_price}}</view>
|
<view>¥{{goods.cart_info.productAttr.wholesale_price}}</view>
|
||||||
<view>x{{goods.product_num}}</view>
|
<view>x{{goods.product_num}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="item.pay_type==8"
|
<view v-if="item.pay_type==8"
|
||||||
|
|
Loading…
Reference in New Issue