|
@@ -8,7 +8,7 @@
|
|
|
<view class="shop_title">{{pageInfo.name}}</view>
|
|
<view class="shop_title">{{pageInfo.name}}</view>
|
|
|
<view class="shop_intro">
|
|
<view class="shop_intro">
|
|
|
<text v-if="pageInfo.giveDiscount >= 1" style="margin-right: 20upx;">已采购:{{pageInfo.expendAmount || '0.00'}}</text>
|
|
<text v-if="pageInfo.giveDiscount >= 1" style="margin-right: 20upx;">已采购:{{pageInfo.expendAmount || '0.00'}}</text>
|
|
|
- <text v-else style="margin-right: 20upx;color:red;font-weight:700">下单享{{pageInfo.giveDiscount*100}}折</text>
|
|
|
|
|
|
|
+ <text v-else style="margin-right: 20upx;color:red;font-weight:700">下单享{{shareDiscount}}折</text>
|
|
|
<text>欠款:{{pageInfo.debtAmount || '0.00'}}</text></view>
|
|
<text>欠款:{{pageInfo.debtAmount || '0.00'}}</text></view>
|
|
|
</view>
|
|
</view>
|
|
|
<i class="iconfont icondianhua1" v-if="pageInfo.mobile !=''" @tap="toPhone(pageInfo.mobile)"></i>
|
|
<i class="iconfont icondianhua1" v-if="pageInfo.mobile !=''" @tap="toPhone(pageInfo.mobile)"></i>
|
|
@@ -48,6 +48,7 @@
|
|
|
:offVerifyRepertory="true"
|
|
:offVerifyRepertory="true"
|
|
|
:bigCount="getSelectItemById(productItem.id, classItem.classId).bigCount"
|
|
:bigCount="getSelectItemById(productItem.id, classItem.classId).bigCount"
|
|
|
:smallCount="getSelectItemById(productItem.id, classItem.classId).smallCount"
|
|
:smallCount="getSelectItemById(productItem.id, classItem.classId).smallCount"
|
|
|
|
|
+ :discount.sync="pageInfo.giveDiscount"
|
|
|
@customNum="customNum"
|
|
@customNum="customNum"
|
|
|
@add="addEvent"
|
|
@add="addEvent"
|
|
|
@addOneEvent="addCustomNumEvent"
|
|
@addOneEvent="addCustomNumEvent"
|
|
@@ -157,7 +158,8 @@ export default {
|
|
|
shopId:0,
|
|
shopId:0,
|
|
|
infoData:{},
|
|
infoData:{},
|
|
|
xjData:{},
|
|
xjData:{},
|
|
|
- xjDataInfo:{}
|
|
|
|
|
|
|
+ xjDataInfo:{},
|
|
|
|
|
+ shareDiscount:1
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
onPullDownRefresh() {
|
|
onPullDownRefresh() {
|
|
@@ -309,21 +311,27 @@ export default {
|
|
|
this.initGhsData(id,shopId);
|
|
this.initGhsData(id,shopId);
|
|
|
|
|
|
|
|
if(this.option.id == 0) {
|
|
if(this.option.id == 0) {
|
|
|
- return ghsInfo({shopId: this.option.shopId}).then(res => {
|
|
|
|
|
|
|
+ ghsInfo({shopId: this.option.shopId}).then(res => {
|
|
|
this.pageInfo = res.data
|
|
this.pageInfo = res.data
|
|
|
|
|
+ this.createShareDiscount()
|
|
|
uni.setNavigationBarTitle({title: this.pageInfo.name})
|
|
uni.setNavigationBarTitle({title: this.pageInfo.name})
|
|
|
this.option.id = res.data.id;
|
|
this.option.id = res.data.id;
|
|
|
}).catch(err => {})
|
|
}).catch(err => {})
|
|
|
} else {
|
|
} else {
|
|
|
- return getGhsDataApi({id: this.option.id}).then(res => {
|
|
|
|
|
|
|
+ getGhsDataApi({id: this.option.id}).then(res => {
|
|
|
this.pageInfo = res.data
|
|
this.pageInfo = res.data
|
|
|
this.shopId = res.data.shopId
|
|
this.shopId = res.data.shopId
|
|
|
|
|
+ this.createShareDiscount()
|
|
|
uni.setNavigationBarTitle({
|
|
uni.setNavigationBarTitle({
|
|
|
title: this.pageInfo.name
|
|
title: this.pageInfo.name
|
|
|
})
|
|
})
|
|
|
}).catch(err => {})
|
|
}).catch(err => {})
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
|
|
+ createShareDiscount(){
|
|
|
|
|
+ let shareDiscount = this.pageInfo.giveDiscount*100
|
|
|
|
|
+ this.shareDiscount = shareDiscount
|
|
|
|
|
+ },
|
|
|
scroll_detail(options){
|
|
scroll_detail(options){
|
|
|
if(options.detail.scrollTop > 20) {
|
|
if(options.detail.scrollTop > 20) {
|
|
|
this.myClass = 'fadeOut'
|
|
this.myClass = 'fadeOut'
|