chengjie hace 6 años
padre
commit
801cf69284

+ 1 - 1
app.js

@@ -14,7 +14,7 @@ App({
14 14
   },
15 15
   globalData: {
16 16
     Version: "1.0.0",
17
-    IsProduction: true,
17
+    IsProduction: false,
18 18
     ShareTitle: "可以用来记忆一切的工具",
19 19
     SharePath: "pages/index/index",
20 20
     ShareImage: '',

+ 36 - 9
pages/index/index.js

@@ -1,5 +1,5 @@
1 1
 import common from '../../utils/util';
2
-import server from '../../utils/main';
2
+import main from '../../utils/main';
3 3
 
4 4
 const app = getApp();
5 5
 
@@ -61,7 +61,6 @@ Page({
61 61
     this.updateProgram();
62 62
 
63 63
     this.getUserInfo();
64
-
65 64
   },
66 65
   //得到用户信息
67 66
   getUserInfo: function (cb) {
@@ -117,8 +116,8 @@ Page({
117 116
   login: function (param) {
118 117
     var that = this;
119 118
 
120
-    server.getLocalHost(function () {
121
-      server.postData('MiaoguoLogin', {
119
+    main.getLocalHost(function () {
120
+      main.postData('MiaoguoLogin', {
122 121
         Code: param.Code,
123 122
         NickName: param.nickName,
124 123
         Language: param.language,
@@ -180,10 +179,10 @@ Page({
180 179
           //   url: url,
181 180
           // });
182 181
 
183
-          var url = '../main/default';
182
+          var url = '../main/default?IsStart=1';
184 183
 
185 184
           if (that.data.MiaoguoCardID){
186
-            url += "?Share=1&MiaoguoCardID=" + that.data.MiaoguoCardID;
185
+            url += "&Share=1&MiaoguoCardID=" + that.data.MiaoguoCardID;
187 186
           }
188 187
 
189 188
           setTimeout(function () {
@@ -193,22 +192,50 @@ Page({
193 192
           }, 2000);
194 193
 
195 194
           that.getBaiduToken();
195
+          that.getTaskTodayList();
196 196
         }
197 197
       });
198 198
 
199 199
     });
200 200
   },
201 201
   getBaiduToken: function () {
202
-    server.getLocalHost(function () {
203
-      server.getData('GetBaiduToken', function (data) {
202
+      main.getData('GetBaiduToken', function (data) {
204 203
         if (data) {
205 204
           app.globalData.BaiduToken = data;
206 205
           //console.log(app.globalData.BaiduToken);
207 206
         }
208 207
       });
209
-    });
210 208
   },
209
+  //得到当天任务
210
+  getTaskTodayList: function () {
211
+    var that = this;
212
+    common.getStorageValue(that, "CardMaxNumberNew", 10, function () {
213
+      common.getStorageValue(that, "CardMaxNumberHistory", 30, function () {
214
+        common.getStorageValue(that, "SortTypeIndex", 0, function () {
215
+          var url = 'GetMiaoguoCardToday?UserID=' + app.globalData.userInfo.UserID;
216
+          url += "&New=" + that.data.CardMaxNumberNew;
217
+          url += "&History=" + that.data.CardMaxNumberHistory;
218
+          url += "&SortTypeIndex=" + that.data.SortTypeIndex;
219
+
220
+          main.getData(url, function (data) {
221
+            if (data) {
222
+              var TodayTaskNumber = data.ListNew.length + data.ListReview.length + data.ListHistory.length;
223
+              that.setData({
224
+                List: data,
225
+                DayNumber: data.DayNumber,
226
+                TodayTaskNumber: TodayTaskNumber,
227
+                IsStart: data.IsStart,
228
+              });
229
+
230
+              wx.setStorageSync("TaskToday", data);
211 231
 
232
+            }
233
+          });
234
+        });
235
+      });
236
+    });
237
+
238
+  },
212 239
   updateProgram: function () {
213 240
     const updateManager = wx.getUpdateManager();
214 241
 

+ 12 - 21
pages/main/add.js

@@ -7,8 +7,6 @@ var arrTag = [];
7 7
 
8 8
 Page({
9 9
   data: {
10
-    IsShowRemind: false,
11
-    IsShowRemind2: false,
12 10
   },
13 11
   onLoad: function (options) {
14 12
     wx.hideShareMenu();
@@ -49,9 +47,11 @@ Page({
49 47
         Tags: card.Tags,
50 48
       });
51 49
 
52
-      wx.setNavigationBarTitle({
53
-        title: '编辑题卡'
54
-      });
50
+      if (that.data.UpdateType != "add2") {
51
+        wx.setNavigationBarTitle({
52
+          title: '编辑题卡'
53
+        });
54
+      }
55 55
 
56 56
       if (that.data.UpdateType == "edit3") {
57 57
         that.setData({
@@ -60,10 +60,6 @@ Page({
60 60
         that.gotoAddItem({ currentTarget: { dataset: { fieldid: that.data.FieldID } } });
61 61
       }
62 62
     }
63
-
64
-    this.setData({
65
-      IsShowRemind: false,
66
-    });
67 63
   },
68 64
   onUnload: function () {
69 65
     field = [[], [], [], []];
@@ -97,10 +93,10 @@ Page({
97 93
     })
98 94
   },
99 95
   onPreview: function (e) {
100
-    var that=this;
96
+    var that = this;
101 97
     if (that.data.Field[1] == "") {
102
-      that.setData({
103
-        IsShowRemind: true,
98
+      wx.showToast({
99
+        title: '请在第一段输入内容',
104 100
       });
105 101
     }
106 102
     else {
@@ -118,8 +114,8 @@ Page({
118 114
     var that = this;
119 115
 
120 116
     if (that.data.Field[1] == "") {
121
-      that.setData({
122
-        IsShowRemind: true,
117
+      wx.showToast({
118
+        title: '请在第一段输入内容',
123 119
       });
124 120
     }
125 121
     else {
@@ -183,14 +179,9 @@ Page({
183 179
           that.onClose();
184 180
         }
185 181
         else {
186
-          that.setData({
187
-            IsShowRemind2: true,
182
+          wx.showToast({
183
+            title: '保存成功!',
188 184
           });
189
-          setTimeout(function () {
190
-            that.setData({
191
-              IsShowRemind2: false,
192
-            });
193
-          }, 2000);
194 185
 
195 186
           if (that.data.UpdateType == "add2") {
196 187
             that.initAddCard();

+ 2 - 1
pages/main/add.json

@@ -1,3 +1,4 @@
1 1
 {
2
-  "navigationBarTitleText": "添加题卡"
2
+  "navigationBarTitleText": "添加题卡",
3
+  "backgroundColor": "#F0F0F0"
3 4
 }

+ 2 - 4
pages/main/add.wxml

@@ -21,8 +21,8 @@
21 21
       </view>
22 22
       <view class="panelItem21 FlexRow">
23 23
         <text class="textNull" wx:if="{{!Field[itemParent] || Field[itemParent].length==0}}">
24
-          <block wx:if="{{itemParent==1}}">题目,必填</block>
25
-          <block wx:if="{{itemParent==2}}">答案</block>
24
+          <block wx:if="{{itemParent==1}}">题目</block>
25
+          <block wx:if="{{itemParent==2}}">答案</block>
26 26
           <block wx:if="{{itemParent==3}}">其它</block>
27 27
         </text>
28 28
         <block wx:for="{{Field[itemParent]}}" wx:key="index">
@@ -58,8 +58,6 @@
58 58
 
59 59
   <view style='height:300rpx;'></view>
60 60
 
61
-  <view wx:if="{{IsShowRemind}}" class="remind">请在第一段输入内容</view>
62
-  <view wx:if="{{IsShowRemind2}}" class="remind1 remind">保存成功</view>
63 61
   <view class='panelSave FlexRow'>
64 62
     <view class="panelSave1 FlexRow" bindtap="onSearch">
65 63
       <view class="add">+</view>  资料

+ 6 - 16
pages/main/add.wxss

@@ -143,21 +143,6 @@
143 143
   margin-right: 30rpx;
144 144
 }
145 145
 
146
-.remind{
147
-  width:100%;
148
-  line-height: 60rpx;
149
-  text-align: center;
150
-  color:#fff;
151
-  background-color: #B3443B;
152
-  font-size:24rpx;
153
-  position: fixed;
154
-  bottom: 120rpx;
155
-}
156
-
157
-.remind1{
158
-  background-color: #2e2e2e;
159
-}
160
-
161 146
 .panelSave {
162 147
   width: 100%;
163 148
   background-color: #fff;
@@ -168,6 +153,7 @@
168 153
   z-index: 10;
169 154
   color: #0071ef;
170 155
   justify-content: space-between;
156
+  border-top: 1rpx solid #d2d2d2;
171 157
 }
172 158
 
173 159
 .panelSave .panelSave1 {
@@ -180,7 +166,11 @@
180 166
   height:80rpx;
181 167
   border-radius: 10rpx;
182 168
   font-size:28rpx;
183
-  margin-left: 30rpx;
169
+  margin-left: 20rpx;
170
+}
171
+.panelSave .panelSave2 {
172
+  width: 168rpx;
173
+  justify-content: flex-end;
184 174
 }
185 175
 
186 176
 .add {

+ 2 - 1
pages/main/addItem.json

@@ -1,3 +1,4 @@
1 1
 {
2
-  "navigationBarTitleText": "编辑 段落1"
2
+  "navigationBarTitleText": "编辑 段落1",
3
+  "backgroundColor": "#F0F0F0"
3 4
 }

+ 1 - 1
pages/main/addItem.wxml

@@ -16,7 +16,7 @@
16 16
       <view class="panelSave3 panelSave1 FlexRow" bindtap="addSymbol" data-id="{{LineSign}}" wx:if="{{LineSign=='[/线]'}}">
17 17
         <image class="universalpic_underline_end_white_30x22" src='../images/universalpic_underline_end_white_30x22.png' />
18 18
       </view>
19
-      <image class="universalpic_help_gray_26x26" src='../images/universalpic_help_gray_26x26.png' />
19
+      <!-- <image class="universalpic_help_gray_26x26" src='../images/universalpic_help_gray_26x26.png' /> -->
20 20
 
21 21
     </view>
22 22
     <view class='right FlexRow'>

+ 3 - 3
pages/main/cardInfo.wxml

@@ -12,7 +12,7 @@
12 12
     <view class="lineWidth720"></view>
13 13
   </view>
14 14
   <view class="panelItem FlexRow">
15
-    <view class="panelItem1">首次练习</view>
15
+    <view class="panelItem1">首次练习</view>
16 16
     <view class="panelItem2 FlexRow">
17 17
       {{CardInfo.FirstTimeStr}}
18 18
     </view>
@@ -44,7 +44,7 @@
44 44
     <view class="panelTitle1">进展</view>
45 45
   </view>
46 46
   <view class="panelItem FlexRow">
47
-    <view class="panelItem1">练习数</view>
47
+    <view class="panelItem1">练习数</view>
48 48
     <view class="panelItem2 FlexRow">
49 49
       {{CardInfo.LearnNumber}}
50 50
     </view>
@@ -53,7 +53,7 @@
53 53
     <view class="lineWidth720"></view>
54 54
   </view>
55 55
   <view class="panelItem FlexRow">
56
-    <view class="panelItem1">总习用时</view>
56
+    <view class="panelItem1">总习用时</view>
57 57
     <view class="panelItem2 FlexRow">
58 58
       {{CardInfo.Duration}}
59 59
     </view>

+ 14 - 13
pages/main/colorplan.wxml

@@ -1,6 +1,6 @@
1 1
 <view class="container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
2 2
   <view class="panelTitle FlexRow">
3
-    <view class="panelTitle1">习中界面</view>
3
+    <view class="panelTitle1">习中界面</view>
4 4
   </view>
5 5
   <view class="panelItem FlexRow">
6 6
     <view class="panelItem1">每次更换颜色</view>
@@ -10,18 +10,19 @@
10 10
   </view>
11 11
   <view class='lineFooter'></view>
12 12
 
13
-  <view class="panelTitle FlexRow">
14
-    <view class="panelTitle1">配色</view>
15
-  </view>
16
-  <view class="panelItem FlexColumn">
17
-    <view style="height:30rpx;"></view>
18
-    <view class="{{item.SelectedCSS}} panelItem0 FlexRow"  wx:for="{{ColorList}}" wx:key="index" wx:if="{{index>0}}" bindtap="selectColor" data-index="{{index}}">
19
-      <view class='panelItem01' style='background-color:{{item.BackColor}};color:{{item.FrontColor}};'>{{item.Name}}</view>
20
-      <view class='panelItem02' style='background-color:{{item.BackColor1}};'></view>
21
-      <view class='panelItem03' style='background-color:{{item.BackColor2}};'></view>
13
+  <block wx:if="{{!IsChangeColor}}">
14
+    <view class="panelTitle FlexRow">
15
+      <view class="panelTitle1">配色</view>
22 16
     </view>
23
-  </view>
24
-  <view class='lineFooter'></view>
25
-
17
+    <view class="panelItem FlexColumn">
18
+      <view style="height:30rpx;"></view>
19
+      <view class="{{item.SelectedCSS}} panelItem0 FlexRow" wx:for="{{ColorList}}" wx:key="index" wx:if="{{index>0}}" bindtap="selectColor" data-index="{{index}}">
20
+        <view class='panelItem01' style='background-color:{{item.BackColor}};color:{{item.FrontColor}};'>{{item.Name}}</view>
21
+        <view class='panelItem02' style='background-color:{{item.BackColor1}};'></view>
22
+        <view class='panelItem03' style='background-color:{{item.BackColor2}};'></view>
23
+      </view>
24
+    </view>
25
+    <view class='lineFooter'></view>
26
+  </block>
26 27
   <view style='height:100rpx'></view>
27 28
 </view>

+ 40 - 38
pages/main/default.js

@@ -17,27 +17,25 @@ Page({
17 17
       var id = options.MiaoguoCardID;
18 18
       wx.navigateTo({
19 19
         url: './preview?type=share&id=' + id,
20
-      })
20
+      });
21 21
     }
22 22
   },
23 23
   onShow: function () {
24 24
     var that = this;
25
-
26
-    common.getStorageValue(that, "CardMaxNumberNew", 10, function () {
27
-      common.getStorageValue(that, "CardMaxNumberHistory", 30, function () {
28
-        common.getStorageValue(that, "SortTypeIndex", 0, function () {
29
-          that.getList();
30
-          wx.stopPullDownRefresh();
31
-        });
32
-      });
33
-    });
34
-
35 25
     wx.getSetting({
36 26
       success(res) {
37 27
         if (res.authSetting['scope.userInfo']) {
38 28
           that.setData({
39 29
             IsAccredit: true,
40 30
           });
31
+
32
+          common.getStorageValue(that, "UserName", "秒过", function () {
33
+            wx.setNavigationBarTitle({
34
+              title: that.data.UserName
35
+            });
36
+          });
37
+
38
+          that.getTaskTodayList();
41 39
         }
42 40
         else {
43 41
           wx.navigateTo({
@@ -46,16 +44,6 @@ Page({
46 44
         }
47 45
       }
48 46
     });
49
-
50
-    common.getStorageValue(this, "UserName", "秒过", function () {
51
-      wx.setNavigationBarTitle({
52
-        title: that.data.UserName
53
-      });
54
-    });
55
-    
56
-  },
57
-  onPullDownRefresh: function () {
58
-    this.onShow();
59 47
   },
60 48
   goto: function (e) {
61 49
     var url = e.currentTarget.dataset.url;
@@ -63,27 +51,41 @@ Page({
63 51
       url: './' + url,
64 52
     })
65 53
   },
66
-  getList: function () {
54
+  //得到当天任务
55
+  getTaskTodayList: function () {
56
+    wx.showLoading({
57
+      title: '请稍候',
58
+      mask:true,
59
+    })
67 60
     var that = this;
68
-    var url = 'GetMiaoguoCardToday?UserID=' + app.globalData.userInfo.UserID;
69
-    url += "&New=" + this.data.CardMaxNumberNew;
70
-    url += "&History=" + this.data.CardMaxNumberHistory;
71
-    url += "&SortTypeIndex=" + this.data.SortTypeIndex;
61
+    common.getStorageValue(that, "CardMaxNumberNew", 10, function () {
62
+      common.getStorageValue(that, "CardMaxNumberHistory", 30, function () {
63
+        common.getStorageValue(that, "SortTypeIndex", 0, function () {
64
+          var url = 'GetMiaoguoCardToday?UserID=' + app.globalData.userInfo.UserID;
65
+          url += "&New=" + that.data.CardMaxNumberNew;
66
+          url += "&History=" + that.data.CardMaxNumberHistory;
67
+          url += "&SortTypeIndex=" + that.data.SortTypeIndex;
72 68
 
73
-    main.getData(url, function (data) {
74
-      if (data) {
75
-        var TodayTaskNumber = data.ListNew.length + data.ListReview.length + data.ListHistory.length;
76
-        that.setData({
77
-          List: data,
78
-          DayNumber: data.DayNumber,
79
-          TodayTaskNumber: TodayTaskNumber,
80
-          IsStart:data.IsStart,
81
-        });
69
+          main.getData(url, function (data) {
70
+            wx.hideLoading();
82 71
 
83
-        wx.setStorageSync("TaskToday", data);
84
-        
85
-      }
72
+            if (data) {
73
+              var TodayTaskNumber = data.ListNew.length + data.ListReview.length + data.ListHistory.length;
74
+              that.setData({
75
+                List: data,
76
+                DayNumber: data.DayNumber,
77
+                TodayTaskNumber: TodayTaskNumber,
78
+                IsStart: data.IsStart,
79
+              });
80
+
81
+              wx.setStorageSync("TaskToday", data);
82
+
83
+            }
84
+          });
85
+        });
86
+      });
86 87
     });
88
+    
87 89
   },
88 90
   gotoCard: function () {
89 91
     wx.redirectTo({

+ 1 - 2
pages/main/default.json

@@ -2,6 +2,5 @@
2 2
   "navigationBarBackgroundColor": "#3157BA",
3 3
   "navigationBarTextStyle": "white",
4 4
   "navigationBarTitleText": "秒过",
5
-  "backgroundColor": "#3157BA",
6
-  "enablePullDownRefresh": true
5
+  "backgroundColor": "#3157BA"
7 6
 }

+ 1 - 1
pages/main/default.wxml

@@ -18,7 +18,7 @@
18 18
     <view class='panelBottom1 FlexRow'>
19 19
       <view class='panelBottom11 FlexColumn'>
20 20
         <image class="program_tabbar_task_default" src='../images/program_tabbar_task_normal.png' />
21
-        <view class='text5'>习</view>
21
+        <view class='text5'>习</view>
22 22
       </view>
23 23
       <view class='line1'></view>
24 24
       <view class='panelBottom11 FlexColumn' bindtap="goto" data-url="add?type=add&id=0">

+ 6 - 3
pages/main/default.wxss

@@ -6,7 +6,8 @@
6 6
 }
7 7
 
8 8
 .panel1 {
9
-  margin-top: 120rpx;
9
+  position: fixed;
10
+  top:120rpx;
10 11
   color: #fff;
11 12
 }
12 13
 
@@ -29,7 +30,8 @@
29 30
 .task_index_start {
30 31
   width: 377rpx;
31 32
   height: 240rpx;
32
-  margin-top: 156rpx;
33
+  position: fixed;
34
+  top:523rpx;
33 35
 }
34 36
 
35 37
 .panelBottom {
@@ -51,6 +53,7 @@
51 53
   font-size:20rpx;
52 54
   color:#787878;
53 55
   height:98rpx;
56
+  justify-content: flex-start;
54 57
 }
55 58
 .panelBottom1 .line1{
56 59
   height:98rpx;
@@ -64,5 +67,5 @@
64 67
 .program_tabbar_task_default {
65 68
   width: 54rpx;
66 69
   height: 54rpx;
67
-  margin-bottom: 4rpx;
70
+  margin: 10rpx 0 4rpx 0;
68 71
 }

+ 6 - 6
pages/main/detail.js

@@ -6,7 +6,6 @@ const app = getApp();
6 6
 const arrFontSize = [46, 68, 108];
7 7
 
8 8
 var innerAudioContext1;
9
-var innerAudioContext2;
10 9
 
11 10
 var listTaskFinished = []; //完成的任务
12 11
 var timeStart; //计算时长
@@ -45,8 +44,8 @@ Page({
45 44
     });
46 45
 
47 46
     innerAudioContext1 = wx.createInnerAudioContext();
48
-    innerAudioContext2 = wx.createInnerAudioContext();
49
-
47
+    this.audioCtx = wx.createAudioContext('myAudio');
48
+    
50 49
     this.getList();
51 50
 
52 51
     this.getColor();
@@ -369,6 +368,7 @@ Page({
369 368
 
370 369
     wx.showLoading({
371 370
       title: '请稍候',
371
+      mask: true,
372 372
     });
373 373
 
374 374
     var btnnumber = e.currentTarget.dataset.btnnumber;
@@ -577,9 +577,9 @@ Page({
577 577
       url = url.replace("[token]", app.globalData.BaiduToken);
578 578
       url = url.replace("[word]", str);
579 579
     }
580
-    innerAudioContext2.src = url;
581
-    innerAudioContext2.play();
582
-    console.log(url);
580
+    this.audioCtx.setSrc(url);
581
+    this.audioCtx.play();
582
+    //console.log(url);
583 583
 
584 584
     var fieldid = e.currentTarget.dataset.fieldid;
585 585
     var content = TaskList[0].ContentNew.Field[fieldid];

+ 1 - 1
pages/main/detail.json

@@ -1,3 +1,3 @@
1 1
 {
2
-  "navigationBarTitleText": "习中"
2
+  "navigationBarTitleText": "习中"
3 3
 }

+ 5 - 3
pages/main/detail.wxml

@@ -33,7 +33,7 @@
33 33
 
34 34
   </view>
35 35
 
36
-  <!-- 习页 -->
36
+  <!-- 习页 -->
37 37
   <block wx:if="{{(NumberNew+NumberReview+NumberHistory)>0}}">
38 38
 
39 39
     <view class="panelField10" style='background-color:{{Color.BackColor}};'></view>
@@ -70,7 +70,7 @@
70 70
     </view>
71 71
 
72 72
     <view class='right2 FlexRow' wx:if="{{IsShowAnswer[0]==0}}">
73
-      <image class="universalpic_hide_white_34x34" src='../images/universalpic_hide_white_20p_34x34.png' />
73
+      <image class="universalpic_hide_white_34x34" src='../images/universalpic_hide_{{Color.IconColor}}_20p_34x34.png' />
74 74
     </view>
75 75
     <view class='right2 FlexRow' catchtap='onShowAnswer' data-start="true" wx:if="{{IsShowAnswer[0]==1}}">
76 76
       <image class="universalpic_hide_white_34x34" src='../images/universalpic_hide_{{Color.IconColor}}_34x34.png' />
@@ -189,4 +189,6 @@
189 189
       <view>知道了</view>
190 190
     </view>
191 191
   </view>
192
-</view>
192
+</view>
193
+
194
+<audio hidden='true' id="myAudio"></audio>

+ 3 - 5
pages/main/preview.js

@@ -2,7 +2,6 @@ import common from '../../utils/util';
2 2
 import main from '../../utils/main';
3 3
 
4 4
 const app = getApp();
5
-var innerAudioContext1;
6 5
 
7 6
 Page({
8 7
   data: {
@@ -20,8 +19,7 @@ Page({
20 19
       MiaoguoCardID: id,
21 20
     });
22 21
 
23
-    innerAudioContext1 = wx.createInnerAudioContext();
24
-
22
+    this.audioCtx = wx.createAudioContext('myAudio');
25 23
   },
26 24
   onShow: function () {
27 25
     var that = this;
@@ -169,8 +167,8 @@ Page({
169 167
       url = url.replace("[word]", str);
170 168
     }
171 169
 
172
-    innerAudioContext1.src = url;
173
-    innerAudioContext1.play();
170
+    this.audioCtx.setSrc(url);
171
+    this.audioCtx.play();
174 172
   },
175 173
   onMore: function () {
176 174
     var that = this;

+ 2 - 2
pages/main/preview.wxml

@@ -90,7 +90,7 @@
90 90
       <image class="universalpic_prev_black_30x30" src='../images/universalpic_next_black_30x30.png' />
91 91
     </view>
92 92
     <view class='btn1' wx:if="{{NextID==0}}"></view>
93
-
94 93
   </view>
94
+</view>
95 95
 
96
-</view>
96
+<audio hidden='true' id="myAudio"></audio>

+ 3 - 1
pages/main/searchCard.json

@@ -1,3 +1,5 @@
1 1
 {
2
-  "navigationBarTitleText": "题卡"
2
+  "navigationBarTitleText": "题卡",
3
+  "backgroundColor": "#F0F0F0"
4
+  
3 5
 }

+ 1 - 1
pages/main/searchCard.wxml

@@ -21,7 +21,7 @@
21 21
     <view class='panelBottom1 FlexRow'>
22 22
       <view class='panelBottom11 FlexColumn' bindtap="gotoDefault">
23 23
         <image class="program_tabbar_task_default" src='../images/program_tabbar_task_default.png' />
24
-        <view>习</view>
24
+        <view>习</view>
25 25
       </view>
26 26
       <view class='line1'></view>
27 27
       <view class='panelBottom11 FlexColumn' bindtap="goto" data-url="add?type=add&id=0">

+ 2 - 2
pages/main/searchCard.wxss

@@ -67,7 +67,7 @@
67 67
   font-size:20rpx;
68 68
   color:#787878;
69 69
   height:98rpx;
70
-
70
+  justify-content: flex-start;
71 71
 }
72 72
 .panelBottom1 .line1{
73 73
   height:98rpx;
@@ -77,7 +77,7 @@
77 77
 .program_tabbar_task_default {
78 78
   width: 54rpx;
79 79
   height: 54rpx;
80
-  margin-bottom: 4rpx;
80
+  margin: 10rpx 0 4rpx 0;
81 81
 }
82 82
 
83 83
 .text5{

+ 2 - 1
pages/main/searchCard1.json

@@ -1,3 +1,4 @@
1 1
 {
2
-  "navigationBarTitleText": "搜索中"
2
+  "navigationBarTitleText": "搜索中",
3
+  "backgroundColor": "#F0F0F0"
3 4
 }

+ 1 - 0
pages/main/searchCardList.json

@@ -1,4 +1,5 @@
1 1
 {
2 2
   "navigationBarTitleText": "全部题卡",
3
+  "backgroundColor": "#F0F0F0",
3 4
   "enablePullDownRefresh": true
4 5
 }

+ 2 - 1
pages/main/searchWeb.json

@@ -1,3 +1,4 @@
1 1
 {
2
-  "navigationBarTitleText": "搜索资料"
2
+  "navigationBarTitleText": "搜索资料",
3
+  "backgroundColor": "#F0F0F0"
3 4
 }

+ 2 - 1
pages/main/searchWeb1.json

@@ -1,3 +1,4 @@
1 1
 {
2
-  "navigationBarTitleText": "搜索中"
2
+  "navigationBarTitleText": "搜索中",
3
+  "backgroundColor": "#F0F0F0"
3 4
 }

+ 13 - 9
pages/main/searchWeb2.js

@@ -3,6 +3,7 @@ import main from '../../utils/main';
3 3
 
4 4
 const app = getApp();
5 5
 var back = 3;
6
+var isStart;
6 7
 
7 8
 Page({
8 9
   data: {
@@ -26,6 +27,8 @@ Page({
26 27
       
27 28
     });
28 29
 
30
+    isStart = true;
31
+
29 32
   },
30 33
   getList: function (word, type) {
31 34
 
@@ -139,8 +142,9 @@ Page({
139 142
       }
140 143
 
141 144
       this.data.CSS[css].Number = "1";
142
-      if (wx.getStorageSync("TempFieldNumber")) {
145
+      if (wx.getStorageSync("TempFieldNumber") && isStart) {
143 146
         this.data.CSS[css].Number = Number(wx.getStorageSync("TempFieldNumber"));
147
+        isStart=false;
144 148
       }
145 149
     }
146 150
     else if (this.data.CSS[css].Number == "3") {
@@ -153,14 +157,14 @@ Page({
153 157
     }
154 158
     else {
155 159
       this.data.CSS[css].Number = Number(this.data.CSS[css].Number) + 1;
156
-      if (wx.getStorageSync("TempFieldNumber")) {
157
-        this.data.CSS[css].Css1 = "";
158
-        this.data.CSS[css].Css2 = "";
159
-        this.data.CSS[css].Number = "";
160
-        this.data.CSS[css].Content = "";
161
-        this.data.CSS[css].Type = "";
162
-        this.data.CSS[css].Tag = "";
163
-      }
160
+      //if (wx.getStorageSync("TempFieldNumber")) {
161
+        // this.data.CSS[css].Css1 = "";
162
+        // this.data.CSS[css].Css2 = "";
163
+        // this.data.CSS[css].Number = "";
164
+        // this.data.CSS[css].Content = "";
165
+        // this.data.CSS[css].Type = "";
166
+        // this.data.CSS[css].Tag = "";
167
+      //}
164 168
     }
165 169
 
166 170
     this.setData({

+ 2 - 1
pages/main/searchWeb2.json

@@ -1,3 +1,4 @@
1 1
 {
2
-  "navigationBarTitleText": "资料"
2
+  "navigationBarTitleText": "资料",
3
+  "backgroundColor": "#F0F0F0"
3 4
 }

+ 2 - 1
pages/main/setting.json

@@ -1,3 +1,4 @@
1 1
 {
2
-  "navigationBarTitleText": "练习方案"
2
+  "navigationBarTitleText": "练习方案",
3
+  "backgroundColor": "#F0F0F0"
3 4
 }

+ 1 - 1
pages/main/setting.wxml

@@ -48,7 +48,7 @@
48 48
     <view class="panelTitle2"></view>
49 49
   </view>
50 50
   <view class="panelItem FlexRow" bindtap='setColorPlan'>
51
-    <view class="panelItem1">习中界面</view>
51
+    <view class="panelItem1">习中界面</view>
52 52
     <view class="panelItem2 FlexRow">
53 53
       <view class="picker">
54 54
         {{ColorName}}