chengjie před 7 roky
rodič
revize
c91a1fa063
35 změnil soubory, kde provedl 331 přidání a 216 odebrání
  1. binární
      images/Help_aside_answerroom_detail.png
  2. binární
      images/Help_aside_answerroom_list.png
  3. binární
      images/Help_aside_homepage.png
  4. binární
      images/Help_aside_makepaper.png
  5. binární
      images/Help_aside_questioncollection.png
  6. binární
      images/formula_division_size01.png
  7. binární
      images/formula_division_size02.png
  8. binární
      images/formula_division_size03.png
  9. binární
      images/formula_division_size04.png
  10. binární
      images/formula_division_size05.png
  11. binární
      images/formula_division_size06.png
  12. binární
      images/formula_division_size07.png
  13. binární
      images/formula_division_size08.png
  14. binární
      images/pause_white_size01.png
  15. binární
      images/questioncollection_headline_plate.png
  16. binární
      images/questioncollection_headline_plate01_selected.png
  17. binární
      images/questioncollection_headline_plate01_unselected.png
  18. binární
      images/questioncollection_headline_plate02_selected.png
  19. binární
      images/questioncollection_headline_plate02_unselected.png
  20. binární
      images/universalpic_play_white_size01.png
  21. binární
      images/universalpic_product_kongjian_icon_size01.png
  22. binární
      images/universalpic_rewind_white_size01.png
  23. 1 1
      pages/main/default.js
  24. 11 9
      pages/main/default.wxml
  25. 18 27
      pages/main/default.wxss
  26. 13 4
      pages/main/detail.js
  27. 1 1
      pages/main/detail.wxml
  28. 4 0
      pages/main/detail.wxss
  29. 60 15
      pages/main/item.js
  30. 27 18
      pages/main/item.wxml
  31. 40 6
      pages/main/item.wxss
  32. 3 18
      pages/main/list.js
  33. 59 52
      pages/main/list.wxml
  34. 86 64
      pages/main/list.wxss
  35. 8 1
      utils/main.js

binární
images/Help_aside_answerroom_detail.png


binární
images/Help_aside_answerroom_list.png


binární
images/Help_aside_homepage.png


binární
images/Help_aside_makepaper.png


binární
images/Help_aside_questioncollection.png


binární
images/formula_division_size01.png


binární
images/formula_division_size02.png


binární
images/formula_division_size03.png


binární
images/formula_division_size04.png


binární
images/formula_division_size05.png


binární
images/formula_division_size06.png


binární
images/formula_division_size07.png


binární
images/formula_division_size08.png


binární
images/pause_white_size01.png


binární
images/questioncollection_headline_plate.png


binární
images/questioncollection_headline_plate01_selected.png


binární
images/questioncollection_headline_plate01_unselected.png


binární
images/questioncollection_headline_plate02_selected.png


binární
images/questioncollection_headline_plate02_unselected.png


binární
images/universalpic_play_white_size01.png


binární
images/universalpic_product_kongjian_icon_size01.png


binární
images/universalpic_rewind_white_size01.png


+ 1 - 1
pages/main/default.js

