1111
This commit is contained in:
81
App.vue
81
App.vue
@@ -41,46 +41,47 @@
|
|||||||
|
|
||||||
|
|
||||||
this.globalData.navInfo = navParams()
|
this.globalData.navInfo = navParams()
|
||||||
let _this = this;
|
|
||||||
wx.login({
|
// let _this = this;
|
||||||
success: function(res) {
|
// wx.login({
|
||||||
uni.request({
|
// success: function(res) {
|
||||||
// 组装请求地址
|
// uni.request({
|
||||||
url:_this.globalData.wxSilentLoginURL + "?wxCode=" + res.code,
|
// // 组装请求地址
|
||||||
method: "GET",
|
// url:_this.globalData.wxSilentLoginURL + "?wxCode=" + res.code,
|
||||||
header: {
|
// method: "GET",
|
||||||
'content-type': "application/x-www-form-urlencoded"
|
// header: {
|
||||||
},
|
// 'content-type': "application/x-www-form-urlencoded"
|
||||||
data: {
|
// },
|
||||||
"wxCode": res.code
|
// data: {
|
||||||
},
|
// "wxCode": res.code
|
||||||
success: res => {
|
// },
|
||||||
if (res.statusCode == 200) {
|
// success: res => {
|
||||||
if (!res.data.success) {
|
// if (res.statusCode == 200) {
|
||||||
if (res.data.code == "110") {
|
// if (!res.data.success) {
|
||||||
// 需要绑定手机号
|
// if (res.data.code == "110") {
|
||||||
uni.reLaunch({
|
// // 需要绑定手机号
|
||||||
url: '/pages/index/BindPhone?openid=' +
|
// uni.reLaunch({
|
||||||
res.data.data.wxMpOpenid
|
// url: '/pages/index/BindPhone?openid=' +
|
||||||
})
|
// res.data.data.wxMpOpenid
|
||||||
} else {
|
// })
|
||||||
// _this.status = 'more'
|
// } else {
|
||||||
}
|
// // _this.status = 'more'
|
||||||
} else {
|
// }
|
||||||
// 成功后跳转主页
|
// } else {
|
||||||
_this.globalData.sid = res.data.data.sid
|
// // 成功后跳转主页
|
||||||
console.log("用户sid",_this.globalData.sid)
|
// _this.globalData.sid = res.data.data.sid
|
||||||
}
|
// console.log("用户sid",_this.globalData.sid)
|
||||||
} else {
|
// }
|
||||||
}
|
// } else {
|
||||||
},
|
// }
|
||||||
fail: (err) => {
|
// },
|
||||||
}
|
// fail: (err) => {
|
||||||
});
|
// }
|
||||||
},
|
// });
|
||||||
fail: function(res) {
|
// },
|
||||||
}
|
// fail: function(res) {
|
||||||
});
|
// }
|
||||||
|
// });
|
||||||
},
|
},
|
||||||
onShow: function() {
|
onShow: function() {
|
||||||
console.log('App Show')
|
console.log('App Show')
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
|
|
||||||
<view style="display: flex;flex-direction: column; height: 100vh;box-sizing: border-box; background-color: #fff;" id="page">
|
<view style="display: flex;flex-direction: column; height: 100vh;box-sizing: border-box; background-color: #fff;"
|
||||||
|
id="page">
|
||||||
|
|
||||||
<view class="top">
|
<view class="top">
|
||||||
<NavBar ref="nav" navTitle="详情" :showIcon="true" :start-change-height="page.startHeight"
|
<NavBar ref="nav" navTitle="详情" :showIcon="true" :start-change-height="page.startHeight"
|
||||||
@@ -59,7 +60,8 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
|
||||||
<text style="color: #AEAEAE;font-size: 14px;margin-top: 5px;line-height: 20px;">{{item.remark}}</text>
|
<text
|
||||||
|
style="color: #AEAEAE;font-size: 14px;margin-top: 5px;line-height: 20px;">{{item.remark}}</text>
|
||||||
|
|
||||||
<view
|
<view
|
||||||
style="display: flex;flex-direction: row;justify-content:space-between;margin-top: 5px;">
|
style="display: flex;flex-direction: row;justify-content:space-between;margin-top: 5px;">
|
||||||
@@ -221,6 +223,8 @@
|
|||||||
|
|
||||||
item.price = Number(item.goodsNumber * item.jprice * item.weight).toFixed(2)
|
item.price = Number(item.goodsNumber * item.jprice * item.weight).toFixed(2)
|
||||||
|
|
||||||
|
else
|
||||||
|
item.price = "0"
|
||||||
},
|
},
|
||||||
getweight() {
|
getweight() {
|
||||||
|
|
||||||
|
|||||||
@@ -191,6 +191,7 @@
|
|||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/cloud/optionalCard'
|
url: '/pages/cloud/optionalCard'
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
|
|
||||||
<!-- <view
|
<!-- <view
|
||||||
style="display: flex;flex-direction: column;background: #f0f; height: auto; border-top-left-radius: 25px;border-top-right-radius: 25px;margin-top: -9.1vw;"> -->
|
style="display: flex;flex-direction: column;background: #f0f; height: auto; border-top-left-radius: 25px;border-top-right-radius: 25px;margin-top: -9.1vw;"> -->
|
||||||
<z-paging ref="paging" v-model="data" :pagingStyle='styleObject' @query="queryList" :refresher-enabled="true">
|
<z-paging ref="paging" v-model="data" :pagingStyle='styleObject' @query="queryList" :refresher-enabled="true" :auto="false">
|
||||||
|
|
||||||
<view v-for="(item,index) in data" :key="index"
|
<view v-for="(item,index) in data" :key="index"
|
||||||
style="display: flex;flex-direction: column;align-items: center;margin-top: 14px; "
|
style="display: flex;flex-direction: column;align-items: center;margin-top: 14px; "
|
||||||
@@ -298,6 +298,9 @@
|
|||||||
this.page.startHeight = info.windowWidth * 0.6
|
this.page.startHeight = info.windowWidth * 0.6
|
||||||
this.page.endHeight = info.windowWidth * 0.8
|
this.page.endHeight = info.windowWidth * 0.8
|
||||||
},
|
},
|
||||||
|
onShow() {
|
||||||
|
this.$refs.paging.reload(true);
|
||||||
|
},
|
||||||
onUnload() {
|
onUnload() {
|
||||||
uni.$off('order');
|
uni.$off('order');
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -187,10 +187,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.$bus.$on('order', msg => {
|
// this.$bus.$on('order', msg => {
|
||||||
console.log("aaaaaaaaaaa4", msg)
|
// console.log("aaaaaaaaaaa4", msg)
|
||||||
this.$refs.paging.reload(true);
|
// this.$refs.paging.reload(true);
|
||||||
});
|
// });
|
||||||
this.$bus.$on('order2', msg => {
|
this.$bus.$on('order2', msg => {
|
||||||
console.log("aaaaaaaaaaa4", msg)
|
console.log("aaaaaaaaaaa4", msg)
|
||||||
this.$refs.paging.reload(true);
|
this.$refs.paging.reload(true);
|
||||||
|
|||||||
@@ -188,10 +188,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.$bus.$on('order', msg => {
|
// this.$bus.$on('order', msg => {
|
||||||
console.log("aaaaaaaaaaa4", msg)
|
// console.log("aaaaaaaaaaa4", msg)
|
||||||
this.$refs.paging.reload(true);
|
// this.$refs.paging.reload(true);
|
||||||
});
|
// });
|
||||||
this.$bus.$on('order2', msg => {
|
this.$bus.$on('order2', msg => {
|
||||||
console.log("aaaaaaaaaaa4", msg)
|
console.log("aaaaaaaaaaa4", msg)
|
||||||
this.$refs.paging.reload(true);
|
this.$refs.paging.reload(true);
|
||||||
|
|||||||
Reference in New Issue
Block a user