chengjie лет назад: 7
Родитель
Сommit
8fe849d0e2

+ 1 - 0
app.js

@@ -15,6 +15,7 @@ App({
15
     IsProduction: true,
15
     IsProduction: true,
16
     ProgramID: 106,
16
     ProgramID: 106,
17
     AppID: "wx313a8f2c0741efe1",
17
     AppID: "wx313a8f2c0741efe1",
18
+    ShareTitle:"识字,让阅读赢在起点",
18
     userInfo: null,
19
     userInfo: null,
19
     fileUrl: "https://www.kylx365.com/",
20
     fileUrl: "https://www.kylx365.com/",
20
     serverUrl: "https://www.kylx365.com/apiData/",
21
     serverUrl: "https://www.kylx365.com/apiData/",

BIN
images/01001.png


BIN
images/07001.png


+ 1 - 10
pages/index/index.js

@@ -165,18 +165,9 @@ Page({
165
   },
165
   },
166
   onShareAppMessage: function () {
166
   onShareAppMessage: function () {
167
     return {
167
     return {
168
-      title: '让阅读赢在起点',
168
+      title: app.globalData.ShareTitle,
169
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
169
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
170
       imageUrl: '../../images/07001.png',
170
       imageUrl: '../../images/07001.png',
171
-      success: function (res) {
172
-
173
-      },
174
-      fail: function (err) {
175
-        console.log(err);
176
-      },
177
-      complete: function (res) {
178
-        console.log(res);
179
-      },
180
     }
171
     }
181
   },
172
   },
182
 })
173
 })

+ 1 - 1
pages/index/index.wxss

@@ -13,7 +13,7 @@
13
 }
13
 }
14
 
14
 
15
 .image01001 {
15
 .image01001 {
16
-  width: 513rpx;
16
+  width: 462rpx;
17
   height: 516rpx;
17
   height: 516rpx;
18
 }
18
 }
19
 
19
 

+ 1 - 10
pages/main/about.js

@@ -37,18 +37,9 @@ Page({
37
   },
37
   },
38
   onShareAppMessage: function () {
38
   onShareAppMessage: function () {
39
     return {
39
     return {
40
-      title: '让阅读赢在起点',
40
+      title: app.globalData.ShareTitle,
41
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
41
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
42
       imageUrl: '../../images/07001.png',
42
       imageUrl: '../../images/07001.png',
43
-      success: function (res) {
44
-
45
-      },
46
-      fail: function (err) {
47
-        console.log(err);
48
-      },
49
-      complete: function (res) {
50
-        console.log(res);
51
-      },
52
     }
43
     }
53
   },
44
   },
54
 })
45
 })

+ 1 - 11
pages/main/cooperation.js

@@ -71,19 +71,9 @@ Page({
71
   },
71
   },
72
   onShareAppMessage: function () {
72
   onShareAppMessage: function () {
73
     return {
73
     return {
74
-      title: '让阅读赢在起点',
74
+      title: app.globalData.ShareTitle,
75
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
75
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
76
       imageUrl: '../../images/07001.png',
76
       imageUrl: '../../images/07001.png',
77
-      success: function (res) {
78
-
79
-      },
80
-      fail: function (err) {
81
-        console.log(err);
82
-      },
83
-      complete: function (res) {
84
-        console.log(res);
85
-      },
86
     }
77
     }
87
   },
78
   },
88
-
89
 });
79
 });

+ 19 - 18
pages/main/detail.js

@@ -291,11 +291,14 @@ Page({
291
           var pinyinStr = "";
291
           var pinyinStr = "";
292
           if (pinyinItem.indexOf(",")>0){
292
           if (pinyinItem.indexOf(",")>0){
293
             pinyinItem=pinyinItem.substr(0,pinyinItem.indexOf(","));
293
             pinyinItem=pinyinItem.substr(0,pinyinItem.indexOf(","));
294
+            if (e && e.currentTarget.dataset.pinyin)
295
+              pinyinItem = e.currentTarget.dataset.pinyin;
296
+              
294
             pinyinStr = "(" + pinyin.getPinyinName(pinyinItem)+")";
297
             pinyinStr = "(" + pinyin.getPinyinName(pinyinItem)+")";
295
           }
298
           }
296
 
299
 
297
           var Name = this.data.List[this.data.CurrentIndex].Name;
300
           var Name = this.data.List[this.data.CurrentIndex].Name;
298
-          if (!this.data.IsAudioLengthChecked) {
301
+          if (!this.data.IsAudioLengthChecked || (e && e.currentTarget.dataset.pinyin)) {
299
             url = url.replace("[word]", Name + pinyinStr);
302
             url = url.replace("[word]", Name + pinyinStr);
300
             url = url.replace("spd=3", "spd=1");
303
             url = url.replace("spd=3", "spd=1");
301
           }
304
           }
@@ -390,12 +393,14 @@ Page({
390
     }, second);
393
     }, second);
391
   },
394
   },
