作者 zhuwenjin@bronet.cn

海油修改

... ... @@ -49,13 +49,14 @@ App({
console.log(entrance_type);
if (entrance_type == '1' || url == '/getopenid/get' || url.indexOf('address') > -1 || url.indexOf('/wb/wb')>-1) {
//劳保商城入口
baseUrl = 'https://binhai.w.broing.cn/api';
// baseUrl = 'http://bhng.cn/api'
// baseUrl = 'https://binhai.w.broing.cn/api';
baseUrl = 'http://binhai.shs.broing.cn/api'
} else if (entrance_type == '2') {
//工会商城入口
baseUrl = 'https://binhaigh.w.broing.cn/api';
// baseUrl = 'https://binhaigh.w.broing.cn/api';
baseUrl = 'http://gonghui.shs.broing.cn/api'
} else if (entrance_type == '3') {
//工会商城入口
//办公入口
baseUrl = 'https://bgcb.w.broing.cn/api';
}
// 天远甄选
... ... @@ -161,6 +162,7 @@ App({
header: {
'content-type': 'application/x-www-form-urlencoded',
'token': wx.getStorageSync('token') || ''
// 'token': '' || ''
},
success: function (res) { //返回取得的数据
if (res.data.code == '1') {
... ... @@ -356,6 +358,7 @@ App({
shopcarNum: '/shop/shopcarnum', // 购物车数量
orderlist: '/shop/orderlist', // 订单各状态数量
order_read: '/shop/read', // 订单数
orderMixed: '/order/zhifu',
},
globalData: {
login_new: "",
... ...
... ... @@ -8,7 +8,9 @@ Page({
info:[],
item:'',
detail:{},
sel:0
sel:0,
kuaidiList: [],
sum: 0
},
// 复制物流编号
copy(e){
... ... @@ -39,10 +41,35 @@ Page({
this.setData({
item: res.msg.kuaidi[0]
})
this.setData({
id: res.msg.id
})
let sum = 0
this.data.info.forEach(item=>{
sum += item.goods_number
})
this.setData({
sum: sum
})
console.log(sum)
console.log(that.data.info)
// that.getOrderDetail(res.msg.id)
})
},
getOrderDetail(id) {
let that=this
let url = app.interface.orderInfo
let params = {
id: id
}
app.post(url,params).then((res)=>{
res.msg.kuaidi = JSON.parse(res.msg.kuaidi)
console.log(res.msg.kuaidi,'zzzzzzzzzzzzz')
this.setData({
kuaidiList: res.msg.kuaidi
})
})
},
lookMoreInfo(e){
let index = e.currentTarget.dataset.index;
console.log(this.data.info[index]);
... ...
... ... @@ -22,6 +22,9 @@
</view>
<view class="pack" wx:if="{{item.kuaidi.goods_number&&item.kuaidi.goods_number>0}}">当前快递含有{{item.kuaidi.goods_number}}个商品</view>
</view>
<view class="name" style="display: flex;">
<text>订单详情 您的订单总计{{sum}}件商品,本包裹发货{{item.goods_number}}件商品。请注意查验货品,如有疑问请及时联系我方客服。</text>
</view>
<view class="order_box {{item.open?'':'normalHeight'}}">
<view class="order_item" wx:for="{{item.kuaidi.Traces}}" wx:key="index">
<view class="time_box">
... ...
const app = getApp()
Page({
/**
* 页面的初始数据
*/
data: {
success: false,
fail: false,
name: '',
choudanNum:0,
addressId: 0,
tel: '',
area: '',
address: '',
cover_type: false,
total:'',
info:{
address:{
address:'',
area:'',
id:'',
tel:'',
name:''
}
}
},
//加减商品数量
num_change(e) {
let that = this
let num = Number(e.currentTarget.dataset.num)
console.log(num)
let type = e.currentTarget.dataset.type
let index = e.currentTarget.dataset.index
let id = e.currentTarget.dataset.id
let check = e.currentTarget.dataset.check
let coudan = this.data.coudan||[]
let coudan_arr = this.data.coudan_arr||[]
let price = e.currentTarget.dataset.price;
let price2 = e.currentTarget.dataset.price2;
if (type == 1) {
if(this.data.info.choudan*100<(price*100)){
wx.showToast({
title: '当前剩余积分不足,请重新挑选',
icon:'none'
})
return
}
num++
} else {
num--
if (num < 0) {
num = 0;
return
}
}
/**
* 页面的初始数据
*/
data: {
success: false,
fail: false,
name: '',
choudanNum: 0,
addressId: 0,
tel: '',
area: '',
address: '',
cover_type: false,
total: '',
payMent: '',
orderPayMent: '',
info: {
address: {
address: '',
area: '',
id: '',
tel: '',
name: ''
}
if (num<1) {
coudan.forEach((item, index) => {
if (item.id == id) {
coudan.splice(index, 1)
coudan_arr.splice(index, 1)
}
})
} else {
if(type==1&&num==1){
//选中
coudan.push({
id: id,
num: num
})
coudan_arr.push({
id: id,
num: num,
price: Number(price),
price2:Number(price2)
})
}else{
coudan.forEach((item, index) => {
if (item.id == id) {
item.num = num
coudan_arr[index].num = num
},
//加减商品数量
num_change(e) {
let that = this
let num = Number(e.currentTarget.dataset.num)
console.log(num)
let type = e.currentTarget.dataset.type
let index = e.currentTarget.dataset.index
let id = e.currentTarget.dataset.id
let check = e.currentTarget.dataset.check
let coudan = this.data.coudan || []
let coudan_arr = this.data.coudan_arr || []
let price = e.currentTarget.dataset.price;
let price2 = e.currentTarget.dataset.price2;
if (type == 1) {
if (this.data.info.choudan * 100 < (price * 100)) {
wx.showToast({
title: '当前剩余积分不足,请重新挑选',
icon: 'none'
})
return
}
num++
} else {
num--
if (num < 0) {
num = 0;
return
}
})
}
}
that.setData({
coudan: coudan,
coudan_arr: coudan_arr,
[`info.coudanProduct[${index}].num`]: num
// [`info.coudanProduct[${index}].check`]: check
})
this.get_choudan()
},
// 计算凑单费用
get_choudan() {
let coudan_arr = this.data.coudan_arr
let choudan_money = 0;
let num = 0
for (let obj of coudan_arr) {
console.log(obj)
console.log(obj.price2)
if (obj.price2!= null) {
console.log(111)
choudan_money = (obj.price2 * 100 * obj.num) / 100 + choudan_money
} else {
console.log(222)
choudan_money = (obj.price * 100 * obj.num) / 100 + choudan_money
}
num = num+obj.num
}
if (num < 1) {
coudan.forEach((item, index) => {
if (item.id == id) {
coudan.splice(index, 1)
coudan_arr.splice(index, 1)
}
})
} else {
if (type == 1 && num == 1) {
//选中
coudan.push({
id: id,
num: num
})
coudan_arr.push({
id: id,
num: num,
price: Number(price),
price2: Number(price2)
})
} else {
coudan.forEach((item, index) => {
if (item.id == id) {
item.num = num
coudan_arr[index].num = num
}
})
}
this.setData({
choudan_money: choudan_money*100,
choudanNum:num,
'info.choudan': this.data.info.syjf - choudan_money
// choudan_money: Math.floor(choudan_money* 100) / 100
})
},
show_cover() {
let that = this
if (!that.data.cover_type) {
if (that.data.info.status == 0) {
}
that.setData({
fail: true
coudan: coudan,
coudan_arr: coudan_arr,
[`info.coudanProduct[${index}].num`]: num
// [`info.coudanProduct[${index}].check`]: check
})
return
}
if (!that.data.info.address) {
wx.showToast({
title: '请添加地址',
icon: 'none',
duration: 1000
this.get_choudan()
},
// 计算凑单费用
get_choudan() {
let coudan_arr = this.data.coudan_arr
let choudan_money = 0;
let num = 0
for (let obj of coudan_arr) {
console.log(obj)
console.log(obj.price2)
if (obj.price2 != null) {
console.log(111)
choudan_money = (obj.price2 * 100 * obj.num) / 100 + choudan_money
} else {
console.log(222)
choudan_money = (obj.price * 100 * obj.num) / 100 + choudan_money
}
num = num + obj.num
}
this.setData({
choudan_money: choudan_money * 100,
choudanNum: num,
'info.choudan': this.data.info.syjf - choudan_money
// choudan_money: Math.floor(choudan_money* 100) / 100
})
return
}
}
that.setData({
cover_type: !this.data.cover_type
})
},
// 去添加地址
add_address() {
wx.navigateTo({
url: '/pages/address/address',
})
},
//选择凑单商品
chooseGoods(e) {
// coudan 凑单商品组成的数组
// coudan_type 凑单的状态 可能废弃
let that = this
let coudan = this.data.coudan ? this.data.coudan : []
let coudan_arr = this.data.coudan_arr ? this.data.coudan_arr : []
let check = e.currentTarget.dataset.check
let num = e.currentTarget.dataset.num
let index = e.currentTarget.dataset.index
let id = e.currentTarget.dataset.id
let price = e.currentTarget.dataset.price;
let price2 = e.currentTarget.dataset.price2;
if (check) {
check = 0
coudan.forEach((item, index) => {
if (item.id == id) {
coudan.splice(index, 1)
coudan_arr.splice(index, 1)
},
show_cover() {
let that = this
if (!that.data.cover_type) {
if (that.data.info.status == 0) {
that.setData({
fail: true
})
return
}
if (!that.data.info.address) {
wx.showToast({
title: '请添加地址',
icon: 'none',
duration: 1000
})
return
}
}
})
} else {
check = 1
//选中
coudan.push({
id: id,
num: num
})
coudan_arr.push({
id: id,
num: num,
price: Number(price),
price2:Number(price2)
})
}
that.setData({
coudan: coudan,
coudan_arr: coudan_arr,
[`info.coudanProduct[${index}].check`]: check
})
that.get_choudan()
},
//获取页面信息
get_info(type, info, id) {
let that = this
let url = type == 4 ? app.interface.prev_pay : app.interface.now_prev_pay
let params = {
info: info
}
app.post(url, params).then((res) => {
console.log('99999', res, Number(res.msg.total))
res.msg.syjf = res.msg.choudan - res.msg.yunfei
res.msg.choudan = res.msg.choudan - res.msg.yunfei
res.msg.total = Number(res.msg.total * 100)
res.msg.yunfei = Number(res.msg.yunfei * 100)
let total = (res.msg.total + res.msg.yunfei).toFixed("1");
console.log(total)
that.setData({
info: res.msg,
total:total
})
console.log('9988756', that.data.info)
})
},
//获取页面信息
get_youfei(id) {
let that = this
let url = that.data.type == 4 ? app.interface.youfei1 : app.interface.youfei
let params = {
info: that.data.params,
address_id: id
}
app.post(url, params).then((res) => {
that.setData({
"info.yunfei": Number(res.msg.yunfei)*100
})
})
},
//点击支付
submit() {
let that = this
let list = that.data.info.products
let coudan = that.data.coudan
let info = []
if (that.data.type == 4) {
for (let obj of list) {
info.push({
id: obj.product.id,
num: obj.product.num
that.setData({
cover_type: !this.data.cover_type
})
}
} else {
for (let obj of list) {
info.push({
id: obj.id,
num: obj.num
},
// 去添加地址
add_address() {
wx.navigateTo({
url: '/pages/address/address',
})
}
}
if (coudan && coudan.length > 0) {
info = info.concat(coudan)
}
let url = app.interface.now_add
let params = {
address: that.data.info.address.id,
info: JSON.stringify(info)
}
app.post(url, params).then((res) => {
that.setData({
cover_type: false
})
that.order_pay(res.msg)
})
},
//订单支付
order_pay(order_odd) {
let url = app.interface.order_pay
let params = {
order_odd: order_odd
}
app.post(url, params).then((res) => {
this.setData({
order: res.msg
})
if (res.msg.message == "支付成功") {
// wx.showToast({
// title: '购买成功',
// icon:'none'
// })
},
//选择凑单商品
chooseGoods(e) {
// coudan 凑单商品组成的数组
// coudan_type 凑单的状态 可能废弃
let that = this
let coudan = this.data.coudan ? this.data.coudan : []
let coudan_arr = this.data.coudan_arr ? this.data.coudan_arr : []
let check = e.currentTarget.dataset.check
let num = e.currentTarget.dataset.num
let index = e.currentTarget.dataset.index
let id = e.currentTarget.dataset.id
let price = e.currentTarget.dataset.price;
let price2 = e.currentTarget.dataset.price2;
if (check) {
check = 0
coudan.forEach((item, index) => {
if (item.id == id) {
coudan.splice(index, 1)
coudan_arr.splice(index, 1)
}
})
} else {
check = 1
//选中
coudan.push({
id: id,
num: num
})
coudan_arr.push({
id: id,
num: num,
price: Number(price),
price2: Number(price2)
})
}
that.setData({
coudan: coudan,
coudan_arr: coudan_arr,
[`info.coudanProduct[${index}].check`]: check
})
that.get_choudan()
},
//获取页面信息
get_info(type, info, id) {
let that = this
let url = type == 4 ? app.interface.prev_pay : app.interface.now_prev_pay
let params = {
info: info
}
app.post(url, params).then((res) => {
console.log('99999', res, Number(res.msg.total))
res.msg.syjf = res.msg.choudan - res.msg.yunfei
let a = (res.msg.choudan - res.msg.yunfei).toFixed(2)
if (a < 0) {
a = 0
}
res.msg.choudan = a
res.msg.total = Number(res.msg.total * 100)
res.msg.yunfei = Number(res.msg.yunfei * 100)
let total = (res.msg.total + res.msg.yunfei).toFixed("1");
console.log(total)
that.setData({
info: res.msg,
total: total
})
console.log('9988756', that.data.info)
})
},
//获取页面信息
get_youfei(id) {
let that = this
let url = that.data.type == 4 ? app.interface.youfei1 : app.interface.youfei
let params = {
info: that.data.params,
address_id: id
}
app.post(url, params).then((res) => {
that.setData({
"info.yunfei": Number(res.msg.yunfei) * 100
})
})
},
// 支付失败弹窗关闭
payFail() {
this.setData({
success: true
fail: false
})
},
// 混合支付
mixedPay() {
let that = this
let url = app.interface.orderMixed
let params = {
order_odd: that.data.orderPayMent,
money: that.data.payMent
}
app.post(url, params).then((res) => {
wx.requestPayment({
timeStamp: res.data.timestamp,
nonceStr: res.data.nonceStr,
package: res.data.package,
signType: 'MD5',
paySign: res.data.paySign,
success(res) {
console.log(res,'支付成功')
that.setData({
fail: false
})
wx.showToast({
title: '支付成功',
})
},
fail(res) {
console.log(res,'支付失败')
}
})
})
} else if (res.msg.message == "余额不足") {
},
//点击支付
submit() {
let that = this
let list = that.data.info.products
let coudan = that.data.coudan
let info = []
if (that.data.type == 4) {
for (let obj of list) {
info.push({
id: obj.product.id,
num: obj.product.num
})
}
} else {
for (let obj of list) {
info.push({
id: obj.id,
num: obj.num
})
}
}
if (coudan && coudan.length > 0) {
info = info.concat(coudan)
}
let url = app.interface.now_add
let params = {
address: that.data.info.address.id,
info: JSON.stringify(info)
}
app.post(url, params).then((res) => {
that.setData({
cover_type: false
})
that.setData({
orderPayMent: res.msg
})
that.order_pay(res.msg)
})
},
//订单支付
order_pay(order_odd) {
let that = this
let url = app.interface.order_pay
let params = {
order_odd: order_odd
}
app.post(url, params).then((res) => {
this.setData({
order: res.msg
})
if (res.msg.message == "支付成功") {
// wx.showToast({
// title: '购买成功',
// icon:'none'
// })
this.setData({
success: true
})
} else if (res.msg.message == "余额不足") {
this.setData({
fail: true
})
let payMents = (that.data.info.total + that.data.info.yunfei) / 100 - that.data.order.syjf
that.setData({
payMent: payMents.toFixed(2)
})
console.log(payMents, 'payMent')
}
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
console.log(options)
this.setData({
fail: true
type: options.type,
params: options.info
})
}
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function(options) {
console.log(options)
this.setData({
type: options.type,
params: options.info
})
this.get_info(options.type, options.info, options.id)
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function() {
let pages = getCurrentPages();
let currPage = pages[pages.length - 1]
console.log('887766554',currPage.data.id)
if (currPage.data.id) {
console.log('4778785',this.data.info)
this.setData({
"info.address.address": currPage.data.address,
"info.address.area": currPage.data.area,
"info.address.id": currPage.data.id,
"info.address.tel": currPage.data.tel,
"info.address.name": currPage.data.name
})
console.log(this.data.info)
console.log(currPage.data.address)
this.get_youfei(currPage.data.id)
}
// if (wx.getStorageSync('no_address')) {
// wx.setStorageSync('no_address', false)
// this.setData({
// "info.address": null
// })
// }
this.get_info(options.type, options.info, options.id)
},
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function() {
},
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function() {
let pages = getCurrentPages();
},
let currPage = pages[pages.length - 1]
console.log('887766554', currPage.data.id)
if (currPage.data.id) {
console.log('4778785', this.data.info)
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function() {
this.setData({
"info.address.address": currPage.data.address,
"info.address.area": currPage.data.area,
"info.address.id": currPage.data.id,
"info.address.tel": currPage.data.tel,
"info.address.name": currPage.data.name
})
console.log(this.data.info)
console.log(currPage.data.address)
this.get_youfei(currPage.data.id)
}
// if (wx.getStorageSync('no_address')) {
// wx.setStorageSync('no_address', false)
// this.setData({
// "info.address": null
// })
// }
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function() {
},
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
/**
* 用户点击右上角分享
*/
onShareAppMessage: function() {
},
}
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
<view class="content">
<!-- 地址信息 -->
<view class="address_box" wx:if="{{info.address}}" bindtap="add_address">
<view class="name">{{info.address.name}}
<text>{{info.address.tel}}</text>
<text>{{info.address.b_tel||""}}</text>
</view>
<view class="address">
<image class="tips_img" src="/images/icon_54.png" />
<view>{{info.address.area}}{{info.address.address}}</view>
<!-- 地址信息 -->
<view class="address_box" wx:if="{{info.address}}" bindtap="add_address">
<view class="name">{{info.address.name}}
<text>{{info.address.tel}}</text>
<text>{{info.address.b_tel||""}}</text>
</view>
<view class="address">
<image class="tips_img" src="/images/icon_54.png" />
<view>{{info.address.area}}{{info.address.address}}</view>
</view>
<image src="/images/icon_41.png" class="youjiantou" />
</view>
<image src="/images/icon_41.png" class="youjiantou" />
</view>
<view class="on_address" wx:else bindtap="add_address">
<image src="/images/icon_46.png" />
<view>暂无收货地址,
<text>去添加</text>
<view class="on_address" wx:else bindtap="add_address">
<image src="/images/icon_46.png" />
<view>暂无收货地址,
<text>去添加</text>
</view>
</view>
<view class="line">
<image src="/images/line.png" />
</view>
</view>
<view class="line">
<image src="/images/line.png" />
</view>
<view class="content">
<shop_item list="{{info.products}}" type="{{type}}" />
<view class='recommend' wx:if="{{info.coudanProduct.length>0}}">
<view class='re_one'>*您支付后还剩{{info.choudan}}积分为您推荐了以下凑单产品!</view>
<scroll-view class='re_goods' scroll-x scroll-left="0">
<view class='re_item' wx:for='{{info.coudanProduct}}' wx:key='index' data-index="{{index}}" data-id="{{item.id}}" data-num="{{item.num?item.num:1}}" data-check='{{item.check}}' data-price='{{item.price}}' data-price2="{{item.price2}}">
<view class='re_re_item {{item.check?"active":""}}'>
<view class='triangle' wx:if='{{item.check}}'>
<image src='/images/bingo.png' class='bingo'></image>
</view>
<view class='re_re_img'>
<image src='{{item.images[0]}}' mode='aspectFill'></image>
</view>
<view class='re_bottom'>
<view class='re_re_name'>{{item.name}}</view>
<view class='re_re_score'wx:if="{{item.price!=null}}">{{item.price2}}积分</view>
<view class='re_re_score' wx:else>{{item.price}}积分</view>
</view>
<view class="content">
<shop_item list="{{info.products}}" type="{{type}}" />
<view class='recommend' wx:if="{{info.coudanProduct.length>0}}">
<view class='re_one'>*您支付后还剩{{info.choudan}}积分为您推荐了以下凑单产品!</view>
<scroll-view class='re_goods' scroll-x scroll-left="0">
<view class='re_item' wx:for='{{info.coudanProduct}}' wx:key='index' data-index="{{index}}" data-id="{{item.id}}" data-num="{{item.num?item.num:1}}" data-check='{{item.check}}' data-price='{{item.price}}' data-price2="{{item.price2}}">
<view class='re_re_item {{item.check?"active":""}}'>
<view class='triangle' wx:if='{{item.check}}'>
<image src='/images/bingo.png' class='bingo'></image>
</view>
<view class='re_re_img'>
<image src='{{item.images[0]}}' mode='aspectFill'></image>
</view>
<view class='re_bottom'>
<view class='re_re_name'>{{item.name}}</view>
<view class='re_re_score' wx:if="{{item.price!=null}}">{{item.price2}}积分</view>
<view class='re_re_score' wx:else>{{item.price}}积分</view>
</view>
<!-- 数量操作 -->
<view class="num_box">
<image class="num_btn" src="/images/reduce.png" data-check='{{item.check}}' wx:if="{{item.num}}" data-index="{{index}}" data-id="{{item.id}}" data-type="0" data-num="{{item.num?item.num:0}}" catchtap="num_change" data-price='{{item.price}}' data-price2="{{item.price2}}" />
<text wx:if="{{item.num}}" >{{item.num?item.num:0}}</text>
<image class="num_btn" src="/images/add.png" data-check='{{item.check}}' data-index="{{index}}" data-id="{{item.id}}" data-type="1" data-num="{{item.num?item.num:0}}" catchtap="num_change" data-price='{{item.price}}' data-price2="{{item.price2}}" />
</view>
</view>
<!-- 数量操作 -->
<view class="num_box">
<image class="num_btn" src="/images/reduce.png" data-check='{{item.check}}' wx:if="{{item.num}}" data-index="{{index}}" data-id="{{item.id}}" data-type="0" data-num="{{item.num?item.num:0}}" catchtap="num_change" data-price='{{item.price}}' data-price2="{{item.price2}}" />
<text wx:if="{{item.num}}">{{item.num?item.num:0}}</text>
<image class="num_btn" src="/images/add.png" data-check='{{item.check}}' data-index="{{index}}" data-id="{{item.id}}" data-type="1" data-num="{{item.num?item.num:0}}" catchtap="num_change" data-price='{{item.price}}' data-price2="{{item.price2}}" />
</view>
</view>
</view>
</scroll-view>
</view>
</scroll-view>
</view>
<view class='three'>
<view class='mask_two'>
<view>订单编号</view>
<view class='score'>{{info.order_odd}}</view>
</view>
<view class='three'>
<view class='mask_two'>
<view>订单编号</view>
<view class='score'>{{info.order_odd}}</view>
</view>
<view class='mask_two'>
<view>创建时间</view>
<view class='score'>{{info.date}}</view>
</view>
<view class='mask_two'>
<view>创建时间</view>
<view class='score'>{{info.date}}</view>
</view>
<view class='mask_two'>
<view>邮费</view>
<view class='score' style="color:rgba(242, 0, 0, 1)">{{info.yunfei/100}}积分</view>
</view>
<view class='mask_two'>
<view>邮费</view>
<view class='score' style="color:rgba(242, 0, 0, 1)">{{info.yunfei/100}}积分</view>
</view>
</view>
</view>
</view>
</view>
<view class="footer">
<view class="submit" catchtap="show_cover">提交</view>
<view class="jifen"> 合计:
<!-- <text>{{choudan_money?choudan_money + info.total + info.yunfei*100/100: info.total + info.yunfei*100/100}}积分</text> -->
<text>{{choudan_money?(choudan_money + info.total + info.yunfei)/100: (info.total + info.yunfei)/100}}积分</text>
</view>
<view class="num">共{{info.totalnum + choudanNum}}件</view>
<view class="submit" catchtap="show_cover">提交</view>
<view class="jifen"> 合计:
<!-- <text>{{choudan_money?choudan_money + info.total + info.yunfei*100/100: info.total + info.yunfei*100/100}}积分</text> -->
<text>{{choudan_money?(choudan_money + info.total + info.yunfei)/100: (info.total + info.yunfei)/100}}积分</text>
</view>
<view class="num">共{{info.totalnum + choudanNum}}件</view>
</view>
<concat/>
<concat />
<!-- 支付成功弹框开始 -->
<view class='success_mask' wx:if='{{success}}'>
<view class='success_diceng'>
<view class='success_one'>
<image src='/images/success.png'></image>
<view class='success_diceng'>
<view class='success_one'>
<image src='/images/success.png'></image>
</view>
<view class='success_font'>支付成功</view>
<navigator class='success_confirm_btn' open-type="navigateBack">确定</navigator>
</view>
<view class='success_font'>支付成功</view>
<navigator class='success_confirm_btn' open-type="navigateBack">确定</navigator>
</view>
</view>
<!-- 支付成功弹框结束 -->
<!-- 支付失败弹框开始 -->
<view class='success_mask' wx:if='{{fail}}'>
<!-- <view class='success_mask' wx:if='{{fail}}'>
<view class='success_diceng'>
<view class='success_one'>
<image src='/images/icon_55.png'></image>
</view>
<view class='success_font'>支付失败</view>
<!-- status为1的时候才能支付 -->
status为1的时候才能支付
<view class='fail_font' wx:if="{{info.status == 0}}">不在活动时间,您不能支付</view>
<view class='fail_font' wx:else>所需积分{{order.xy}},积分余额{{order.syjf}}</view>
<navigator class='success_confirm_btn' open-type="navigateBack">取消支付</navigator>
</view>
</view> -->
<view class="peijianMask" wx-if="{{fail}}">
<view class="peijianPopup">
<view class="typePopop_quxiao" bindtap="payFail">
<image src="/images/quxiao11.png" mode="widthFix" style="width: 48rpx;"></image>
</view>
<view style="padding: 32rpx;margin-top: 80rpx;">
<view style="display: flex;flex-direction: column;align-items: center;">
<image src="/images/jinggao.png" mode="widthFix" style="width: 126rpx;"></image>
<text style="font-size: 32rpx; color: #000;margin: 16rpx 0;">支付失败</text>
<text style="font-size: 28rpx;">您的积分不足,可使用微信支付差价</text>
</view>
<view style="width: 100%;padding: 32rpx 0;display: flex;justify-content: space-between;border-bottom: 1rpx solid rgba(240,242,245,1);">
<view style="font-size: 28rpx;">
共需积分
</view>
<view style="font-size: 32rpx;color: #3D9BF5;">
{{order.xy}}
</view>
</view>
<view style="width: 100%;padding: 32rpx 0;display: flex;justify-content: space-between;border-bottom: 1rpx solid rgba(240,242,245,1);">
<view style="font-size: 28rpx;">
当前积分
</view>
<view style="font-size: 32rpx;color: #3D9BF5;">
{{order.syjf}}
</view>
</view>
<view style="width: 100%;padding: 32rpx 0;display: flex;justify-content: space-between;border-bottom: 1rpx solid rgba(240,242,245,1);">
<view style="font-size: 28rpx;">
差价支付
</view>
<view style="font-size: 32rpx;color: #ED261C;">
¥{{payMent}}
</view>
</view>
<view style="margin-top: 114rpx;display: flex;align-items: center;font-size: 28rpx;justify-content: space-between;">
<view>
<text style="color: rgba(0,0,0,0.26);">共{{info.totalnum + choudanNum}}件,</text>
<text style="color: rgba(0,0,0,0.6);">合计:</text>
<text style="color: #3D9BF5;">{{order.xy}}积分,</text>
<text style="color: rgba(0,0,0,0.6);">差价:</text>
<text style="color: #ED261C;">¥{{payMent}}</text>
</view>
<view style="width: 222rpx;height: 88rpx;background-color: #3D9BF5;border-radius: 96rpx;display: flex;align-items: center;justify-content: center;font-size: 32rpx;color: #FFFFFF;" bindtap="mixedPay">
提交
</view>
</view>
</view>
</view>
</view>
<!-- 支付失败弹框结束 -->
<view class="cover_box" wx:if="{{cover_type}}">
<view class="cover_order">
<view class="all_money">{{choudan_money?(choudan_money + info.total + info.yunfei)/100: (info.total + info.yunfei)/100}}积分</view>
<view class="money_item">
<text>商品积分</text>
<text>{{choudan_money?(choudan_money + info.total)/100:info.total/100}}积分</text>
</view>
<view class="money_item">
<text>邮费</text>
<text>{{info.yunfei/100}}积分</text>
<view class="cover_order">
<view class="all_money">{{choudan_money?(choudan_money + info.total + info.yunfei)/100: (info.total + info.yunfei)/100}}积分</view>
<view class="money_item">
<text>商品积分</text>
<text>{{choudan_money?(choudan_money + info.total)/100:info.total/100}}积分</text>
</view>
<view class="money_item">
<text>邮费</text>
<text>{{info.yunfei/100}}积分</text>
</view>
<view class="cover_submit" catchtap="submit">确认支付</view>
<image src="/images/close.png" class="cover_close" catchtap="show_cover" />
</view>
<view class="cover_submit" catchtap="submit">确认支付</view>
<image src="/images/close.png" class="cover_close" catchtap="show_cover" />
</view>
</view>
\ No newline at end of file
... ...
... ... @@ -478,4 +478,30 @@ page {
font-weight: 400;
color: rgba(19, 26, 46, 1);
margin: 0 24rpx;
}
\ No newline at end of file
}
.peijianMask {
width: 100%;
height: 100%;
position: fixed;
top: 0;
left: 0;
background-color: rgba(0, 0, 0, 0.4);
opacity: 1;
z-index: 999999;
}
.peijianPopup {
width: 100%;
border-radius: 32rpx 32rpx 0 0;
opacity: 1;
background-color: #FFFFFF;
position: absolute;
bottom: 0;
left: 0;
z-index: 999999;
}
.typePopop_quxiao {
position: absolute;
top: 32rpx;
right: 32rpx;
}
... ...
{
"description": "项目配置文件",
"packOptions": {
"ignore": []
},
"setting": {
"urlCheck": false,
"es6": true,
"enhance": false,
"postcss": true,
"preloadBackgroundData": false,
"minified": true,
"newFeature": false,
"coverView": true,
"nodeModules": false,
"autoAudits": false,
"showShadowRootInWxmlPanel": true,
"scopeDataCheck": false,
"uglifyFileName": false,
"checkInvalidKey": true,
"checkSiteMap": true,
"uploadWithSourceMap": true,
"compileHotReLoad": true,
"lazyloadPlaceholderEnable": false,
"useMultiFrameRuntime": true,
"useApiHook": true,
"useApiHostProcess": true,
"babelSetting": {
"ignore": [],
"disablePlugins": [],
"outputPath": ""
"description": "项目配置文件",
"packOptions": {
"ignore": [],
"include": []
},
"useIsolateContext": false,
"userConfirmedBundleSwitch": false,
"packNpmManually": false,
"packNpmRelationList": [],
"minifyWXSS": true,
"disableUseStrict": false,
"minifyWXML": true,
"showES6CompileOption": false,
"useCompilerPlugins": false,
"ignoreUploadUnusedFiles": true
},
"compileType": "miniprogram",
"libVersion": "2.22.0",
"appid": "wx73497072e7340d61",
"projectname": "binhaineigouopen",
"debugOptions": {
"hidedInDevtools": []
},
"isGameTourist": false,
"simulatorType": "wechat",
"simulatorPluginLibVersion": {},
"condition": {
"plugin": {
"list": []
"setting": {
"urlCheck": false,
"es6": true,
"enhance": false,
"postcss": true,
"preloadBackgroundData": false,
"minified": true,
"newFeature": false,
"coverView": true,
"nodeModules": false,
"autoAudits": false,
"showShadowRootInWxmlPanel": true,
"scopeDataCheck": false,
"uglifyFileName": false,
"checkInvalidKey": true,
"checkSiteMap": true,
"uploadWithSourceMap": true,
"compileHotReLoad": true,
"lazyloadPlaceholderEnable": false,
"useMultiFrameRuntime": true,
"useApiHook": true,
"useApiHostProcess": true,
"ignoreDevUnusedFiles": false,
"babelSetting": {
"ignore": [],
"disablePlugins": [],
"outputPath": ""
},
"useIsolateContext": false,
"userConfirmedBundleSwitch": false,
"packNpmManually": false,
"packNpmRelationList": [],
"minifyWXSS": true,
"disableUseStrict": false,
"minifyWXML": true,
"showES6CompileOption": false,
"useCompilerPlugins": false,
"ignoreUploadUnusedFiles": true
},
"game": {
"list": []
},
"gamePlugin": {
"list": []
},
"miniprogram": {
"list": [
{
"id": 0,
"name": "123",
"pathName": "pages/login/login",
"query": "",
"scene": null
},
{
"id": 1,
"name": "pages/shop_detail/shop_detail",
"pathName": "pages/order/order",
"query": "",
"scene": null
},
{
"id": 2,
"name": "公众号模拟",
"pathName": "pages/register/register",
"query": "",
"scene": 1058
},
{
"id": -1,
"name": "自定义菜单",
"pathName": "pages/register/register",
"query": "",
"scene": 1035,
"referrerInfo": {
"appId": "wx017596efd78a16f0"
}
},
{
"id": -1,
"name": "个人中心",
"pathName": "pages/my/my",
"query": "",
"scene": null
},
{
"id": -1,
"name": "商品列表",
"pathName": "pages/classify/classify",
"query": "",
"scene": null
},
{
"id": -1,
"name": "活动套餐",
"pathName": "pages/search/search_result/search_result",
"query": "",
"scene": null
},
{
"id": -1,
"name": "足迹",
"pathName": "pages/zuji/zuji",
"query": "",
"scene": null
},
{
"id": -1,
"name": "首页",
"pathName": "pages/index/index",
"query": "",
"scene": null
},
{
"id": -1,
"name": "注册",
"pathName": "pages/register/register",
"query": "",
"scene": null
},
{
"id": -1,
"name": "pages/shop_detail/shop_detail",
"pathName": "pages/shop_detail/shop_detail",
"query": "id=774",
"scene": null
},
{
"id": -1,
"name": "pages/classify/classify",
"pathName": "pages/classify/classify",
"query": "",
"scene": null
},
{
"id": -1,
"name": "pages/classify/classify",
"pathName": "pages/classify/classify",
"query": "",
"scene": null
},
{
"name": "确定顶",
"pathName": "pages/order/order",
"query": "type=3&info={\"shop_id\":12,\"num\":1}&id=12",
"scene": null
},
{
"name": "pages/shop_cart/shop_cart",
"pathName": "pages/shop_cart/shop_cart",
"query": "",
"scene": null
},
{
"name": "packageA/pages/index/index",
"pathName": "packageA/pages/index/index",
"query": "",
"scene": null
},
{
"name": "确认订单",
"pathName": "packageA/pages/order/order",
"query": "type=3&info={\"shop_id\":3232,\"num\":1}&id=3232",
"scene": null
},
{
"name": "packageA/pages/logistics/logistics",
"pathName": "packageA/pages/logistics/logistics",
"query": "order=K7J527500103601",
"scene": null
"compileType": "miniprogram",
"libVersion": "2.22.0",
"appid": "wx73497072e7340d61",
"projectname": "binhaineigouopen",
"simulatorType": "wechat",
"simulatorPluginLibVersion": {},
"condition": {
"miniprogram": {
"list": [
{
"name": "123",
"pathName": "pages/login/login",
"query": "",
"scene": null
},
{
"name": "pages/shop_detail/shop_detail",
"pathName": "pages/order/order",
"query": "",
"scene": null
},
{
"name": "公众号模拟",
"pathName": "pages/register/register",
"query": "",
"scene": 1058
},
{
"name": "自定义菜单",
"pathName": "pages/register/register",
"query": "",
"scene": 1035,
"referrerInfo": {
"appId": "wx017596efd78a16f0"
}
},
{
"name": "个人中心",
"pathName": "pages/my/my",
"query": "",
"scene": null
},
{
"name": "商品列表",
"pathName": "pages/classify/classify",
"query": "",
"scene": null
},
{
"name": "活动套餐",
"pathName": "pages/search/search_result/search_result",
"query": "",
"scene": null
},
{
"name": "足迹",
"pathName": "pages/zuji/zuji",
"query": "",
"scene": null
},
{
"name": "首页",
"pathName": "pages/index/index",
"query": "",
"scene": null
},
{
"name": "注册",
"pathName": "pages/register/register",
"query": "",
"scene": null
},
{
"name": "pages/shop_detail/shop_detail",
"pathName": "pages/shop_detail/shop_detail",
"query": "id=774",
"scene": null
},
{
"name": "pages/classify/classify",
"pathName": "pages/classify/classify",
"query": "",
"scene": null
},
{
"name": "pages/classify/classify",
"pathName": "pages/classify/classify",
"query": "",
"scene": null
},
{
"name": "确定顶",
"pathName": "pages/order/order",
"query": "type=3&info={\"shop_id\":12,\"num\":1}&id=12",
"scene": null
},
{
"name": "pages/shop_cart/shop_cart",
"pathName": "pages/shop_cart/shop_cart",
"query": "",
"scene": null
},
{
"name": "packageA/pages/index/index",
"pathName": "packageA/pages/index/index",
"query": "",
"scene": null
},
{
"name": "确认订单",
"pathName": "packageA/pages/order/order",
"query": "type=3&info={\"shop_id\":3232,\"num\":1}&id=3232",
"scene": null
},
{
"name": "packageA/pages/logistics/logistics",
"pathName": "packageA/pages/logistics/logistics",
"query": "order=K7J527500103601",
"scene": null
}
]
}
]
},
"editorSetting": {
"tabIndent": "insertSpaces",
"tabSize": 4
}
}
}
\ No newline at end of file
... ...
{
"description": "项目私有配置文件。此文件中的内容将覆盖 project.config.json 中的相同字段。项目的改动优先同步到此文件中。详见文档:https://developers.weixin.qq.com/miniprogram/dev/devtools/projectconfig.html",
"libVersion": "2.25.0",
"condition": {
"miniprogram": {
"list": [
{
"name": "123",
"pathName": "pages/login/login",
"query": "",
"scene": null
},
{
"name": "pages/shop_detail/shop_detail",
"pathName": "pages/order/order",
"query": "",
"scene": null
},
{
"name": "公众号模拟",
"pathName": "pages/register/register",
"query": "",
"scene": 1058
},
{
"name": "自定义菜单",
"pathName": "pages/register/register",
"query": "",
"scene": 1035,
"referrerInfo": {
"appId": "wx017596efd78a16f0"
}
},
{
"name": "个人中心",
"pathName": "pages/my/my",
"query": "",
"scene": null
},
{
"name": "商品列表",
"pathName": "pages/classify/classify",
"query": "",
"scene": null
},
{
"name": "活动套餐",
"pathName": "pages/search/search_result/search_result",
"query": "",
"scene": null
},
{
"name": "足迹",
"pathName": "pages/zuji/zuji",
"query": "",
"scene": null
},
{
"name": "首页",
"pathName": "pages/index/index",
"query": "",
"scene": null
},
{
"name": "注册",
"pathName": "pages/register/register",
"query": "",
"scene": null
},
{
"name": "pages/shop_detail/shop_detail",
"pathName": "pages/shop_detail/shop_detail",
"query": "id=774",
"scene": null
},
{
"name": "pages/classify/classify",
"pathName": "pages/classify/classify",
"query": "",
"scene": null
},
{
"name": "pages/classify/classify",
"pathName": "pages/classify/classify",
"query": "",
"scene": null
},
{
"name": "确定顶",
"pathName": "pages/order/order",
"query": "type=3&info={\"shop_id\":12,\"num\":1}&id=12",
"scene": null
},
{
"name": "pages/shop_cart/shop_cart",
"pathName": "pages/shop_cart/shop_cart",
"query": "",
"scene": null
},
{
"name": "packageA/pages/index/index",
"pathName": "packageA/pages/index/index",
"query": "",
"scene": null
},
{
"name": "确认订单",
"pathName": "packageA/pages/order/order",
"query": "type=3&info={\"shop_id\":3232,\"num\":1}&id=3232",
"scene": null
},
{
"name": "packageA/pages/logistics/logistics",
"pathName": "packageA/pages/logistics/logistics",
"query": "order=K7J527500103601",
"scene": null
},
{
"name": "快递详情",
"pathName": "packageA/pages/logistics/logistics",
"query": "order=LBLAY890707802979",
"launchMode": "default",
"scene": null
}
]
}
}
}
\ No newline at end of file
... ...