chengjie 2 年之前
父节点
当前提交
42f1debbe6

二进制
package4/images/pay_shoppingguide_illus_03_106.png


二进制
package4/images/pay_shoppingguide_illus_03_99.png


+ 142 - 78
package4/main/activate.js

@@ -2,107 +2,171 @@ import common from '../../utils/util';
2
 import server from '../../utils/main';
2
 import server from '../../utils/main';
3
 
3
 
4
 const app = getApp();
4
 const app = getApp();
5
+var productList = [];
5
 
6
 
6
 Page({
7
 Page({
7
   data: {
8
   data: {
8
-    fileUrl: app.globalData.fileUrl,
9
   },
9
   },
10
   onLoad: function (options) {
10
   onLoad: function (options) {
11
-    var text0 = "", text1 = "", text2 = "", text3 = "";
12
-    text0 = "会员登录";
13
-    text1 = "无需注册,微信授权即可登录";
14
-    text2 = "去登录";
15
-    text3 = "注意:会员登录后可使用付费功能。授权微信用户信息即可一键登录。为保障消费权益,购买后请尽快授权用户信息。登录后才能正常使用统计、排行、我的订单、套装、礼品卡等功能。";
16
 
11
 
17
     this.setData({
12
     this.setData({
18
-      Height: common.getSystemHeight(),
19
-      Text0: text0,
20
-      Text1: text1,
21
-      Text2: text2,
22
-      Text3: text3,
23
-      OrderType: options.type,
13
+      Containnerheight: common.getSystemHeight(),
14
+      ProgramList: server.getProgramList(),
24
     });
15
     });
25
 
16
 
26
-    //适配ipad
27
-    var systemInfo = wx.getSystemInfoSync();
28
-    if (systemInfo.model) {
29
-      if (systemInfo.model.indexOf("iPad") >= 0) {
30
-        this.setData({
31
-          ipad: "ipad",
32
-        })
33
-      }
34
-    }
17
+    this.init();
35
   },
18
   },
36
-  //得到用户信息
37
-  getUserInfo: function () {
38
-    var that = this
39
-   
40
-    wx.getUserProfile({
41
-      desc: "登录注册",
42
-      success: function (res2) {
43
-        
44
-        app.globalData.userInfo.NickName = res2.userInfo.nickName;
45
-        app.globalData.userInfo.AvatarUrl = res2.userInfo.avatarUrl;
46
-        
47
-        //调用登录接口
48
-        wx.login({
49
-          success: function (res0) {
50
-            app.globalData.userInfo.Code = res0.code;
51
-            that.login(app.globalData.userInfo, res2.userInfo);
19
+  onUnload:function(){
20
+    productList=[];
21
+  },
22
+  init: function (e, isRemind) {
23
+    var that = this;
24
+    wx.showLoading({
25
+      title: '装载中',
26
+    });
27
+    server.getData('GetUserActivateListByUserID500?UserID=' + app.globalData.userInfo.UserID + "&ProductID=" + app.globalData.ProgramID, function (data) {
28
+      if (data && data.length > 0) {
29
+        var programList = server.getProgramList();
30
+        for (var i = 0; i < programList.length; i++) {
31
+          for (var j = 0; j < data.length; j++) {
32
+            if (programList[i].ID == data[j].ProductID) {
33
+              data[j].Name = programList[i].Name;
34
+              data[j].ImageUrl = programList[i].ImageUrl;
35
+              data[j].appId = programList[i].appId;
36
+              data[j].path = programList[i].path;
37
+              //不是当前小程序不解锁
38
+              if (app.globalData.ProgramID == data[j].ProductID)
39
+                app.globalData.userInfo.IsMember = 1;
40
+            }
41
+          }
42
+        }
43
+
44
+        if (productList.length > 0) {
45
+          for (var i = 0; i < productList.length; i++) {
46
+            var b = false;
47
+            for (var j = 0; j < data.length; j++) {
48
+              if (productList[i].ProductID == data[j].ProductID) {
49
+                b = true;
50
+                
51
+                break;
52
+              }
53
+            }
54
+            if (!b) {
55
+              productList[i].IsActivate = 1;
56
+              data.push(productList[i]);
57
+            }
52
           }
58
           }
59
+        }
60
+
61
+        that.setData({
62
+          List: data,
53
         });
63
         });
54
-      },
55
-      fail: function (res) {
56
-        console.log(res);
64
+
65
+        productList = data;
66
+
67
+        if (isRemind) {
68
+          wx.showModal({
69
+            title: '产品未激活',
70
+            content: '您有产品未激活,请立即点击红色“去激活”按钮。',
71
+            showCancel: false,
72
+            confirmText: "知道了",
73
+          });
74
+        }
75
+
76
+        wx.setStorageSync("HasActivate", 1);
77
+        wx.hideLoading();
78
+      }
79
+      else {
80
+        if (isRemind) {
81
+          var arr = [];
82
+          for (var i = 0; i < productList.length; i++) {
83
+            arr.push(productList[i].ProductID);
84
+          }
85
+          wx.redirectTo({
86
+            url: "./activateFinish?idarr="+arr.join(","),
87
+          });
88
+          productList = [];
89
+          wx.removeStorageSync("HasActivate");
90
+        }
91
+        else{
92
+          for (var i = 0; i < productList.length; i++) {
93
+            productList[i].IsActivate = 1;
94
+          }
95
+
96
+          if (productList.length>0){
97
+            that.setData({
98
+              List: productList,
99
+            });
100
+          }
101
+          else{
102
+            wx.removeStorageSync("HasActivate");
103
+            wx.showModal({
104
+              title: '提醒',
105
+              content: '产品已激活。',
106
+              showCancel: false,
107
+              confirmText: "去首页",
108
+              success:function(){
109
+                wx.reLaunch({
110
+                  url: '../../pages/index/index',
111
+                })
112
+              }
113
+            });
114
+          }
115
+        }
57
       }
116
       }
117
+      wx.hideLoading();
118
+
58
     });
119
     });
59
   },
120
   },
60
-  login: function (param, param2) {
121
+  gotoFeedback: function () {
122
+    server.gotoFeedback();
123
+  },
124
+  gotoActive: function (e) {
61
     var that = this;
125
     var that = this;
62
-    var url = "Login";
63
-    switch (app.globalData.ProgramID) {
64
-      case 164:
65
-        url = "MathStar" + url;
66
-        break;
67
-      case 105:
68
-        url = "Math" + url;
69
-        break;
70
-      case 106:
71
-        url = "Hanzi" + url;
72
-        break;
73
-      case 98:
74
-        url = "Pinyin" + url;
75
-        break;
76
-      case 99:
77
-        url = "Phonics" + url;
78
-        break;
126
+    var productid = e.currentTarget.dataset.id;
127
+
128
+    if (productid == app.globalData.ProgramID) {
129
+      server.getData('UpdateWXUsersAll500?ProductID=' + productid
130
+        + "&ProductUserID=" + app.globalData.userInfo.UserID
131
+        + "&CurrentProductID=" + productid
132
+        + "&CurrentUserID=" + app.globalData.userInfo.UserID, function (data) {
133
+          if (data) {
134
+
135
+          }
136
+        });
79
     }
137
     }
80
-    server.postData(url, {
81
-      Code: param.Code,
82
-      NickName: param2.nickName,
83
-      AvatarUrl: param2.avatarUrl,
84
-      Language: param2.language,
85
-      Gender: param2.gender,
86
-      City: param2.city,
87
-      Province: param2.province,
88
-      Country: param2.country,
89
-      ProgramVersion: app.globalData.Version,
90
-      Introducer: app.globalData.introducer,
91
-      UserSource: app.globalData.userSource,
92
-      SourceID: app.globalData.SourceID,
93
-      LastUserSource: app.globalData.userSource,
94
-      iv: param.iv,
95
-      encryptedData: param.encryptedData,
96
-    }, function (data) {
97
-      wx.navigateBack({
98
-        delta: 1
138
+    else {
139
+      var appId = e.currentTarget.dataset.appid;
140
+      var path = e.currentTarget.dataset.path;
141
+
142
+      path += "&ProductID=" + app.globalData.ProgramID;
143
+      path += "&ProductUserID=" + app.globalData.userInfo.UserID;
144
+
145
+      wx.navigateToMiniProgram({
146
+        appId: appId,
147
+        path: path,
148
+        success(res) {
149
+
150
+        }
99
       });
151
       });
152
+    }
153
+    var data = this.data.List;
154
+    for (var i = 0; i < data.length; i++) {
155
+      if (data[i].ProductID == productid) {
156
+        data[i].IsActivate = 0;
157
+      }
158
+    }
159
+    that.setData({
160
+      List: data,
100
     });
161
     });
101
   },
162
   },
163
+  gotoFinish: function () {
164
+    this.init(null, true);
165
+  },
102
   onShareAppMessage: function () {
166
   onShareAppMessage: function () {
103
     return {
167
     return {
104
       title: app.globalData.ShareTitle,
168
       title: app.globalData.ShareTitle,
105
-      path: 'pages/index/index?UserID=' + app.globalData.userInfo.UserID,
169
+      path: app.globalData.SharePath + '?UserID=' + app.globalData.userInfo.UserID,
106
       imageUrl: app.globalData.ShareImage,
170
       imageUrl: app.globalData.ShareImage,
107
     }
171
     }
108
   },
172
   },

+ 4 - 2
package4/main/activate.json

@@ -1,4 +1,6 @@
1
 {
1
 {
2
-  "navigationBarTitleText": "会员登录",
3
-  "enablePullDownRefresh": false
2
+  "navigationBarTitleText": "激活产品",
3
+  "navigationBarBackgroundColor": "#ffffff",
4
+  "navigationBarTextStyle": "black",
5
+  "backgroundColor": "#F0F0F0"
4
 }
6
 }

+ 32 - 8
package4/main/activate.wxml

@@ -1,10 +1,34 @@
1
-<view class="container FlexColumn" style='height:{{Height}}rpx;'>
2
-  <image src="../images/accredit.png" class="bg" />
3
-  <text class="text0">{{Text0}}</text>
4
-  <text class="text1">{{Text1}}</text>
5
-  <view class="btn">
6
-    <button  class="btn1" catchtap="getUserInfo">{{Text2}}</button>
1
+<view class="container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
2
+  <view class='text1 FlexColumn' bindtap='gotoFeedback'>
3
+    <view>您有产品未激活,必须激活才能继续其它操作,请立即处理。如</view>
4
+    <view class='FlexRow'>
5
+      <view>遇到问题请切换到“唱意教育家长助手”通过</view>
6
+      <view class='text11'>意见反馈</view>
7
+      <view>联系我们为</view>
8
+    </view>
9
+    <view>您处理。</view>
10
+  </view>
11
+
12
+  <view class="panelItem FlexRow" wx:for="{{List}}" wx:key="index">
13
+    <view class="Left FlexRow">
14
+      <image src='../images/{{item.ImageUrl}}' class="img" />
15
+      <view class="title1">
16
+        {{item.Name}}
17
+      </view>
18
+    </view>
19
+    <view class="Right">
20
+      <view class='btnActivate' wx:if="{{item.IsActivate==-1}}" bindtap="gotoActive" data-id="{{item.ProductID}}" data-appid="{{item.appId}}" data-path="{{item.path}}">去激活</view>
21
+      <view class='btnRefresh btnActivate' wx:if="{{item.IsActivate==0}}" bindtap="init">刷新</view>
22
+      <view class='text2' wx:if="{{item.IsActivate==1}}">已激活</view>
23
+    </view>
24
+  </view>
25
+  <view class='lineFooter'></view>
26
+
27
+  <image src='../images/file_0401.png' class="file_0401" />
28
+  <view class='lineFooter'></view>
29
+  <view style='height:240rpx'></view>
30
+
31
+  <view class='footer FlexRow' bindtap="gotoFinish">
32
+    完成
7
   </view>
33
   </view>
8
-  <view class="line2 {{ipad}}"></view>
9
-  <text class="text3">{{Text3}}</text>
10
 </view>
34
 </view>

+ 64 - 56
package4/main/activate.wxss

@@ -1,75 +1,83 @@
1
-.bg{
2
-  width: 100%;
3
-  height:769rpx;
4
-  position: fixed;
5
-  bottom: 0;
6
-  left:0;
1
+.container {
2
+  background-color: #f0f0f0;
3
+  color:#1e1e1e;
4
+  font-weight: 500;
7
 }
5
 }
8
 
6
 
9
-.text0{
10
-  font-size:36rpx;
11
-  text-align: center;
12
-  margin-top: 280rpx;
13
-  z-index: 10;
7
+.text1{
8
+  width:690rpx;
9
+  font-size:24rpx;
10
+  align-items: flex-start;
11
+  margin: 50rpx 0;
14
 }
12
 }
15
 
13
 
16
-.text1{
17
-  font-size:44rpx;
18
-  text-align: center;
19
-  margin-top: 10rpx;
20
-  z-index: 10;
14
+.text11{
15
+  color:#B3443B;
16
+  text-decoration: underline;
21
 }
17
 }
22
 
18
 
19
+.panelItem{
20
+  width:100%;
21
+  height:111rpx;
22
+  background-color: #fff;
23
+  justify-content: space-between;
24
+  margin-top: 1rpx;
25
+}
23
 
26
 
24
-.btn {
25
-  width: 600rpx;
26
-  height: 104rpx;
27
-  background-color: #035834;
28
-  border-radius: 14rpx;
29
-  margin-top: 90rpx;
30
-  z-index: 10;
27
+.Left {
28
+  margin-left: 30rpx;
29
+  justify-content: flex-start;
31
 }
30
 }
32
 
31
 
33
-.btn1 {
34
-  width: 100%;
35
-  height: 90rpx;
36
-  background-color: #03AF69;
37
-  border-radius: 14rpx;
38
-  position:relative;
39
-  top:0;
40
-  font-size: 36rpx;
41
-  text-align: center;
42
-  line-height: 90rpx;
43
-  color:#fff;
32
+.Right {
33
+  margin-right: 30rpx;
34
+  justify-content: flex-end;
44
 }
35
 }
45
 
36
 
46
-.line2{
47
-  width: 600rpx;
48
-  height:3rpx;
49
-  background-color: #593613;
50
-  margin-top:350rpx;
51
-  z-index: 10;
37
+.img{
38
+  width:50rpx;
39
+  height:50rpx;
40
+  border-radius: 10rpx;
52
 }
41
 }
53
 
42
 
54
-.ipad{
55
-  margin-top:140rpx;
43
+.title1{
44
+  margin-left: 20rpx;
45
+  font-size:28rpx;
56
 }
46
 }
57
 
47
 
58
-.text3{
59
-  font-size:22rpx;
60
-  width:560rpx; 
61
-  margin-top: 40rpx;
62
-  z-index: 10;
63
-  font-weight: 400;
48
+.btnActivate{
49
+  width:108rpx;
50
+  height:50rpx;
51
+  border-radius: 10rpx;
52
+  background-color: #E5321C;
53
+  color:#fff;
54
+  font-size:24rpx;
55
+  text-align: center;
56
+  line-height: 50rpx;
57
+}
58
+.btnRefresh{
59
+  background-color: #0792E4;
60
+}
61
+.text2{
62
+  color:#329468;
63
+  font-size:28rpx;
64
 }
64
 }
65
 
65
 
66
-.buyOK{
67
-  width: 106rpx;
68
-  height:106rpx;
69
-  margin-top: 120rpx;
66
+.file_0401{
67
+  width:100%;
68
+  height:1879rpx;
69
+  margin-top: 50rpx;
70
 }
70
 }
71
-.text4{
72
-  font-size:64rpx;
73
-  margin-top: 20rpx;
74
-  font-weight: 500;
71
+
72
+
73
+.footer{
74
+  width: 100%;
75
+  height: 140rpx;
76
+  position: fixed;
77
+  bottom: 0;
78
+  line-height: 140rpx;
79
+  font-size:48rpx;
80
+  color:#fff;
81
+  text-align: center;
82
+  background-color: #0792E4;
75
 }
83
 }

+ 2 - 7
package4/main/giftinfo.js

@@ -34,12 +34,7 @@ Page({
34
     var that=this;
34
     var that=this;
35
     wx.getSetting({
35
     wx.getSetting({
36
       success(res) {
36
       success(res) {
37
-        if (!res.authSetting['scope.userInfo']) {
38
-          wx.navigateTo({
39
-            url: '../../pages/main/accredit?url=giftinfo'
40
-          });
41
-        }
42
-        else {
37
+        
43
           wx.showModal({
38
           wx.showModal({
44
             title: '慎重转发',
39
             title: '慎重转发',
45
             content: '请勿转发到群。如误转,只能在聊天窗口中撤回(1分钟内)。',
40
             content: '请勿转发到群。如误转,只能在聊天窗口中撤回(1分钟内)。',
@@ -49,7 +44,7 @@ Page({
49
           that.setData({
44
           that.setData({
50
             canGive: true,
45
             canGive: true,
51
           });
46
           });
52
-        }
47
+        
53
       }
48
       }
54
     });
49
     });
55
     
50
     

+ 1 - 1
package4/main/miaoguoreadme.wxml

@@ -1,6 +1,6 @@
1
 <view class="container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
1
 <view class="container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
2
   <view class="text1">活动规则</view>
2
   <view class="text1">活动规则</view>
3
-  <text class="text2">① 本活动只针对自2021年3月??日起报名秒过的用户,在此之前报名的老用户不享受此活动优惠项目。\n
3
+  <text class="text2">① 本活动只针对自2021年3月1日起报名秒过的用户,在此之前报名的老用户不享受此活动优惠项目。\n
4
 ② 秒过新手培训只能报名一次,不能重复报名。\n
4
 ② 秒过新手培训只能报名一次,不能重复报名。\n
5
 ③ 符合本活动规则的有效报名是指:打开秒过小程序;支付报名费;关注秒过学习法公众号;添加班务员微信;收到班务员开班安排的通知。以上整个流程中的任何环节均不可或缺。请按系统引导信息一步步完成。\n
5
 ③ 符合本活动规则的有效报名是指:打开秒过小程序;支付报名费;关注秒过学习法公众号;添加班务员微信;收到班务员开班安排的通知。以上整个流程中的任何环节均不可或缺。请按系统引导信息一步步完成。\n
6
 ④ 有效报名可获得唱意公司旗下5款产品各20天免费有效期。产品包括:语文汉语拼音、语文识字、英语自然拼读、数学计算题、口算星球。\n
6
 ④ 有效报名可获得唱意公司旗下5款产品各20天免费有效期。产品包括:语文汉语拼音、语文识字、英语自然拼读、数学计算题、口算星球。\n

+ 2 - 9
package4/main/payfinish.js

@@ -20,10 +20,7 @@ Page({
20
       wx.hideLoading();
20
       wx.hideLoading();
21
     },5000);
21
     },5000);
22
 
22
 
23
-    if (paytype == "4") {
24
-      wx.setStorageSync("HasActivate", 1);
25
-    }
26
-    else if (paytype=="3"){
23
+    if (paytype=="3"){
27
       app.globalData.userInfo.IsMember = 1;
24
       app.globalData.userInfo.IsMember = 1;
28
       app.globalData.IsLocked=0;
25
       app.globalData.IsLocked=0;
29
     }
26
     }
@@ -43,11 +40,7 @@ Page({
43
         url: "./limited?IsShowButton=1",
40
         url: "./limited?IsShowButton=1",
44
       });
41
       });
45
     }
42
     }
46
-    if (this.data.Paytype == "4") {
47
-      wx.redirectTo({
48
-        url: "./activate",
49
-      });
50
-    }
43
+   
51
     if (this.data.Paytype == "5") {
44
     if (this.data.Paytype == "5") {
52
       wx.redirectTo({
45
       wx.redirectTo({
53
         url: "./giftlist",
46
         url: "./giftlist",

+ 56 - 1
package4/main/paylist.js

@@ -6,12 +6,20 @@ const app = getApp();
6
 Page({
6
 Page({
7
   data: {
7
   data: {
8
     PayList: null,
8
     PayList: null,
9
+    IsLogin:1,
9
   },
10
   },
10
   onLoad: function (options) {
11
   onLoad: function (options) {
11
     this.setData({
12
     this.setData({
12
       Containnerheight: common.getSystemHeight(),
13
       Containnerheight: common.getSystemHeight(),
13
     });
14
     });
14
-    this.init();
15
+
16
+    if (app.globalData.userInfo)
17
+      this.init();
18
+    else{
19
+      this.setData({
20
+        IsLogin: -1,
21
+      });
22
+    }
15
   },
23
   },
16
   init: function () {
24
   init: function () {
17
     var that = this;
25
     var that = this;
@@ -31,16 +39,63 @@ Page({
31
           }
39
           }
32
         }
40
         }
33
         that.setData({
41
         that.setData({
42
+          IsLogin: 1,
34
           PayList: data,
43
           PayList: data,
35
         });
44
         });
36
       }
45
       }
37
       else {
46
       else {
38
         that.setData({
47
         that.setData({
48
+          IsLogin: 1,
39
           PayList: [],
49
           PayList: [],
40
         });
50
         });
41
       }
51
       }
42
     });
52
     });
43
   },
53
   },
54
+  showLogin:function(){
55
+    this.setData({
56
+      IsLogin: -2,
57
+    });
58
+  },
59
+  hideLogin:function(){
60
+    this.setData({
61
+      IsLogin: -1,
62
+    });
63
+  },
64
+  onKeyInput: function (e) {
65
+    var that=this; 
66
+    that.setData({
67
+      UserName: e.detail.value
68
+    });
69
+  },
70
+  onKeyInput2: function (e) {
71
+    var that=this; 
72
+    that.setData({
73
+      UserPwd: e.detail.value
74
+    });
75
+  },
76
+  login: function () {
77
+    var that = this;
78
+
79
+    server.getData('Login20221228?UserName=' + that.data.UserName + "&UserPwd="+that.data.UserPwd+"&ProductID=" + app.globalData.ProgramID, function (data) {
80
+      if (data) {
81
+        if (data>0){
82
+            app.globalData.userInfo={};
83
+            app.globalData.userInfo.UserID=data;
84
+            that.init();
85
+        }
86
+        else {
87
+          wx.showToast({
88
+            title: '用户名或密码不正确',
89
+          });
90
+        }
91
+      }
92
+      else {
93
+        wx.showToast({
94
+          title: '登录出错',
95
+        });
96
+      }
97
+    });
98
+  },
44
   onShareAppMessage: function () {
99
   onShareAppMessage: function () {
45
     return {
100
     return {
46
       title: app.globalData.ShareTitle,
101
       title: app.globalData.ShareTitle,

+ 18 - 0
package4/main/paylist.wxml

@@ -1,4 +1,5 @@
1
 <view class="container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
1
 <view class="container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
2
+  
2
   <view style='height:50rpx'></view>
3
   <view style='height:50rpx'></view>
3
   <view class="panel1 FlexColumn" wx:for="{{PayList}}" wx:key="index" wx:if="{{PayList.length>0}}">
4
   <view class="panel1 FlexColumn" wx:for="{{PayList}}" wx:key="index" wx:if="{{PayList.length>0}}">
4
     <view class="item0 item FlexRow">
5
     <view class="item0 item FlexRow">
@@ -54,4 +55,21 @@
54
   </view>
55
   </view>
55
 
56
 
56
   <view class='panelNull' wx:if="{{PayList.length==0}}">没有帐单</view>
57
   <view class='panelNull' wx:if="{{PayList.length==0}}">没有帐单</view>
58
+
59
+  <view class="panelIsLogin" wx:if="{{IsLogin==-1}}" bindtap="showLogin">
60
+    登录查看订单
61
+  </view>
62
+  
63
+  <view  wx:if="{{IsLogin==-2}}" class="panelLogin FlexColumn" style='height:{{Containnerheight}}rpx;'>
64
+    <view class="panelLogin1 FlexColumn">
65
+      <view class="text1">用户名</view>
66
+      <input class="input" bindinput="onKeyInput" value="{{UserName}}"/>
67
+      <view class="text1">密码</view>
68
+      <input class="input" password="true" bindinput="onKeyInput2" value="{{UserPwd}}"/>
69
+      <view class="panelLogin2 FlexRow">
70
+        <view class="panelLogin21" bindtap="hideLogin">取消</view>
71
+        <view class="panelLogin21" bindtap="login">登录</view>
72
+      </view>
73
+    </view>
74
+  </view>
57
 </view>
75
 </view>

+ 55 - 0
package4/main/paylist.wxss

@@ -104,4 +104,59 @@
104
 .panelNull{
104
 .panelNull{
105
   margin-top: 462rpx;
105
   margin-top: 462rpx;
106
   font-size:48rpx;
106
   font-size:48rpx;
107
+}
108
+
109
+.panelIsLogin{
110
+  background: #FFFFFF;
111
+  border: 4rpx solid #E65A20;
112
+  border-radius: 20rpx;
113
+  font-size: 36rpx;
114
+  color: #E65A20;
115
+  text-align: center;
116
+  width:500rpx;
117
+  height:100rpx;
118
+  line-height: 100rpx;
119
+  margin-top: 400rpx;
120
+}
121
+
122
+.panelLogin{
123
+  width:100%;
124
+  background-color: rgba(0,0,0,0.5);
125
+  position: fixed;
126
+  top:0;
127
+}
128
+.panelLogin1{
129
+  width:560rpx;
130
+  height:577rpx;
131
+  position: fixed;
132
+  top:313rpx;
133
+  background-color: #fff;
134
+  border-radius: 8rpx;
135
+  justify-content: flex-start;
136
+}
137
+.text1{
138
+  width:480rpx;
139
+  margin-top: 60rpx;
140
+  font-size: 28rpx;
141
+}
142
+.input{
143
+  width:480rpx;
144
+  height:90rpx;
145
+  background:#FFFFFF;
146
+  border: 1rpx solid #979797;
147
+  margin-top:20rpx;
148
+  color:#1e1e1e;
149
+  padding-left: 10rpx;
150
+}
151
+
152
+.panelLogin2{
153
+  width:100%;
154
+  margin-top: 74rpx;
155
+}
156
+
157
+.panelLogin21{
158
+  width:280rpx;
159
+  text-align: center;
160
+  font-size:36rpx;
161
+  font-weight: 400;
107
 }
162
 }

+ 14 - 11
pages/index/index.js

@@ -127,17 +127,20 @@ Page({
127
         else {
127
         else {
128
           app.globalData.userInfo = data;
128
           app.globalData.userInfo = data;
129
 
129
 
130
-          var isShow = data.IsShow;
131
-          if (isShow == -1) {
132
-            isShow = 0;
133
-          }
134
-          else {
135
-            var systemInfo = wx.getSystemInfoSync();
136
-            if (isShow == 0 && systemInfo.system && systemInfo.system.indexOf("Android") >= 0) {
137
-              isShow = 1;
138
-            }
139
-          }
140
-          app.globalData.userInfo.IsShow = isShow;
130
+          //app.globalData.userInfo.AvatarUrl = param.avatarUrl;
131
+
132
+          // var isShow = data.IsShow;
133
+          // if (isShow == -1) {
134
+          //   isShow = 0;
135
+          // }
136
+          // else {
137
+          //   var systemInfo = wx.getSystemInfoSync();
138
+          //   if (isShow == 0 && systemInfo.system && systemInfo.system.indexOf("Android") >= 0) {
139
+          //     isShow = 1;
140
+          //   }
141
+          // }
142
+          // app.globalData.userInfo.IsShow = isShow;
143
+          app.globalData.userInfo.IsShow = data.IsShow;
141
 
144
 
142
           app.globalData.IsLocked = data.IsLocked;
145
           app.globalData.IsLocked = data.IsLocked;
143
           
146
           

+ 11 - 22
pages/main/index.js

@@ -94,24 +94,19 @@ Page({
94
       AvatarUrl: app.globalData.userInfo.AvatarUrl,
94
       AvatarUrl: app.globalData.userInfo.AvatarUrl,
95
     });
95
     });
96
     
96
     
97
-    if (wx.getStorageSync("HasActivate") == 1) {
97
+    
98
+    this.getData();
99
+
100
+    if (app.globalData.goto) {
101
+      var url = "../main/list?id=1";
102
+      if (app.globalData.goto == "test")
103
+        url = '../main/test';
98
       wx.navigateTo({
104
       wx.navigateTo({
99
-        url: '../../package4/main/activate',
105
+        url: url,
100
       });
106
       });
107
+      app.globalData.goto = "";
101
     }
108
     }
102
-    else {
103
-      this.getData();
104
-
105
-      if (app.globalData.goto) {
106
-        var url = "../main/list?id=1";
107
-        if (app.globalData.goto == "test")
108
-          url = '../main/test';
109
-        wx.navigateTo({
110
-          url: url,
111
-        });
112
-        app.globalData.goto = "";
113
-      }
114
-    }
109
+    
115
     var miaoguoADTime = wx.getStorageSync("miaoguoADTime");
110
     var miaoguoADTime = wx.getStorageSync("miaoguoADTime");
116
     if (miaoguoADTime) {
111
     if (miaoguoADTime) {
117
       if (this.data.IsShow == 1 && this.data.IsMember == 1 && isMiaoguoADShow && common.formatTime(new Date()) >= miaoguoADTime) {
112
       if (this.data.IsShow == 1 && this.data.IsMember == 1 && isMiaoguoADShow && common.formatTime(new Date()) >= miaoguoADTime) {
@@ -254,13 +249,7 @@ Page({
254
     });
249
     });
255
   },
250
   },
256
   gotoMemberCenter: function () {
251
   gotoMemberCenter: function () {
257
-    if (app.globalData.userInfo.NickName=="陌生用户" && app.globalData.userInfo.IsShow>0) {
258
-      //请去授权
259
-      wx.navigateTo({
260
-        url: './accredit?type=accredit',
261
-      });
262
-    }
263
-    else if (app.globalData.userInfo.IsShow>0) {
252
+    if (app.globalData.userInfo.IsShow>=0) {
264
       wx.navigateTo({
253
       wx.navigateTo({
265
         url: './userinfo',
254
         url: './userinfo',
266
       });
255
       });

+ 67 - 62
pages/main/index.wxml

@@ -1,5 +1,5 @@
1
 <view class="container FlexColumn" style='min-height:{{Height}}rpx;'>
1
 <view class="container FlexColumn" style='min-height:{{Height}}rpx;'>
2
-  
2
+
3
   <view class="panelTop FlexRow">
3
   <view class="panelTop FlexRow">
4
     <view class="Avatar FlexColumn">
4
     <view class="Avatar FlexColumn">
5
       <image src='../images/userface_default.png' class="AvatarImage" bindtap="gotoMemberCenter">
5
       <image src='../images/userface_default.png' class="AvatarImage" bindtap="gotoMemberCenter">
@@ -7,7 +7,7 @@
7
       <image src='{{AvatarUrl}}' class="AvatarImage1" bindtap="gotoMemberCenter">
7
       <image src='{{AvatarUrl}}' class="AvatarImage1" bindtap="gotoMemberCenter">
8
       </image>
8
       </image>
9
     </view>
9
     </view>
10
-    
10
+
11
     <view class="panelTop1 FlexColumn">
11
     <view class="panelTop1 FlexColumn">
12
       <view class="number" wx:if="{{!IsAccredit}}">-</view>
12
       <view class="number" wx:if="{{!IsAccredit}}">-</view>
13
       <view class="number" wx:if="{{IsAccredit}}">{{DayNumber}}</view>
13
       <view class="number" wx:if="{{IsAccredit}}">{{DayNumber}}</view>
@@ -30,8 +30,7 @@
30
   </view>
30
   </view>
31
   <view class="panelList FlexRow">
31
   <view class="panelList FlexRow">
32
     <view class="panelItem btn FlexColumn" wx:for="{{List}}" wx:key="*this">
32
     <view class="panelItem btn FlexColumn" wx:for="{{List}}" wx:key="*this">
33
-      <image  src='../images/{{item.ImageUrl}}' bindtap="goto" data-url="{{item.Url}}"
34
-      class="itemImg" />
33
+      <image src='../images/{{item.ImageUrl}}' bindtap="goto" data-url="{{item.Url}}" class="itemImg" />
35
     </view>
34
     </view>
36
     <view class="panelTool FlexColumn">
35
     <view class="panelTool FlexColumn">
37
       <view class="panelTool1">自测工具</view>
36
       <view class="panelTool1">自测工具</view>
@@ -50,77 +49,83 @@
50
     </view>
49
     </view>
51
 
50
 
52
     <image src='../images/png02016.png' class="png02016" />
51
     <image src='../images/png02016.png' class="png02016" />
53
-    <view class="panelOther FlexRow">
54
-      <view class="panelOther1">其它产品</view>
55
-      <image src='../images/home_triangle_up.png' class="home_triangle_up" />
56
-    </view>
57
-  </view>
58
-  <view class="panelProduct FlexColumn">
59
-    <view class="panelProduct10 panelProduct0 FlexColumn">
60
-      <view class="panelProduct1">全科练习</view>
61
-      <view class="panelProduct3 FlexRow" bindtap="showMiaoguo" >
62
-        <image src='../images/sofewareicon_mg.png' class="sofewareicon_mg" />
63
-        <view class="panelProduct31 FlexColumn">
64
-          <view class="panelProduct311">秒过</view>
65
-          <view class="panelProduct312">基础知识记忆工具</view>
66
-        </view>
52
+
53
+    <block wx:if="{{IsShow==1}}">
54
+      <view class="panelOther FlexRow">
55
+        <view class="panelOther1">其它产品</view>
56
+        <image src='../images/home_triangle_up.png' class="home_triangle_up" />
67
       </view>
57
       </view>
68
-    </view>
69
 
58
 
70
-    <view class="panelProduct1">单科练习</view>
71
-    <view class="panelProduct10 FlexRow" style="width:100%;">
72
-      <view class="panelProduct0 FlexColumn">
73
-        <view class="panelProduct2">数学</view>
74
-        <view class="panelProduct3 FlexRow" bindtap='switchProgram' data-appid='wxa5441bbf344692ba' >
75
-          <image src='../images/sofewareicon_ks.png' class="sofewareicon_mg" />
76
-          <view class="panelProduct31 FlexColumn">
77
-            <view class="panelProduct311">口算星球</view>
78
-            <view class="panelProduct312">好玩的口算敏捷练习</view>
79
-          </view>
80
-        </view>
81
-        <view class="panelProduct3 FlexRow" bindtap='switchProgram' data-appid='wx1fef080f74481cbd' >
82
-          <image src='../images/sofewareicon_jst.png' class="sofewareicon_mg" />
59
+    </block>
60
+  </view>
61
+
62
+  <block wx:if="{{IsShow==1}}">
63
+    <view class="panelProduct FlexColumn">
64
+      <view class="panelProduct10 panelProduct0 FlexColumn">
65
+        <view class="panelProduct1">全科练习</view>
66
+        <view class="panelProduct3 FlexRow" bindtap="showMiaoguo">
67
+          <image src='../images/sofewareicon_mg.png' class="sofewareicon_mg" />
83
           <view class="panelProduct31 FlexColumn">
68
           <view class="panelProduct31 FlexColumn">
84
-            <view class="panelProduct311">计算题打印</view>
85
-            <view class="panelProduct312">打印竖式横式计算题</view>
69
+            <view class="panelProduct311">秒过</view>
70
+            <view class="panelProduct312">基础知识记忆工具</view>
86
           </view>
71
           </view>
87
         </view>
72
         </view>
88
       </view>
73
       </view>
89
-      <view class="panelProduct0 FlexColumn">
90
-        <view class="panelProduct2">语文</view>
91
-        <view class="panelProduct3 FlexRow" bindtap='switchProgram' data-appid='wx331e8dd070f01d0e' >
92
-          <image src='../images/sofewareicon_py.png' class="sofewareicon_mg" />
93
-          <view class="panelProduct31 FlexColumn">
94
-            <view class="panelProduct311">汉语拼音</view>
95
-            <view class="panelProduct312">纯正发音练习</view>
74
+
75
+      <view class="panelProduct1">单科练习</view>
76
+      <view class="panelProduct10 FlexRow" style="width:100%;">
77
+        <view class="panelProduct0 FlexColumn">
78
+          <view class="panelProduct2">数学</view>
79
+          <view class="panelProduct3 FlexRow" bindtap='switchProgram' data-appid='wxa5441bbf344692ba'>
80
+            <image src='../images/sofewareicon_ks.png' class="sofewareicon_mg" />
81
+            <view class="panelProduct31 FlexColumn">
82
+              <view class="panelProduct311">口算星球</view>
83
+              <view class="panelProduct312">好玩的口算敏捷练习</view>
84
+            </view>
85
+          </view>
86
+          <view class="panelProduct3 FlexRow" bindtap='switchProgram' data-appid='wx1fef080f74481cbd'>
87
+            <image src='../images/sofewareicon_jst.png' class="sofewareicon_mg" />
88
+            <view class="panelProduct31 FlexColumn">
89
+              <view class="panelProduct311">计算题打印</view>
90
+              <view class="panelProduct312">打印竖式横式计算题</view>
91
+            </view>
96
           </view>
92
           </view>
97
         </view>
93
         </view>
98
-        <view class="panelProduct3 FlexRow" bindtap='switchProgram' data-appid='wx313a8f2c0741efe1' >
99
-          <image src='../images/sofewareicon_sz.png' class="sofewareicon_mg" />
100
-          <view class="panelProduct31 FlexColumn">
101
-            <view class="panelProduct311">识字</view>
102
-            <view class="panelProduct312">小学六年课本同步</view>
94
+        <view class="panelProduct0 FlexColumn">
95
+          <view class="panelProduct2">语文</view>
96
+          <view class="panelProduct3 FlexRow" bindtap='switchProgram' data-appid='wx331e8dd070f01d0e'>
97
+            <image src='../images/sofewareicon_py.png' class="sofewareicon_mg" />
98
+            <view class="panelProduct31 FlexColumn">
99
+              <view class="panelProduct311">汉语拼音</view>
100
+              <view class="panelProduct312">纯正发音练习</view>
101
+            </view>
102
+          </view>
103
+          <view class="panelProduct3 FlexRow" bindtap='switchProgram' data-appid='wx313a8f2c0741efe1'>
104
+            <image src='../images/sofewareicon_sz.png' class="sofewareicon_mg" />
105
+            <view class="panelProduct31 FlexColumn">
106
+              <view class="panelProduct311">识字</view>
107
+              <view class="panelProduct312">小学六年课本同步</view>
108
+            </view>
103
           </view>
109
           </view>
104
         </view>
110
         </view>
105
       </view>
111
       </view>
106
-    </view>
107
-    
108
-    <view style="width:100%;height:20rpx;"></view>
109
-    <view class="panelProduct10 panelProduct0 FlexColumn" bindtap='switchProgram' data-appid='wxb54a6d5aff836ee3' >
110
-      <view class="panelProduct1">英语</view>
111
-      <view class="panelProduct3 FlexRow">
112
-        <image src='../images/sofewareicon_pd.png' class="sofewareicon_mg" />
113
-        <view class="panelProduct31 FlexColumn">
114
-          <view class="panelProduct311">自然拼读</view>
115
-          <view class="panelProduct312">英语国家母语学习法</view>
112
+
113
+      <view style="width:100%;height:20rpx;"></view>
114
+      <view class="panelProduct10 panelProduct0 FlexColumn" bindtap='switchProgram' data-appid='wxb54a6d5aff836ee3'>
115
+        <view class="panelProduct1">英语</view>
116
+        <view class="panelProduct3 FlexRow">
117
+          <image src='../images/sofewareicon_pd.png' class="sofewareicon_mg" />
118
+          <view class="panelProduct31 FlexColumn">
119
+            <view class="panelProduct311">自然拼读</view>
120
+            <view class="panelProduct312">英语国家母语学习法</view>
121
+          </view>
116
         </view>
122
         </view>
117
       </view>
123
       </view>
124
+      <view style="width:100%;height:60rpx;"></view>
118
     </view>
125
     </view>
119
-    <view style="width:100%;height:60rpx;"></view>
120
-  </view>
121
-  
122
-  <image bindtap="showMiaoguo" src='../images/home_banner.png' class="home_banner" />
123
-          
126
+
127
+    <image bindtap="showMiaoguo" src='../images/home_banner.png' class="home_banner" />
128
+  </block>
124
 </view>
129
 </view>
125
 
130
 
126
 <view class="HelpInfo2 FlexColumn" style='height:{{Height}}rpx;' wx:if="{{IsMiaoguoAD2==1}}">
131
 <view class="HelpInfo2 FlexColumn" style='height:{{Height}}rpx;' wx:if="{{IsMiaoguoAD2==1}}">
@@ -156,7 +161,7 @@
156
 
161
 
157
 <view class="PanelMiaoguo FlexColumn" style='height:{{Height}}rpx;' wx:if="{{IsShowMiaoguo==1}}" catchtap="closeMiaoguo">
162
 <view class="PanelMiaoguo FlexColumn" style='height:{{Height}}rpx;' wx:if="{{IsShowMiaoguo==1}}" catchtap="closeMiaoguo">
158
   <view class="PanelMiaoguo1 FlexColumn">
163
   <view class="PanelMiaoguo1 FlexColumn">
159
-    <image src='../images/bm_sy_illus.png' class="bm_sy_illus"/>
164
+    <image src='../images/bm_sy_illus.png' class="bm_sy_illus" />
160
     <view class="Text1">该记的记不住</view>
165
     <view class="Text1">该记的记不住</view>
161
     <view class="Text2">用「秒过」</view>
166
     <view class="Text2">用「秒过」</view>
162
     <text class="Text3">帮助孩子记牢语数外基础知识的\n工具和练习方法</text>
167
     <text class="Text3">帮助孩子记牢语数外基础知识的\n工具和练习方法</text>

+ 1 - 0
pages/main/userinfo.js

@@ -16,6 +16,7 @@ Page({
16
       ProgramID:app.globalData.ProgramID,
16
       ProgramID:app.globalData.ProgramID,
17
       IsShow: app.globalData.userInfo.IsShow,
17
       IsShow: app.globalData.userInfo.IsShow,
18
       IsLocked: app.globalData.IsLocked,
18
       IsLocked: app.globalData.IsLocked,
19
+      IsIOS:app.globalData.IsIOS,
19
     });
20
     });
20
   },
21
   },
21
   goto:function(e){
22
   goto:function(e){

+ 2 - 1
pages/main/userinfo.wxml

@@ -19,7 +19,8 @@
19
   </view>
19
   </view>
20
   <view class='lineFooter'></view>
20
   <view class='lineFooter'></view>
21
 
21
 
22
-  <block wx:if="{{IsShow==1 && IsLocked==1}}">
22
+  <block wx:if="{{(IsShow==1 && IsLocked==1) || (IsShow<=0 && !IsIOS)}}">
23
+  
23
     <view class="panelTitle FlexRow">
24
     <view class="panelTitle FlexRow">
24
       <view class="panelTitle1">我的卡包</view>
25
       <view class="panelTitle1">我的卡包</view>
25
     </view>
26
     </view>