合并分支 'lhj' 到 'master'
Lhj 查看合并请求 !2
正在显示
7 个修改的文件
包含
36 行增加
和
10 行删除
@@ -55,11 +55,11 @@ App({ | @@ -55,11 +55,11 @@ App({ | ||
55 | 'token': token || '' | 55 | 'token': token || '' |
56 | }, | 56 | }, |
57 | postData; | 57 | postData; |
58 | - data.header ? (token ? (header['token'] = token, delete data.header) : setTimeout(() => { | 58 | + // data.header ? (token ? (header['token'] = token, delete data.header) : setTimeout(() => { |
59 | // wx.navigateTo({ | 59 | // wx.navigateTo({ |
60 | // url: '/pages/register/register', | 60 | // url: '/pages/register/register', |
61 | // }) | 61 | // }) |
62 | - }, 1000)) : "" | 62 | + // }, 1100)) : "" |
63 | //网络请求 | 63 | //网络请求 |
64 | wx.request({ | 64 | wx.request({ |
65 | url: this.globalData.baseUrl + url, | 65 | url: this.globalData.baseUrl + url, |
@@ -87,6 +87,16 @@ App({ | @@ -87,6 +87,16 @@ App({ | ||
87 | icon: 'none', | 87 | icon: 'none', |
88 | }) | 88 | }) |
89 | reject(res.data) | 89 | reject(res.data) |
90 | + if (res.data.code == '401') { | ||
91 | + if (!app.globalData.register){ | ||
92 | + // setTimeout(() => { | ||
93 | + wx.navigateTo({ | ||
94 | + url: '/pages/register/register', | ||
95 | + }) | ||
96 | + // }, 1200) | ||
97 | + } | ||
98 | + | ||
99 | + } | ||
90 | } | 100 | } |
91 | (showLoad || showLoad == undefined) ? wx.hideLoading(): ""; | 101 | (showLoad || showLoad == undefined) ? wx.hideLoading(): ""; |
92 | wx.hideNavigationBarLoading() | 102 | wx.hideNavigationBarLoading() |
@@ -99,7 +99,7 @@ page { | @@ -99,7 +99,7 @@ page { | ||
99 | .news_detail_item { | 99 | .news_detail_item { |
100 | border-bottom: 2rpx solid #f5f5f5; | 100 | border-bottom: 2rpx solid #f5f5f5; |
101 | display: flex; | 101 | display: flex; |
102 | - padding: 24rpx 0; | 102 | + padding: 15rpx 0; |
103 | } | 103 | } |
104 | 104 | ||
105 | .news_detail_item:last-child { | 105 | .news_detail_item:last-child { |
@@ -3,5 +3,5 @@ | @@ -3,5 +3,5 @@ | ||
3 | "navigationBarTitleText": "党建工作", | 3 | "navigationBarTitleText": "党建工作", |
4 | "navigationBarBackgroundColor": "#169BD5", | 4 | "navigationBarBackgroundColor": "#169BD5", |
5 | "navigationBarTextStyle": "white", | 5 | "navigationBarTextStyle": "white", |
6 | - "enablePullDownRefresh": true | 6 | + "enablePullDownRefresh": false |
7 | } | 7 | } |
@@ -85,7 +85,7 @@ page{ | @@ -85,7 +85,7 @@ page{ | ||
85 | .news_detail_item{ | 85 | .news_detail_item{ |
86 | border-bottom:2rpx solid #f5f5f5; | 86 | border-bottom:2rpx solid #f5f5f5; |
87 | display: flex; | 87 | display: flex; |
88 | - padding: 24rpx 0; | 88 | + padding: 15rpx 0; |
89 | } | 89 | } |
90 | .news_detail_item:last-child{ | 90 | .news_detail_item:last-child{ |
91 | border: none; | 91 | border: none; |
@@ -19,7 +19,8 @@ Page({ | @@ -19,7 +19,8 @@ Page({ | ||
19 | ifData:!1, | 19 | ifData:!1, |
20 | navScrollLeft:0, | 20 | navScrollLeft:0, |
21 | noMore:!0, | 21 | noMore:!0, |
22 | - beautiful_switch:0 | 22 | + beautiful_switch:0, |
23 | + selectindex:0 | ||
23 | }, | 24 | }, |
24 | changeShow(){ | 25 | changeShow(){ |
25 | this.setData({ | 26 | this.setData({ |
@@ -97,7 +98,18 @@ Page({ | @@ -97,7 +98,18 @@ Page({ | ||
97 | }) | 98 | }) |
98 | }, | 99 | }, |
99 | tabCharge(e) { | 100 | tabCharge(e) { |
101 | + | ||
100 | let s = this, singleWidth = s.data.windowWidth / 7, cur = e.currentTarget.dataset.index+1; | 102 | let s = this, singleWidth = s.data.windowWidth / 7, cur = e.currentTarget.dataset.index+1; |
103 | + | ||
104 | + if (e.currentTarget.dataset.idx == -1) { | ||
105 | + s.setData({ | ||
106 | + selectindex:0 | ||
107 | + }) | ||
108 | + } else{ | ||
109 | + s.setData({ | ||
110 | + selectindex: e.currentTarget.dataset.idx | ||
111 | + }) | ||
112 | + } | ||
101 | s.setData({ | 113 | s.setData({ |
102 | beautiful_switch: e.currentTarget.dataset.beau, | 114 | beautiful_switch: e.currentTarget.dataset.beau, |
103 | companyList:[], | 115 | companyList:[], |
@@ -8,15 +8,15 @@ | @@ -8,15 +8,15 @@ | ||
8 | 8 | ||
9 | </view> --> | 9 | </view> --> |
10 | <scroll-view class='tab_box' scroll-left="{{navScrollLeft}}" scroll-x='true' scroll-with-animation='true'> | 10 | <scroll-view class='tab_box' scroll-left="{{navScrollLeft}}" scroll-x='true' scroll-with-animation='true'> |
11 | - <view class="tab_item {{current==0?'active':''}}" data-current='0' bindtap='tabCharge' data-beau="0">全部</view> | 11 | + <view class="tab_item {{selectindex==0?'active':''}}" data-current='0' bindtap='tabCharge' data-idx='-1' data-beau="0">全部</view> |
12 | 12 | ||
13 | - <view class="tab_item zuiactive" data-current='0' bindtap='tabCharge' data-beau="1"> | 13 | + <view class="tab_item zuiactive" data-idx='-2' data-current='0' bindtap='tabCharge' data-beau="1"> |
14 | 最美企业 | 14 | 最美企业 |
15 | 15 | ||
16 | <view class="iconfont icon-huangguan"></view> | 16 | <view class="iconfont icon-huangguan"></view> |
17 | </view> | 17 | </view> |
18 | <block wx:for="{{typeList}}" wx:key=''> | 18 | <block wx:for="{{typeList}}" wx:key=''> |
19 | - <view class="tab_item {{current == item.id?'active':''}}" data-current='{{item.id}}' bindtap='tabCharge' data-index='{{index}}' data-beau="0">{{item.name}}</view> | 19 | + <view class="tab_item {{selectindex == item.id?'active':''}}" data-idx="{{item.id}}" data-current='{{item.id}}' bindtap='tabCharge' data-index='{{index}}' data-beau="0">{{item.name}}</view> |
20 | </block> | 20 | </block> |
21 | </scroll-view> | 21 | </scroll-view> |
22 | <view class='iconfont icon-gengduo1' bindtap='changeShow'></view> | 22 | <view class='iconfont icon-gengduo1' bindtap='changeShow'></view> |
@@ -12,6 +12,7 @@ page { | @@ -12,6 +12,7 @@ page { | ||
12 | left: 0; | 12 | left: 0; |
13 | display: flex; | 13 | display: flex; |
14 | z-index: 10; | 14 | z-index: 10; |
15 | + | ||
15 | } | 16 | } |
16 | 17 | ||
17 | .tab_box { | 18 | .tab_box { |
@@ -20,6 +21,9 @@ page { | @@ -20,6 +21,9 @@ page { | ||
20 | white-space: nowrap; | 21 | white-space: nowrap; |
21 | overflow: hidden; | 22 | overflow: hidden; |
22 | line-height: 80rpx; | 23 | line-height: 80rpx; |
24 | + display:flex; | ||
25 | + padding-left: 10rpx | ||
26 | + | ||
23 | } | 27 | } |
24 | 28 | ||
25 | .tab_item { | 29 | .tab_item { |
@@ -27,7 +31,7 @@ page { | @@ -27,7 +31,7 @@ page { | ||
27 | color: #999; | 31 | color: #999; |
28 | display: inline-block; | 32 | display: inline-block; |
29 | position: relative; | 33 | position: relative; |
30 | - padding: 0 30rpx; | 34 | + padding: 0 12rpx; |
31 | height: 100%; | 35 | height: 100%; |
32 | text-align: center; | 36 | text-align: center; |
33 | } | 37 | } |
-
请 注册 或 登录 后发表评论