Showing
3 changed files
with
16 additions
and
5 deletions
| @@ -86,11 +86,22 @@ Page({ | @@ -86,11 +86,22 @@ Page({ | ||
| 86 | * 生命周期函数--监听页面显示 | 86 | * 生命周期函数--监听页面显示 |
| 87 | */ | 87 | */ |
| 88 | onShow: function () { | 88 | onShow: function () { |
| 89 | + let systemInfo = wx.getSystemInfoSync(); | ||
| 90 | + let reg = /ios/i; | ||
| 91 | + let pt = 20;//导航状态栏上内边距 | ||
| 92 | + let h = 44;//导航状态栏高度 | ||
| 93 | + if(reg.test(systemInfo.system)){ | ||
| 94 | + pt = systemInfo.statusBarHeight; | ||
| 95 | + h = 44; | ||
| 96 | + }else{ | ||
| 97 | + pt = systemInfo.statusBarHeight; | ||
| 98 | + h = 48; | ||
| 99 | + } | ||
| 89 | this.setData({ | 100 | this.setData({ |
| 90 | totalWidth: getApp().system.windowWidth, | 101 | totalWidth: getApp().system.windowWidth, |
| 91 | singleWidth: parseInt((getApp().system.windowWidth * 0.92 - 16) / 2), | 102 | singleWidth: parseInt((getApp().system.windowWidth * 0.92 - 16) / 2), |
| 92 | totalHeight: getApp().system.windowHeight, | 103 | totalHeight: getApp().system.windowHeight, |
| 93 | - kindHeight: getApp().system.windowHeight - 68 | 104 | + kindHeight: getApp().system.windowHeight - pt-h |
| 94 | }) | 105 | }) |
| 95 | setTimeout(()=>{ | 106 | setTimeout(()=>{ |
| 96 | this.initScrollHeightList(); | 107 | this.initScrollHeightList(); |
| @@ -5,7 +5,7 @@ | @@ -5,7 +5,7 @@ | ||
| 5 | <!--第四部分 原始菜无图或有图展示--> | 5 | <!--第四部分 原始菜无图或有图展示--> |
| 6 | <scroll-view | 6 | <scroll-view |
| 7 | scroll-y class = "partfour list-model" | 7 | scroll-y class = "partfour list-model" |
| 8 | - style = "height:{{totalHeight}}px;width:100%;z-index:{{scrollZindex}}; position: fixed;" | 8 | + style = "height:{{kindHeight-55}}px;width:100%;z-index:{{scrollZindex}}; position: fixed;" |
| 9 | scroll-into-view = "{{toView}}" | 9 | scroll-into-view = "{{toView}}" |
| 10 | scroll-with-animation | 10 | scroll-with-animation |
| 11 | bindscroll="bindscroll" | 11 | bindscroll="bindscroll" |
| @@ -29,7 +29,7 @@ | @@ -29,7 +29,7 @@ | ||
| 29 | </view> | 29 | </view> |
| 30 | </view> | 30 | </view> |
| 31 | </view> | 31 | </view> |
| 32 | - <view style="height: 110px;width: 100%;"></view> | 32 | + <view style="height: 110rpx;width: 100%;"></view> |
| 33 | </view> | 33 | </view> |
| 34 | </scroll-view> | 34 | </scroll-view> |
| 35 | <view class="white flex-lr bottom-view"> | 35 | <view class="white flex-lr bottom-view"> |
| @@ -45,7 +45,7 @@ | @@ -45,7 +45,7 @@ | ||
| 45 | "list": [] | 45 | "list": [] |
| 46 | }, | 46 | }, |
| 47 | "miniprogram": { | 47 | "miniprogram": { |
| 48 | - "current": 53, | 48 | + "current": 25, |
| 49 | "list": [ | 49 | "list": [ |
| 50 | { | 50 | { |
| 51 | "id": 0, | 51 | "id": 0, |
| @@ -244,7 +244,7 @@ | @@ -244,7 +244,7 @@ | ||
| 244 | "id": 25, | 244 | "id": 25, |
| 245 | "name": "pack-cookbook/pages/index", | 245 | "name": "pack-cookbook/pages/index", |
| 246 | "pathName": "pack-cookbook/pages/index", | 246 | "pathName": "pack-cookbook/pages/index", |
| 247 | - "query": "rid=5328&oid=173&identity=1&sid=154", | 247 | + "query": "rid=18599&oid=273&identity=1&sid=154", |
| 248 | "scene": 1001 | 248 | "scene": 1001 |
| 249 | }, | 249 | }, |
| 250 | { | 250 | { |
-
Please register or login to post a comment