|
|
@@ -130,7 +130,7 @@
|
|
130
|
130
|
success: function(data) {
|
|
131
|
131
|
/*验证请求*/
|
|
132
|
132
|
if(data.state == "success") {
|
|
133
|
|
-
|
|
|
133
|
+
|
|
134
|
134
|
$.cookie("token", data.data.token, {
|
|
135
|
135
|
expires: 7
|
|
136
|
136
|
});
|
|
|
@@ -140,7 +140,21 @@
|
|
140
|
140
|
$.cookie("u_code", User, {
|
|
141
|
141
|
expires: 7
|
|
142
|
142
|
});
|
|
143
|
|
- window.location.href = "index.html";
|
|
|
143
|
+
|
|
|
144
|
+ var expireDate = data.data.date.split(' ')[0];
|
|
|
145
|
+ var expireDay = data.data.days;
|
|
|
146
|
+ var expireText = '<span style="color:#f00;">软件到期时间:' + expireDate + ',还剩' + expireDay +'天,请联系软件厂家</span>'
|
|
|
147
|
+ if (expireDay * 1 > 0) {
|
|
|
148
|
+ layer.confirm(expireText, {
|
|
|
149
|
+ btn: ['确定'] //按钮
|
|
|
150
|
+ }, function () {
|
|
|
151
|
+ window.location.href = "index.html";
|
|
|
152
|
+ })
|
|
|
153
|
+ }
|
|
|
154
|
+ else {
|
|
|
155
|
+ window.location.href = "index.html";
|
|
|
156
|
+ }
|
|
|
157
|
+
|
|
144
|
158
|
} else {
|
|
145
|
159
|
//alert("登录失败");
|
|
146
|
160
|
$("#user").val('');
|