Commit 2e0a6172 authored by qipeng's avatar qipeng

使用onshow每次刷新加载

parent 7c645f8d
...@@ -636,18 +636,20 @@ export default { ...@@ -636,18 +636,20 @@ export default {
} }
}, },
onShow() { onShow() {
let _this=this let _this=this
uni.getScreenBrightness({ uni.getScreenBrightness({
success: function(res){ success: function(res){
// 这里是把获取到的手机屏幕亮度,存储到data里面,方便给到页面生命周期隐藏和卸载方法里面用 // 这里是把获取到的手机屏幕亮度,存储到data里面,方便给到页面生命周期隐藏和卸载方法里面用
_this.Brightness = res.value _this.Brightness = res.value
if(res.value != 1){ if(res.value != 1){
uni.setScreenBrightness({ uni.setScreenBrightness({
value: 1 value: 1
}) })
} }
} }
}) })
this.getDetail()
}, },
onHide: function () { onHide: function () {
if(this.timer1) { if(this.timer1) {
...@@ -680,7 +682,7 @@ export default { ...@@ -680,7 +682,7 @@ export default {
//this.id = "z00167956572219584dc15634b62cf75" //this.id = "z00167956572219584dc15634b62cf75"
this.openId = uni.getStorageSync('openid') //openid oroHZ5FaUQ_SOOC_uQQP92fJpBRE oh2UV1lyYABHMZ1rMlgjhVHyyYDQ this.openId = uni.getStorageSync('openid') //openid oroHZ5FaUQ_SOOC_uQQP92fJpBRE oh2UV1lyYABHMZ1rMlgjhVHyyYDQ
//this.openId = 'oroHZ5FaUQ_SOOC_uQQP92fJpBRE'//'oh2UV1lyYABHMZ1rMlgjhVHyyYDQ' oroHZ5FaUQ_SOOC_uQQP92fJpBRE //this.openId = 'oroHZ5FaUQ_SOOC_uQQP92fJpBRE'//'oh2UV1lyYABHMZ1rMlgjhVHyyYDQ' oroHZ5FaUQ_SOOC_uQQP92fJpBRE
this.getDetail() //this.getDetail()
}, },
onUnload() { onUnload() {
if(this.timer1) { if(this.timer1) {
......
...@@ -444,7 +444,7 @@ export default { ...@@ -444,7 +444,7 @@ export default {
}, },
onLoad(option) { onLoad(option) {
this.openId = uni.getStorageSync('openid') this.openId = uni.getStorageSync('openid')
// this.openId = 'oh2UV1lyYABHMZ1rMlgjhVHyyYDQ'//oh2UV1lyYABHMZ1rMlgjhVHyyYDQ oroHZ5FaUQ_SOOC_uQQP92fJpBRE //this.openId = 'oroHZ5FaUQ_SOOC_uQQP92fJpBRE'//oh2UV1lyYABHMZ1rMlgjhVHyyYDQ oroHZ5FaUQ_SOOC_uQQP92fJpBRE
this.orderStatus = option.orderStatus||'' this.orderStatus = option.orderStatus||''
this.ifyukuaiCode = option.ifyukuaiCode||'' this.ifyukuaiCode = option.ifyukuaiCode||''
this.getData(1) this.getData(1)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment