Commit e7845a93109e52ab9ce854bf442b976a8a4c7c91

Authored by vking
1 parent 6d68b990

search

@@ -79,5 +79,8 @@ Component({ @@ -79,5 +79,8 @@ Component({
79 }) 79 })
80 console.log('this.setData', this.data); 80 console.log('this.setData', this.data);
81 }, 81 },
  82 + getHeight(){
  83 + return this.data.statusBarHeightFull
  84 + },
82 } 85 }
83 }) 86 })
@@ -19,6 +19,7 @@ Page({ @@ -19,6 +19,7 @@ Page({
19 hasSellerMore:false, 19 hasSellerMore:false,
20 keyword:'', 20 keyword:'',
21 sellerSplit:-1, 21 sellerSplit:-1,
  22 + navHeight:100,
22 }, 23 },
23 24
24 /** 25 /**
@@ -40,6 +41,10 @@ Page({ @@ -40,6 +41,10 @@ Page({
40 */ 41 */
41 onShow: function () { 42 onShow: function () {
42 this.getHistory(); 43 this.getHistory();
  44 + this.setData({
  45 + navHeight:this.selectComponent('#nav').getHeight()
  46 + })
  47 +
43 }, 48 },
44 49
45 /** 50 /**
1 <!--pages/reserve/search.wxml--> 1 <!--pages/reserve/search.wxml-->
2 -<nav>搜索</nav>  
3 -<view class="searchAddrView">  
4 - <view class="searchAddr flex-ll"> 2 +<nav id="nav">搜索</nav>
  3 +<view class="searchAddrView" style="height: {{navHeight+40}}px;">
  4 + <view class="searchAddr flex-ll" style="margin-top: {{navHeight+5}}px;">
5 <image class="icon" src="http://qn.colorcun.com/custom/lite-online/image/search26.png"></image> 5 <image class="icon" src="http://qn.colorcun.com/custom/lite-online/image/search26.png"></image>
6 <input style="width: 100%;" placeholder="输入餐厅名或地名,快速订包间" 6 <input style="width: 100%;" placeholder="输入餐厅名或地名,快速订包间"
7 type="text" confirm-type="done" 7 type="text" confirm-type="done"
@@ -6,15 +6,13 @@ @@ -6,15 +6,13 @@
6 } 6 }
7 .searchAddrView{ 7 .searchAddrView{
8 position: fixed; 8 position: fixed;
9 - top:100rpx; 9 + top:0rpx;
10 width: 100%; 10 width: 100%;
11 - height: 120rpx;  
12 - background-color: #fefefe; 11 + height: 240rpx;
  12 + background-color: #ffffff;
13 z-index: 9; 13 z-index: 9;
14 } 14 }
15 .searchAddr { 15 .searchAddr {
16 - position: fixed;  
17 - top:140rpx;  
18 width: 90%; 16 width: 90%;
19 height: 60rpx; 17 height: 60rpx;
20 background-color: #F5F5F5; 18 background-color: #F5F5F5;
@@ -23,8 +21,7 @@ @@ -23,8 +21,7 @@
23 color:#999999; 21 color:#999999;
24 line-height: 60rpx; 22 line-height: 60rpx;
25 font-size: 28rpx; 23 font-size: 28rpx;
26 - z-index: 99;  
27 - left: 5%; 24 + margin:0 auto;
28 } 25 }
29 .searchAddr .icon{ 26 .searchAddr .icon{
30 min-width: 26rpx; 27 min-width: 26rpx;