392
   setCurrentWord: function (index, isShowPrev, isShowNext) {
395
   setCurrentWord: function (index, isShowPrev, isShowNext) {
393
-    this.setData({
396
+    var that=this;
397
+    that.setData({
394
       CurrentIndex: index,
398
       CurrentIndex: index,
395
       IsShowPrev: isShowPrev,
399
       IsShowPrev: isShowPrev,
396
       IsShowNext: isShowNext,
400
       IsShowNext: isShowNext,
397
       IsShowWordDetail: false,
401
       IsShowWordDetail: false,
398
     });
402
     });
403
+    
399
   },
404
   },
400
   getImageError: function () {
405
   getImageError: function () {
401
     var that = this;
406
     var that = this;
@@ -410,7 +415,7 @@ Page({
410
       that.initSearch();
415
       that.initSearch();
411
   },
416
   },
412
   getImageDownload: function () {
417
   getImageDownload: function () {
413
-    this.data.List[this.data.CurrentIndex].WordUrl += common.random(0, 9);
418
+    this.data.List[this.data.CurrentIndex].WordUrl += "?"+common.random(0, 9);
414
     this.setData({
419
     this.setData({
415
       List: this.data.List,
420
       List: this.data.List,
416
       IsImageError: false,
421
       IsImageError: false,
@@ -423,7 +428,11 @@ Page({
423
       this.setData({
428
       this.setData({
424
         IsShowWordDetail: this.data.IsShowWordDetail,
429
         IsShowWordDetail: this.data.IsShowWordDetail,
425
       });
430
       });
426
-
431
+      if (!this.data.IsShowWordDetail){
432
+        this.setData({
433
+          Detail: null,
434
+        });
435
+      }
427
       if (this.data.IsShowWordDetail) {
436
       if (this.data.IsShowWordDetail) {
428
         if (this.data.WordType == "search") {
437
         if (this.data.WordType == "search") {
429
           var result = wx.getStorageSync("CurrentSearchWord");
438
           var result = wx.getStorageSync("CurrentSearchWord");
@@ -676,11 +685,12 @@ Page({
676
 
685
 
677
     //this.animation = animation;
686
     //this.animation = animation;
678
     animation.opacity(opacity).step();
687
     animation.opacity(opacity).step();
679
-    this.setData({
680
-      animationData: animation.export(),
681
-    });
688
+    if (obj =="animationData"){
689
+      this.setData({
690
+        animationData: animation.export(),
691
+      });
692
+    }
682
   },
693
   },
683
-
684
   reviewHandler: function () {
694
   reviewHandler: function () {
685
     var that = this;
695
     var that = this;
686
     if (this.data.IsShowNext && !this.data.IsAutoPage) {
696
     if (this.data.IsShowNext && !this.data.IsAutoPage) {
@@ -725,18 +735,9 @@ Page({
725
   },
735
   },
726
   onShareAppMessage: function () {
736
   onShareAppMessage: function () {
727
     return {
737
     return {
728
-      title: '让阅读赢在起点',
738
+      title: app.globalData.ShareTitle,
729
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
739
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
730
       imageUrl: '../../images/07001.png',
740
       imageUrl: '../../images/07001.png',
731
-      success: function (res) {
732
-
733
-      },
734
-      fail: function (err) {
735
-        console.log(err);
736
-      },
737
-      complete: function (res) {
738
-        console.log(res);
739
-      },
740
     }
741
     }
741
   },
742
   },
742
 });
743
 });

+ 3 - 3
pages/main/detail.wxml

@@ -1,12 +1,12 @@
1
 <view class="container FlexColumn" style='height:{{Height}}rpx;'>
1
 <view class="container FlexColumn" style='height:{{Height}}rpx;'>
2
   <view class="main FlexColumn" bindtap='playAudio' data-click="true">
2
   <view class="main FlexColumn" bindtap='playAudio' data-click="true">
3
     <block wx:if="{{CurrentIndex<List.length-1}}">
3
     <block wx:if="{{CurrentIndex<List.length-1}}">
4
-      <view class="pinyin">
4
+      <view class="pinyin" animation="{{animationDataWord}}">
5
         <block wx:if="{{ShowPinyin}}">
5
         <block wx:if="{{ShowPinyin}}">
6
           {{List[CurrentIndex].Pinyin}}
6
           {{List[CurrentIndex].Pinyin}}
7
         </block>
7
         </block>
8
       </view>
8
       </view>
9
-      <image binderror='getImageError' wx:if="{{!IsImageError}}" src='{{List[CurrentIndex].WordUrl}}' class="wordImage" />
9
+      <image binderror='getImageError' wx:if="{{!IsImageError}}" src='{{List[CurrentIndex].WordUrl}}' class="wordImage" animation="{{animationDataWord}}"/>
10
       <image catchtap='getImageDownload' wx:if="{{IsImageError}}" src='../../images/05014.png' class="wordImage" />
10
       <image catchtap='getImageDownload' wx:if="{{IsImageError}}" src='../../images/05014.png' class="wordImage" />
11
     </block>
11
     </block>
12
     <block wx:if="{{CurrentIndex==List.length-1}}">
12
     <block wx:if="{{CurrentIndex==List.length-1}}">
@@ -31,7 +31,7 @@
31
     <view class="{{RemindCss}} Remind" animation="{{animationData}}">{{RemindStr}}</view>
31
     <view class="{{RemindCss}} Remind" animation="{{animationData}}">{{RemindStr}}</view>
32
 
32
 
33
   </view>
33
   </view>
34
-  <view class="detail" wx:if="{{IsShowWordDetail}}">
34
+  <view class="detail" wx:if="{{IsShowWordDetail}}" >
35
     <block wx:if="{{Detail.BiShunUrl}}">
35
     <block wx:if="{{Detail.BiShunUrl}}">
36
       <image src='{{Detail.BiShunUrl}}' class="bishun" />
36
       <image src='{{Detail.BiShunUrl}}' class="bishun" />
37
       <view class="line"></view>
37
       <view class="line"></view>

+ 1 - 10
pages/main/index.js

@@ -331,18 +331,9 @@ Page({
331
   },
331
   },
332
   onShareAppMessage: function () {
332
   onShareAppMessage: function () {
333
     return {
333
     return {
334
-      title: '让阅读赢在起点',
334
+      title: app.globalData.ShareTitle,
335
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
335
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
336
       imageUrl: '../../images/07001.png',
336
       imageUrl: '../../images/07001.png',
337
-      success: function (res) {
338
-
339
-      },
340
-      fail: function (err) {
341
-        console.log(err);
342
-      },
343
-      complete: function (res) {
344
-        console.log(res);
345
-      },
346
     }
337
     }
347
   },
338
   },
348
 })
339
 })

+ 1 - 10
pages/main/list.js

@@ -170,18 +170,9 @@ Page({
170
   },
170
   },
171
   onShareAppMessage: function () {
171
   onShareAppMessage: function () {
172
     return {
172
     return {
173
-      title: '让阅读赢在起点',
173
+      title: app.globalData.ShareTitle,
174
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
174
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
175
       imageUrl: '../../images/07001.png',
175
       imageUrl: '../../images/07001.png',
176
-      success: function (res) {
177
-
178
-      },
179
-      fail: function (err) {
180
-        console.log(err);
181
-      },
182
-      complete: function (res) {
183
-        console.log(res);
184
-      },
185
     }
176
     }
186
   },
177
   },
187
 })
178
 })

+ 1 - 10
pages/main/newuserlist.js

@@ -39,18 +39,9 @@ Page({
39
   },
39
   },
40
   onShareAppMessage: function () {
40
   onShareAppMessage: function () {
41
     return {
41
     return {
42
-      title: '让阅读赢在起点',
42
+      title: app.globalData.ShareTitle,
43
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
43
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
44
       imageUrl: '../../images/07001.png',
44
       imageUrl: '../../images/07001.png',
45
-      success: function (res) {
46
-
47
-      },
48
-      fail: function (err) {
49
-        console.log(err);
50
-      },
51
-      complete: function (res) {
52
-        console.log(res);
53
-      },
54
     }
45
     }
55
   },
46
   },
56
 })
47
 })

+ 1 - 10
pages/main/payfinished.js

@@ -28,18 +28,9 @@ Page({
28
   },
28
   },
29
   onShareAppMessage: function () {
29
   onShareAppMessage: function () {
30
     return {
30
     return {
31
-      title: '让阅读赢在起点',
31
+      title: app.globalData.ShareTitle,
32
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
32
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
33
       imageUrl: '../../images/07001.png',
33
       imageUrl: '../../images/07001.png',
34
-      success: function (res) {
35
-
36
-      },
37
-      fail: function (err) {
38
-        console.log(err);
39
-      },
40
-      complete: function (res) {
41
-        console.log(res);
42
-      },
43
     }
34
     }
44
   },
35
   },
45
 })
