Compare commits

..

No commits in common. "44a4d393c65c550a667b1af78f94184e2bf7486f" and "134e9cbe6ef2b58f900e17957d59ec072af2075f" have entirely different histories.

3 changed files with 6 additions and 19 deletions

View File

@ -30,12 +30,9 @@
<view class="fz28 tc l-h-18 m-t-12">{{sku.name}}</view>
<view class="flex1 flex msb mac">
<view class="m-l-12 fcm">
<text v-if="priceDifference(sku.id)<0">
<text v-if="priceDifference(sku.id)!==0">
{{priceDifference(sku.id) | formatPrice}}
</text>
<text v-else-if="priceDifference(sku.id)>0">
+{{priceDifference(sku.id) | formatPrice}}
</text>
</view>
<view class="border rad-c m-r-12" :class="isSel(sku.id)?'border-m bg-m':''"
style="width: 40rpx;height: 40rpx;">

View File

@ -127,7 +127,7 @@
},
//
total() {
return Number(this.totalPrice(this.$store.state.cartList))
return this.totalPrice(this.$store.state.cartList)
},
//
transportPrice() {
@ -149,7 +149,7 @@
},
//
fullPrice() {
return Number(this.total) + Number(this.transportPrice) + Number(this.packPrice)
return this.total + this.transportPrice + this.packPrice
},
//
userInfo() {
@ -182,12 +182,11 @@
}).then(res => {
//
if (res.data.status === 1) {
let fullPrice = String(this.fullPrice)
//
this.$store.commit('clearCartList')
//
uni.navigateTo({
url: `/pages/shop/pay?order_sn=${res.data.order_sn}&fullPrice=${fullPrice}`
url: `/pages/shop/pay?order_sn=${res.data.order_sn}`
});
} else if (res.data.status === -1) {
uni.removeStorage({ //

View File

@ -7,32 +7,23 @@
</view>
</u-navbar>
<!-- 价格 -->
<view>{{fullPrice | formatPrice}}</view>
<view></view>
<button @click="pay" type="primary" style="margin-top:200rpx;">确认支付</button>
</view>
</template>
<script>
import {
formatPrice
} from '@/utils/index.js'
export default {
data() {
return {
order_sn: '', //
fullPrice: 0,//
order_sn: '' //
}
},
onLoad(options) {
this.order_sn = options.order_sn; //
this.fullPrice = Number(options.fullPrice); //
},
computed(){
},
filters: {
formatPrice, //
},
methods: {
//