@@ -155,7 +155,7 @@ Page({
155 155
 
156 156
     updateManager.onCheckForUpdate(function(res) {
157 157
       // 请求完新版本信息的回调
158
-      console.log(res.hasUpdate)
158
+      //console.log(res.hasUpdate)
159 159
     });
160 160
 
161 161
     updateManager.onUpdateReady(function() {

+ 11 - 9
pages/main/default.wxml

@@ -4,14 +4,15 @@
4 4
   </scroll-view>
5 5
 
6 6
   <view class="panel FlexColumn">
7
+    
7 8
     <view class="line1"></view>
8
-    <view class="line2"></view>
9 9
     <view class="panel0 FlexRow">
10
-      <view class="panel00Left"></view>
11 10
       <view class="panel00 FlexColumn">
11
+        
12 12
         <view class="panel000 FlexRow">
13
+        <view class="line2"></view>
13 14
           <view class="text">选题</view>
14
-          <view class="text">·</view>
15
+          <view class="text">+</view>
15 16
           <view class="text">打印</view>
16 17
         </view>
17 18
         <view class="panel001 FlexRow">
@@ -42,14 +43,16 @@
42 43
                     登录
43 44
                   </view>
44 45
                 </button>
45
-                <view class="btn" wx:if="{{IsAccredit}}" >
46
-                  <view class="btn1">
47
-                    设置
46
+                
47
+                <view class="btn2 btn" bindtap='gotoAnswer' wx:if="{{!IsAccredit}}">
48
+                  <view class="btn3 btn1">
49
+                    答案
48 50
                   </view>
49 51
                 </view>
50
-                <view class="btn2 btn" bindtap='gotoAnswer'>
52
+
53
+                <view class="btn6 btn2 btn' " wx:if="{{IsAccredit}}" bindtap='gotoAnswer' >
51 54
                   <view class="btn3 btn1">
52
-                    答案
55
+                    答案
53 56
                   </view>
54 57
                 </view>
55 58
               </view>
@@ -104,7 +107,6 @@
104 107
           </view>
105 108
         </view>
106 109
       </view>
107
-      <view class="panel00Right"></view>
108 110
     </view>
109 111
   </view>
110 112
 </view>

+ 18 - 27
pages/main/default.wxss

@@ -20,19 +20,14 @@
20 20
   justify-content: flex-start;
21 21
 }
22 22
 
23
-.line1 {
24
-  width: 100%;
25
-  height: 10rpx;
26
-  background-color: rgba(0, 0, 0, 0.16);
27
-}
28 23
 
29
-.line2 {
24
+.line1 {
30 25
   width: 100%;
31
-  height: 90rpx;
26
+  height: 120rpx;
32 27
   background-color: #291112;
33
-  margin-top: 30rpx;
34 28
 }
35 29
 
30
+
36 31
 .panel0 {
37 32
   width: 100%;
38 33
   position: absolute;
@@ -46,26 +41,19 @@
46 41
   justify-content: flex-start;
47 42
 }
48 43
 
49
-.panel00Left {
50
-  width: 15rpx;
51
-  height: 90rpx;
52
-  background-color: #3d211b;
53
-  border-top-left-radius: 6rpx;
54
-  border-bottom-left-radius: 6rpx;
55
-}
56
-
57
-.panel00Right {
58
-  width: 15rpx;
59
-  height: 90rpx;
60
-  background-color: #3d211b;
61
-  border-top-right-radius: 6rpx;
62
-  border-bottom-right-radius: 6rpx;
63
-}
64
-
65 44
 .panel000 {
66 45
   width: 100%;
67 46
   height: 90rpx;
68 47
   background-color: #4f2921;
48
+  position: relative;
49
+}
50
+
51
+.line2 {
52
+  width: 100%;
53
+  height: 10rpx;
54
+  background-color: rgba(0, 0, 0, 0.30);
55
+  position: absolute;
56
+  top:0;
69 57
 }
70 58
 
71 59
 .panel000 .text {
@@ -213,6 +201,11 @@
213 201
   background-color: #3b85d0;
214 202
 }
215 203
 
204
+.btn6 {
205
+  width: 430rpx;
206
+  margin-left: 0rpx;
207
+}
208
+
216 209
 .panel00201 {
217 210
   width: 160rpx;
218 211
   height: 160rpx;
@@ -231,7 +224,7 @@
231 224
 
232 225
 .panel003 {
233 226
   width: 100%;
234
-  height: 888rpx;
227
+  height: 1050rpx;
235 228
   background-color: #723c30;
236 229
   box-shadow: 0px 10px 0px rgba(0, 0, 0, 0.10);
237 230
   color: #edc1b4;
@@ -275,8 +268,6 @@
275 268
   width: 140rpx;
276 269
   height: 154rpx;
277 270
   border-radius: 20rpx;
278
-
279
-  
280 271
 }
281 272
 
282 273
 .btn5 {

+ 13 - 4
pages/main/detail.js

@@ -23,6 +23,7 @@ Page({
23 23
     arrPage: [],
24 24
     ShowLoading: false,
25 25
     IsDistabled: "",
26
+    NameClass:"",
26 27
   },
27 28
   onLoad: function (options) {
28 29
     var id = options.id;
@@ -53,13 +54,21 @@ Page({
53 54
           item = data[i].List[k];
54 55
           item.Example[0] = item.Example[0].replace("+", " + ").replace("-", " - ").replace("×", " × ").replace("÷", " ÷ ");
55 56
           item.Example[1] = item.Example[1].replace("+", " + ").replace("-", " - ").replace("×", " × ").replace("÷", " ÷ ");
57
+          if (item.Name.length>12)
58
+            item.NameClass="text2";
56 59
           break;
57 60
         }
58 61
       }
59 62
     }
63
+    
60 64
     this.setData({
61 65
       QuestionTypeItem: item,
62 66
     });
67
+
68
+    //有竖式则缺省竖式
69
+    if (item.QuestionNumber3 > 0) {
70
+      this.menuClick({ currentTarget: { dataset: { id: "vertical" } } })
71
+    }
63 72
   },
64 73
   gotoAnswer: function (e) {
65 74
     wx.navigateTo({
@@ -362,10 +371,10 @@ Page({
362 371
               duration: 300
363 372
             });
364 373
 
365
-            wx.previewImage({
366
-              current: that.data.arrPage[0], // 当前显示图片的http链接
367
-              urls: that.data.arrPage // 需要预览的图片http链接列表
368
-            });
374
+            // wx.previewImage({
375
+            //   current: that.data.arrPage[0], // 当前显示图片的http链接
376
+            //   urls: that.data.arrPage // 需要预览的图片http链接列表
377
+            // });
369 378
 
370 379
             //存列表
371 380
             var tempList = wx.getStorageSync("AnswerList");

+ 1 - 1
pages/main/detail.wxml

@@ -14,7 +14,7 @@
14 14
   <view class="line0"></view>
15 15
   <view class="line1 FlexColumn">
16 16
     <image class="makepaper_headline_illus_board FlexColumn" src="../../images/makepaper_headline_illus_board.png" />
17
-    <view class="text">
17
+    <view class="{{QuestionTypeItem.NameClass}} text">
18 18
       {{QuestionTypeItem.Name}}
19 19
     </view>
20 20
   </view>

+ 4 - 0
pages/main/detail.wxss

@@ -59,6 +59,10 @@
59 59
   margin-top: -80rpx;
60 60
   font-size:42rpx;
61 61
 }
62
+.line1 .text2{
63
+  font-size:32rpx;
64
+  margin-top: -70rpx;
65
+}
62 66
 
63 67
 
64 68
 .line2 {

+ 60 - 15
pages/main/item.js

@@ -10,25 +10,43 @@ Page({
10 10
   data: {
11 11
     version: app.globalData.version,
12 12
     FileUrl: app.globalData.fileUrl,
13
-    IsPlaying: true,
13
+    IsPlaying: 0,
14
+    PlayStr: "本",
15
+    selectTab0: "btn1",
16
+    selectTab1: "",
17
+    selectTab2: "",
14 18
   },
15 19
   onLoad: function (options) {
16 20
     this.audioCtx = wx.createAudioContext('myAudio');
17 21
 
18 22
     this.setData({
19 23
       Containnerheight: server.getWindowHeight(),
24
+      IsPlaying: 0,
20 25
     });
21 26
     audioArray = [];
22 27
     var id = options.id;
23 28
     this.getItem(id);
24 29
 
25 30
     wx.setNavigationBarTitle({
26
-      title: "试卷答案 "+id,
31
+      title: "试卷答案 " + id,
27 32
     });
28 33
 
29 34
   },
30 35
   scrollTop: function (e) {
31 36
     var id = Number(e.currentTarget.dataset.id);
37
+    var selectTab0 = "", selectTab1 = "", selectTab2 = "";
38
+    if (id == 0)
39
+      selectTab0 = "btn1";
40
+    else if (id == 1)
41
+      selectTab1 = "btn1";
42
+    else if (id == 2)
43
+      selectTab2 = "btn1";
44
+    this.setData({
45
+      selectTab0: selectTab0,
46
+      selectTab1: selectTab1,
47
+      selectTab2: selectTab2,
48
+    });
49
+
32 50
     var top = 0;
33 51
 
34 52
     var query = wx.createSelectorQuery();
@@ -62,6 +80,24 @@ Page({
62 80
           list[i].IsShowVertical = true;
63 81
           break;
64 82
         }
83
+
84
+      }
85
+
86
+      var list = item.QuestionList;
87
+      for (var i = 0; i < list.length; i++) {
88
+        if (list[i].OperateAB == '÷' && list[i].Vertical) {
89
+          list[i].LineLength = list[i].A.toString().length;
90
+          for (var k = 0; k < list[i].Vertical[1].Array.length; k++) {
91
+            list[i].Vertical[1].Array[k] = "";
92
+          }
93
+          for (var k = 0; k < list[i].Vertical[2].Array.length; k++) {
94
+            if (list[i].Vertical[2].Array[k] =="√"){
95
+              list[i].Vertical[2].Array[k]="";
96
+              list[i].Vertical[2].Array.push("√");
97
+              break;
98
+            }
99
+          }
100
+        }
65 101
       }
66 102
 
67 103
       that.setData({
@@ -93,14 +129,14 @@ Page({
93 129
     });
94 130
   },
95 131
   playAudioStart: function () {
96
-    this.setData({
97
-      IsPlaying: !this.data.IsPlaying,
98
-    });
99 132
 
100
-    if (this.data.IsPlaying) {
133
+    if (this.data.IsPlaying == 1) {
101 134
       this.audioCtx.pause();
102 135
     }
103
-    else {
136
+    else if (this.data.IsPlaying == -1) {
137
+      this.audioCtx.play();
138
+    }
139
+    else if (this.data.IsPlaying == 0) {
104 140
       var arr = [];
105 141
       var item = this.data.AnswerItem;
106 142
       var list = item.QuestionList;
@@ -127,6 +163,14 @@ Page({
127 163
       this.playAudioAll();
128 164
     }
129 165
 
166
+    if (this.data.IsPlaying == 1)
167
+      this.data.IsPlaying = -1;
168
+    else
169
+      this.data.IsPlaying = 1;
170
+    this.setData({
171
+      IsPlaying: this.data.IsPlaying,
172
+    });
173
+
130 174
   },
131 175
   playAudioAll: function () {
132 176
     if (currentIndex >= 3) {
@@ -142,13 +186,6 @@ Page({
142 186
       console.log(url);
143 187
       this.audioCtx.setSrc(url);
144 188
       this.audioCtx.play();
145
-      this.scrollTop({
146
-        currentTarget: {
147
-          dataset: {
148
-            id: currentIndex
149
-          }
150
-        }
151
-      });
152 189
     }
153 190
   },
154 191
   onPlayEnded: function (e) {
@@ -156,12 +193,20 @@ Page({
156 193
     this.playAudioAll();
157 194
   },
158 195
   playPrev: function () {
159
-    if (currentIndex > 0 && tempCurrentIndex == currentIndex)
196
+    var playstr = "本";
197
+    if (currentIndex > 0 && tempCurrentIndex == currentIndex) {
160 198
       currentIndex--;
199
+    }
161 200
     else {
162 201
       tempCurrentIndex = currentIndex;
202
+      playstr = "前";
203
+      if (currentIndex <= 0)
204
+        playstr = "本";
163 205
     }
164 206
     this.playAudioAll();
207
+    this.setData({
208
+      PlayStr: playstr,
209
+    });
165 210
   },
166 211
   onShareAppMessage: function () {
167 212
     return {

+ 27 - 18
pages/main/item.wxml

@@ -9,15 +9,22 @@
9 9
     <view class="panelLeft">听答案</view>
10 10
     <view class="panelRight FlexRow">
11 11
 
12
-      <view class="btn4 btn2" bindtap='playPrev'>
12
+      <view class="btn2" bindtap='playAudioStart'>
13 13
         <view class="btn3 FlexRow">
14
-          <image class="universalpic_rewind_white_size01" src="../../images/universalpic_rewind_white_size01.png" />
14
+          <view wx:if="{{IsPlaying==0 || IsPlaying==-1}}">播放</view>
15
+          <view wx:if="{{IsPlaying==1}}">暂停</view>
15 16
         </view>
16 17
       </view>
17
-      <view class="btn2" bindtap='playAudioStart'>
18
+
19
+      <view class="btn2" bindtap='playPrev' wx:if="{{IsPlaying!=0}}">
18 20
         <view class="btn3 FlexRow">
19
-          <image class="universalpic_play_white_size01" src="../../images/universalpic_play_white_size01.png" wx:if="{{IsPlaying}}" />
20
-          <image class="pause_white_size01" src="../../images/pause_white_size01.png" wx:if="{{!IsPlaying}}" />
21
+          <view>{{PlayStr}}列重播</view>
22
+        </view>
23
+      </view>
24
+
25
+      <view class="btn4 btn2" bindtap='playPrev' wx:if="{{IsPlaying==0}}">
26
+        <view class="btn5 btn3 FlexRow">
27
+          <view>{{PlayStr}}列重播</view>
21 28
         </view>
22 29
       </view>
23 30
     </view>
@@ -32,9 +39,9 @@
32 39
   <view class="panel0 FlexRow">
33 40
     <view class="panelLeft">题号快翻</view>
34 41
     <view class="panelRight FlexRow">
35
-      <view class="btn1 btn" bindtap="scrollTop" data-id="0">1</view>
36
-      <view class="btn" bindtap="scrollTop" data-id="1">{{AnswerItem.QuestionList.length/3+1}}</view>
37
-      <view class="btn" bindtap="scrollTop" data-id="2">{{AnswerItem.QuestionList.length*2/3+1}}</view>
42
+      <view class="{{selectTab0}} btn" bindtap="scrollTop" data-id="0">1</view>
43
+      <view class="{{selectTab1}} btn" bindtap="scrollTop" data-id="1">{{AnswerItem.QuestionList.length/3+1}}</view>
44
+      <view class="{{selectTab2}} btn" bindtap="scrollTop" data-id="2">{{AnswerItem.QuestionList.length*2/3+1}}</view>
38 45
     </view>
39 46
   </view>
40 47
 
@@ -77,7 +84,6 @@
77 84
           <view class="panelAnswerCol FlexRow" wx:for='{{item.Array}}' wx:key="i" wx:for-item="col" wx:for-index="i">
78 85
             <view class="colNumber" wx:if="{{item.Type=='number' && col!='√' && col!='.'}}">{{col}}</view>
79 86
             <view class="colDot" wx:if="{{item.Type=='number' && col=='.'}}">{{col}}</view>
80
-            <image wx:if="{{item.Type=='number' && col=='√'}}" class="formula_division_size01" src="../../images/formula_division_size01.png" />
81 87
             <view class="colLine" wx:if="{{item.Type=='line' && col=='1'}}"></view>
82 88
             <view class="colLineHalf" wx:if="{{item.Type=='line' && col=='0.5'}}"></view>
83 89
             <view class="colLineNull" wx:if="{{item.Type=='line' && col==''}}"></view>
@@ -88,14 +94,17 @@
88 94
     <!-- 算式(除) -->
89 95
     <view class="panelRowBody panel0 FlexColumn" wx:if="{{item.Vertical && item.OperateAB=='÷' && item.IsShowVertical}}">
90 96
       <view class="panelAnswer FlexColumn">
91
-        <view class="panelAnswerRow FlexRow" wx:for='{{item.Vertical}}' wx:key="index">
92
-          <view class="panelAnswerCol FlexRow" wx:for='{{item.Array}}' wx:key="i" wx:for-item="col" wx:for-index="i">
93
-            <view class="colNumber" wx:if="{{item.Type=='number' && col!='√' && col!='.'}}">{{col}}</view>
94
-            <view class="colDot" wx:if="{{item.Type=='number' && col=='.'}}">{{col}}</view>
95
-            <image wx:if="{{item.Type=='number' && col=='√'}}" class="formula_division_size01" src="../../images/formula_division_size01.png" />
96
-            <view class="colLine" wx:if="{{item.Type=='line' && col=='1'}}"></view>
97
-            <view class="colLineHalf" wx:if="{{item.Type=='line' && col=='0.5'}}"></view>
98
-            <view class="colLineNull" wx:if="{{item.Type=='line' && col==''}}"></view>
97
+        <view class="panelAnswerRow FlexRow" wx:for='{{item.Vertical}}' wx:for-item="itemChild" wx:key="index">
98
+          <view class="panelAnswerCol FlexRow" wx:for='{{itemChild.Array}}' wx:key="i" wx:for-item="col" wx:for-index="i">
99
+            <view class="colNumber" wx:if="{{itemChild.Type=='number' && col!='√' && col!='.'}}">{{col}}</view>
100
+            <view class="colDot" wx:if="{{itemChild.Type=='number' && col=='.'}}">{{col}}</view>
101
+            <view class="colLine" wx:if="{{itemChild.Type=='line' && col=='1'}}"></view>
102
+            <view class="colLineHalf" wx:if="{{itemChild.Type=='line' && col=='0.5'}}"></view>
103
+            <view class="colLineNull" wx:if="{{itemChild.Type=='line' && col==''}}"></view>
104
+            <image wx:if="{{itemChild.Type=='number' && col=='√'}}" class="formula_division_size0{{item.LineLength}} formula_division_size"
105
+              style='margin-left:{{ -57*item.LineLength-35 }}rpx;' 
106
+             src="../../images/formula_division_size0{{item.LineLength}}.png" />
107
+            
99 108
           </view>
100 109
         </view>
101 110
       </view>
@@ -106,6 +115,6 @@
106 115
 
107 116
   </block>
108 117
   <view wx:if="{{AnswerItem.PageCount<60}}" class="panelRowBody panel0 FlexRow" wx:for="{{[1,2,3]}}" wx:key="i"></view>
109
-  
118
+
110 119
 </view>
111 120
 <audio hidden='true' id="myAudio" bindended='onPlayEnded'></audio>

+ 40 - 6
pages/main/item.wxss

@@ -44,12 +44,12 @@
44 44
 
45 45
 
46 46
 .panelRight .btn2 {
47
-  width: 200rpx;
47
+  width: 168rpx;
48 48
   height: 70rpx;
49 49
   background-color: #146392;
50 50
   border-radius: 8rpx;
51 51
   position: relative;
52
-  margin-left: 30rpx;
52
+  margin-left: 20rpx;
53 53
 }
54 54
 
55 55
 .panelRight .btn3 {
@@ -57,12 +57,20 @@
57 57
   height: 60rpx;
58 58
   background-color: #169DED;
59 59
   border-radius: 8rpx;
60
+  font-size:32rpx;
61
+  color:#fff;
60 62
 }
61 63
 
62 64
 .panelRight .btn4 {
63
-  width: 130rpx;
65
+  background-color: #D2D2D2;
66
+}
67
+
68
+.panelRight .btn5 {
69
+  background-color: #F0F0F0;
70
+  color:#D2D2D2;
64 71
 }
65 72
 
73
+
66 74
 .universalpic_play_white_size01{
67 75
   width: 25rpx;
68 76
   height: 30rpx;
@@ -162,12 +170,37 @@
162 170
   justify-content: flex-start;
163 171
 }
164 172
 
165
-.formula_division_size01{
166
-  width:27rpx;
173
+.formula_division_size{
167 174
   height:77rpx;
168 175
   margin: -20rpx 25rpx 0 5rpx;
169 176
 }
170
-
177
+.formula_division_size01{
178
+  width:114rpx;
179
+}
180
+.formula_division_size02{
181
+  width:171rpx;
182
+}
183
+.formula_division_size03{
184
+  width:228rpx;
185
+}
186
+.formula_division_size04{
187
+  width:285rpx;
188
+}
189
+.formula_division_size04{
190
+  width:285rpx;
191
+}
192
+.formula_division_size05{
193
+  width:342rpx;
194
+}
195
+.formula_division_size06{
196
+  width:399rpx;
197
+}
198
+.formula_division_size07{
199
+  width:456rpx;
200
+}
201
+.formula_division_size08{
202
+  width:513rpx;
203
+}
171 204
 .panelAnswer .colNumber{
172 205
   font-size:48rpx;
173 206
   margin: 10rpx 15rpx;
@@ -176,6 +209,7 @@
176 209
   height:57rpx;
177 210
   text-align: center;
178 211
 }
212
+
179 213
 .panelAnswer .colDot{
180 214
   font-size:48rpx;
181 215
   margin: 10rpx -8rpx 0 -5rpx;

+ 3 - 18
pages/main/list.js

@@ -12,7 +12,6 @@ Page({
12 12
     version: app.globalData.version,
13 13
     FileUrl: app.globalData.fileUrl,
14 14
     filter: 'all',
15
-    IsShowMenu: false,
16 15
     CategoryID: 1,
17 16
   },
18 17
   onLoad: function (options) {
@@ -69,7 +68,7 @@ Page({
69 68
 
70 69
 
71 70
             for (var n = 0; n < arr.length; n++) {
72
-              //data[i].List[k].SelectItem = "";
71
+              data[i].List[k].SelectItem = "boxCenter";
73 72
               if (arr[n] == data[i].List[k].ID) {
74 73
                 data[i].List[k].SelectItem = "boxLeft";
75 74
               }
@@ -91,32 +90,18 @@ Page({
91 90
         }
92 91
       }
93 92
     }
94
-    var LineLongHeight = (list.length+1) * 190;
95
-    
96 93
     this.setData({
97 94
       QuestionTypeList: list,
98
-      LineLongHeight: LineLongHeight,
99 95
     });
100 96
 
101 97
   },
102
-  menuClick: function (e) {
103
-    this.data.filter = e.currentTarget.dataset.id;
98
+  openMenu: function (e) {
99
+    this.data.filter = e.currentTarget.dataset.filter;
104 100
     this.setData({
105 101
       filter: this.data.filter,
106
-      IsShowMenu: false,
107 102
     });
108 103
     this.buildList();
109 104
   },
110
-  closeMenu: function () {
111
-    this.setData({
112
-      IsShowMenu: false,
113
-    });
114
-  },
115
-  openMenu: function () {
116
-    this.setData({
117
-      IsShowMenu: true,
118
-    });
119
-  },
120 105
   onShareAppMessage: function () {
121 106
     return {
122 107
       title: app.globalData.ShareTitle,

+ 59 - 52
pages/main/list.wxml

@@ -4,36 +4,60 @@
4 4
   <view class="line2"></view>
5 5
   <view class="line3"></view>
6 6
   <image class="questioncollection_headline_root" src="../../images/questioncollection_headline_root.png" />
7
-  
8
-  <image class="questioncollection_headline_light" src="../../images/questioncollection_headline_light.png" bindtap='openMenu'/>
9
-  <image class="questioncollection_headline_shelf_illus_grade0{{CategoryNum}}" src="../../images/questioncollection_headline_shelf_illus_grade0{{CategoryNum}}.png"  bindtap='openMenu' />
10
-  <image class="questioncollection_headline_plate" src="../../images/questioncollection_headline_plate.png" wx:if="{{filter=='vertical'}}"/>
7
+
8
+  <image class="questioncollection_headline_light" src="../../images/questioncollection_headline_light.png" />
9
+  <view class="panelTop FlexRow">
10
+    <view class="panelTopLine lineLeft lineLong FlexRow">
11
+      <view class="panelTopLine1 lineLong1">
12
+      </view>
13
+    </view>
14
+    <view class="panelTopCenter">
15
+      <image class="questioncollection_headline_shelf_illus_grade0{{CategoryNum}}" src="../../images/questioncollection_headline_shelf_illus_grade0{{CategoryNum}}.png" />
16
+    </view>
17
+    <view class="panelTopLine1 lineRight lineLong FlexRow">
18
+      <view class="panelTopLine lineLong1">
19
+      </view>
20
+    </view>
21
+  </view>
22
+  <image class="questioncollection_headline_plate01_selected" src="../../images/questioncollection_headline_plate01_selected.png" wx:if="{{filter=='all'}}" />
23
+  <image bindtap='openMenu' data-filter="all" class="questioncollection_headline_plate01_selected" src="../../images/questioncollection_headline_plate01_unselected.png" wx:if="{{filter=='vertical'}}" />
24
+  <image class="questioncollection_headline_plate02_selected" src="../../images/questioncollection_headline_plate02_selected.png" wx:if="{{filter=='vertical'}}" />
25
+  <image bindtap='openMenu' data-filter="vertical" class="questioncollection_headline_plate02_selected" src="../../images/questioncollection_headline_plate02_unselected.png" wx:if="{{filter=='all'}}" />
11 26
 
12 27
 
13 28
   <block wx:for="{{QuestionTypeList}}" wx:key="index">
14 29
     <image class="questioncollection_shelf_board" src="../../images/questioncollection_shelf_board.png" bindtap='gotoDetail' data-id="{{item.ID}}" />
15
-    <view class="{{item.SelectItem}} questioncard FlexRow" bindtap='gotoDetail' data-id="{{item.ID}}">
16
-      <image class=" questioncollection_shelf_box" src="../../images/questioncollection_shelf_box.png" />
17
-      <image class="questioncard_icon" src="{{FileUrl}}questioncard_icon_grade0602_size01.png" />
18
-      <view class="title FlexColumn">
19
-        <view class="title1">
20
-          {{item.Name}}
30
+    <view class="questioncard FlexRow" bindtap='gotoDetail' data-id="{{item.ID}}">
31
+      <view class="lineLeft lineLong FlexRow">
32
+        <view class="lineLong1">
21 33
         </view>
22
-        <view class="title2 FlexRow">
23
-          <view class="title20 FlexRow">
24
-            {{item.CategoryLevel}}
34
+      </view>
35
+      <view class="{{item.SelectItem}} cardCenter FlexRow">
36
+        <image class="questioncollection_shelf_box" src="../../images/questioncollection_shelf_box.png" />
37
+        <image class="questioncard_icon" src="{{FileUrl}}questioncard_icon_grade0602_size01.png" />
38
+        <view class="title FlexColumn">
39
+          <view class="title1">
40
+            {{item.Name}}
25 41
           </view>
26
-          <view class="line"></view>
27
-          <view class="title21 FlexRow">
28
-            {{item.DifficultyName}}
42
+          <view class="title2 FlexRow">
43
+            <view class="title20 FlexRow">
44
+              {{item.CategoryLevel}}
45
+            </view>
46
+            <view class="line"></view>
47
+            <view class="title21 FlexRow">
48
+              {{item.DifficultyName}}
49
+            </view>
29 50
           </view>
30 51
         </view>
31
-      </view>
32
-      <image wx:if="{{item.SelectItem!='boxLeft'}}" class="questioncollection_shelf_box_tape" src="../../images/questioncollection_shelf_box_tape.png" />
33
-      <view class="title3" wx:if="{{item.QuestionNumber3>0}}">有竖式</view>
34
-
35
-      <image wx:if="{{item.Select}}" class="questioncollection_shelf_here" src="../../images/questioncollection_shelf_here.png" />
52
+        <image wx:if="{{item.SelectItem!='boxLeft'}}" class="questioncollection_shelf_box_tape" src="../../images/questioncollection_shelf_box_tape.png" />
53
+        <view class="title3" wx:if="{{item.QuestionNumber3>0}}">有竖式</view>
36 54
 
55
+        <image wx:if="{{item.Select}}" class="questioncollection_shelf_here" src="../../images/questioncollection_shelf_here.png" />
56
+      </view>
57
+      <view class="lineRight lineLong FlexRow">
58
+        <view class="lineLong1">
59
+        </view>
60
+      </view>
37 61
     </view>
38 62
 
39 63
   </block>
@@ -62,41 +86,24 @@
62 86
 
63 87
   </view> -->
64 88
 
65
-  <image class="questioncollection_shelf_footer_illus" src="../../images/questioncollection_shelf_footer_illus.png" />
66
-  <view class="line4"></view>
67
-
68
-  <view class="line5"></view>
69
-  <view class="line6" hidden="{{QuestionTypeList.length>0}}"></view>
70
-
71
-  <view class="lineLeft lineLong FlexRow" style="height:{{ LineLongHeight }}rpx;">
72
-    <view class="lineLong1">
73
-    </view>
74
-  </view>
75
-  <view class="lineRight lineLong FlexRow" style="height:{{ LineLongHeight }}rpx;">
76
-    <view class="lineLong2">
77
-    </view>
78
-  </view>
79
-
80
-  <view class="menu FlexColumn" wx:if="{{IsShowMenu}}">
81
-    <view class="text1">筛选题卡</view>
82
-    <view class="panel FlexRow" bindtap='menuClick' data-id="all">
83
-      <view>全部</view>
84
-      <image wx:if="{{filter=='all'}}" class="universalpic_select_on_black" src="../../images/universalpic_select_on_black.png" />
85
-
89
+  <view class="panelBottom panelTop FlexRow">
90
+    
91
+    <view class="line4"></view>
92
+    <view class="panelTopLine2 lineLeft lineLong FlexRow">
93
+      <view class="panelTopLine3 lineLong1">
94
+      </view>
86 95
     </view>
87
-    <view class="line"></view>
88
-    <view class="panel FlexRow" bindtap='menuClick' data-id="vertical">
89
-      <view>仅竖式</view>
90
-      <image wx:if="{{filter=='vertical'}}" class="universalpic_select_on_black" src="../../images/universalpic_select_on_black.png" />
91
-
96
+    <view class="panelTopCenter">
97
+      <image class="questioncollection_shelf_footer_illus" src="../../images/questioncollection_shelf_footer_illus.png" />
92 98
     </view>
93
-    <view class="line"></view>
94
-    <view class="line2"></view>
95
-    <view class="line"></view>
96
-    <view class="panel FlexRow" bindtap='closeMenu'>
97
-      <view>取消</view>
99
+    <view class="panelTopLine3 lineRight lineLong FlexRow">
100
+      <view class="panelTopLine2 lineLong1">
101
+      </view>
98 102
     </view>
99 103
 
100 104
   </view>
101 105
 
106
+  <view class="line5"></view>
107
+  <view class="line6" hidden="{{QuestionTypeList.length>0}}"></view>
108
+
102 109
 </view>

+ 86 - 64
pages/main/list.wxss

@@ -43,33 +43,62 @@
43 43
   z-index: 100;
44 44
 }
45 45
 
46
+.panelTop {
47
+  margin-top: 10rpx;
48
+  align-items: flex-end;
49
+  justify-content: center;
50
+  width: 100%;
51
+  height: 160rpx;
52
+}
53
+
54
+.panelTopLine{
55
+  border-top-left-radius: 8rpx;
56
+}
57
+.panelTopLine1{
58
+  border-top-right-radius: 8rpx;
59
+}
60
+
61
+.panelTopCenter{
62
+  width: 630rpx;
63
+  height: 160rpx;
64
+}
65
+
46 66
 .questioncollection_headline_shelf_illus_grade01 {
47 67
   width: 520rpx;
48 68
   height: 160rpx;
49
-  margin-top: 10rpx;
50 69
 }
70
+
51 71
 .questioncollection_headline_shelf_illus_grade02 {
52 72
   width: 545rpx;
53 73
   height: 140rpx;
54
-  margin-top: 10rpx;
55 74
 }
75
+
56 76
 .questioncollection_headline_shelf_illus_grade03 {
57 77
   width: 580rpx;
58 78
   height: 140rpx;
59
-  margin-top: 10rpx;
60 79
 }
80
+
61 81
 .questioncollection_headline_shelf_illus_grade04 {
62 82
   width: 529rpx;
63 83
   height: 130rpx;
64
-  margin-top: 10rpx;
65 84
 }
66 85
 
67
-.questioncollection_headline_plate {
86
+.questioncollection_headline_plate01_selected {
68 87
   width: 112rpx;
69 88
   height: 70rpx;
70 89
   position: absolute;
71
-  top: 240rpx;
72
-  left: 60rpx;
90
+  top: 186rpx;
91
+  left: 0rpx;
92
+  z-index: 100;
93
+}
94
+
95
+.questioncollection_headline_plate02_selected {
96
+  width: 112rpx;
97
+  height: 70rpx;
98
+  position: absolute;
99
+  top: 264rpx;
100
+  left: 0rpx;
101
+  z-index: 100;
73 102
 }
74 103
 
75 104
 .questioncollection_shelf_board {
@@ -79,9 +108,14 @@
79 108
 }
80 109
 
81 110
 .questioncard {
82
-  width: 580rpx;
111
+  width: 100%;
83 112
   height: 130rpx;
84 113
   margin-top: -40rpx;
114
+}
115
+
116
+.cardCenter {
117
+  width: 590rpx;
118
+  height: 130rpx;
85 119
   position: relative;
86 120
   justify-content: flex-start;
87 121
 }
@@ -93,11 +127,15 @@
93 127
 }
94 128
 
95 129
 .boxLeft {
96
-  margin-left: -20rpx;
130
+  margin: 0 28rpx 0 12rpx;
131
+}
132
+
133
+.boxCenter {
134
+  margin: 0 2rpx 0 38rpx;
97 135
 }
98 136
 
99 137
 .boxRight {
100
-  margin-right: -20rpx;
138
+  margin: 0 2rpx 0 38rpx;
101 139
 }
102 140
 
103 141
 .questioncard_icon {
@@ -177,44 +215,22 @@
177 215
   height: 318rpx;
178 216
   margin-top: 0rpx;
179 217
   z-index: 10;
218
+  position: relative;
180 219
 }
181 220
 
182
-.line4 {
183
-  width: 100%;
184
-  height: 100rpx;
185
-  background-color: #433d3b;
186
-  margin-top: -50rpx;
187
-}
188
-
189
-.line5 {
190
-  width: 100%;
191
-  height: 50rpx;
192
-  background-color: #514a47;
193
-}
194
-.line6 {
195
-  width: 100%;
196
-  height: 550rpx;
197
-  background-color: #514a47;
198
-}
199 221
 
200 222
 .lineLong {
201 223
   width: 30rpx;
202
-  height: 540rpx;
203
-  border-radius: 8rpx;
224
+  height: 190rpx;
204 225
   background-color: #4d4d4d;
226
+  margin-top: -60rpx;
205 227
 }
206 228
 
207 229
 .lineLeft {
208
-  position: absolute;
209
-  top: 168rpx;
210
-  left: 30rpx;
211 230
   justify-content: flex-end;
212 231
 }
213 232
 
214 233
 .lineRight {
215
-  position: absolute;
216
-  top: 168rpx;
217
-  right: 30rpx;
218 234
   justify-content: flex-start;
219 235
 }
220 236
 
@@ -222,8 +238,6 @@
222 238
   background-color: #6b6b6b;
223 239
   height: 100%;
224 240
   width: 10rpx;
225
-  border-top-right-radius: 8rpx;
226
-  border-bottom-right-radius: 8rpx;
227 241
 }
228 242
 
229 243
 .lineLong2 {
@@ -234,43 +248,51 @@
234 248
   border-bottom-left-radius: 8rpx;
235 249
 }
236 250
 
237
-.menu {
238
-  position: fixed;
239
-  bottom: 0;
240
-  width: 100%;
241
-  background-color: #d2d2d2;
242
-  z-index: 30;
251
+.universalpic_select_on_black {
252
+  height: 30rpx;
253
+  width: 30rpx;
254
+  position: absolute;
255
+  left: 40rpx;
256
+  top: 40rpx;
243 257
 }
244 258
 
245
-.menu .text1 {
246
-  font-size: 24rpx;
247
-  margin: 30rpx;
259
+.panelBottom {
260
+  height: 370rpx;
261
+  align-items: flex-start;
262
+
263
+  background-color: #3B3431;
264
+  position: relative;
248 265
 }
249 266
 
250
-.menu .panel {
251
-  font-size: 36rpx;
252
-  height: 111rpx;
253
-  width: 100%;
254
-  background-color: #fff;
267
+.panelTopLine2{
268
+  border-bottom-left-radius: 8rpx;
269
+  height:410rpx;
270
+  position: relative;
271
+  z-index: 10;
272
+}
273
+.panelTopLine3{
274
+  border-bottom-right-radius: 8rpx;
275
+  height:410rpx;
255 276
   position: relative;
277
+  z-index: 10;
256 278
 }
257 279
 
258
-.menu .line {
259
-  height: 2rpx;
280
+.line4 {
260 281
   width: 100%;
261
-  background-color: #e3e3e3;
282
+  height: 100rpx;
283
+  position: absolute;
284
+  bottom:0rpx;
285
+  background-color: #433D3B;
262 286
 }
263 287
 
264
-.menu .line2 {
265
-  height: 20rpx;
288
+.line5 {
266 289
   width: 100%;
267
-  background-color: #d2d2d2;
290
+  height: 50rpx;
291
+  background-color: #514a47;
268 292
 }
269 293
 
270
-.universalpic_select_on_black {
271
-  height: 30rpx;
272
-  width: 30rpx;
273
-  position: absolute;
274
-  left:40rpx;
275
-  top:40rpx;
276
-}
294
+.line6 {
295
+  width: 100%;
296
+  height: 550rpx;
297
+  background-color: #514a47;
298
+}

+ 8 - 1
utils/main.js

@@ -284,11 +284,18 @@ function getProgramList() {
284 284
     },
285 285
     {
286 286
       id: 90,
287
-      Name: "注意力练习",
287
+      Name: "注意力游戏",
288 288
       appId: 'wxa5e33c61fe37dd01',
289 289
       path: 'pages/index/index?SourceID=' + app.globalData.ProgramID,
290 290
       imageName: "universalpic_product_zhuyili_icon_size01",
291 291
     },
292
+    {
293
+      id: 127,
294
+      Name: "空间智力游戏",
295
+      appId: 'wxaa1a8b48d9853872',
296
+      path: 'pages/index/game?SourceID=' + app.globalData.ProgramID,
297
+      imageName: "universalpic_product_kongjian_icon_size01",
298
+    },
292 299
   ];
293 300
 }
294 301