36
 })

+ 1 - 10
pages/main/paylist.js

@@ -34,18 +34,9 @@ Page({
34
   },
34
   },
35
   onShareAppMessage: function () {
35
   onShareAppMessage: function () {
36
     return {
36
     return {
37
-      title: '让阅读赢在起点',
37
+      title: app.globalData.ShareTitle,
38
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
38
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
39
       imageUrl: '../../images/07001.png',
39
       imageUrl: '../../images/07001.png',
40
-      success: function (res) {
41
-
42
-      },
43
-      fail: function (err) {
44
-        console.log(err);
45
-      },
46
-      complete: function (res) {
47
-        console.log(res);
48
-      },
49
     }
40
     }
50
   },
41
   },
51
 })
42
 })

+ 1 - 10
pages/main/search.js

@@ -78,18 +78,9 @@ Page({
78
   },
78
   },
79
   onShareAppMessage: function () {
79
   onShareAppMessage: function () {
80
     return {
80
     return {
81
-      title: '让阅读赢在起点',
81
+      title: app.globalData.ShareTitle,
82
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
82
       path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
83
       imageUrl: '../../images/07001.png',
83
       imageUrl: '../../images/07001.png',
84
-      success: function (res) {
85
-
86
-      },
87
-      fail: function (err) {
88
-        console.log(err);
89
-      },
90
-      complete: function (res) {
91
-        console.log(res);
92
-      },
93
     }
84
     }
94
   },
85
   },
95
 })
86
 })