|
@@ -3,6 +3,7 @@ var tid = '';
|
3
|
3
|
var returnUrl = '';
|
4
|
4
|
var cityInfo = '';
|
5
|
5
|
var retrievePwd = '';
|
|
6
|
+var appName = '';
|
6
|
7
|
var qs = parseQueryString(window.location.href);
|
7
|
8
|
|
8
|
9
|
var httpStr=location.href.substr(0,location.href.indexOf("?") + 1); //str得到?之前的字符串
|
|
@@ -11,7 +12,11 @@ $().ready(function() {
|
11
|
12
|
if (qs.returnUrl) {
|
12
|
13
|
returnUrl = qs.returnUrl;
|
13
|
14
|
}
|
14
|
|
-
|
|
15
|
+
|
|
16
|
+ if (qs.appName) {
|
|
17
|
+ appName = qs.appName;
|
|
18
|
+ }
|
|
19
|
+
|
15
|
20
|
if (qs.token) {
|
16
|
21
|
token = qs.token;
|
17
|
22
|
} else {
|
|
@@ -21,7 +26,9 @@ $().ready(function() {
|
21
|
26
|
if (qs.name && qs.code) {
|
22
|
27
|
$('.city-name').text(qs.name).attr('data-code', qs.code);
|
23
|
28
|
}
|
24
|
|
- httpStr += "returnUrl=" + returnUrl;
|
|
29
|
+ var agreementLink = $('.agreement-wrapper a');
|
|
30
|
+ agreementLink.attr('href', agreementLink.attr('href') + '?appName=' + appName);
|
|
31
|
+ httpStr += "returnUrl=" + returnUrl + "&appName=" + appName;
|
25
|
32
|
httpStr = encodeURIComponent(httpStr)
|
26
|
33
|
console.log(httpStr)
|
27
|
34
|
getLoginInfo();
|
|
@@ -67,7 +74,7 @@ function showDialog(type) {
|
67
|
74
|
$('.dialog-wrapper div').hide();
|
68
|
75
|
if (type === 'failed') {
|
69
|
76
|
$('.dialog-failed').show();
|
70
|
|
- $('.mask').addClass('bg-white').siblings().hide();
|
|
77
|
+ $('.mask').siblings().hide();
|
71
|
78
|
} else if (type === 'maintain') {
|
72
|
79
|
$('.dialog-maintain').show();
|
73
|
80
|
} else if (type === 'timeout') {
|
|
@@ -86,7 +93,6 @@ function showDialog(type) {
|
86
|
93
|
retrievePwd = item.URL.password;
|
87
|
94
|
// window.location.href=retrievePwd;
|
88
|
95
|
window.webkit.messageHandlers.OutPushMessageHandler.postMessage({'name':qs.name,'url':retrievePwd});
|
89
|
|
-
|
90
|
96
|
}else{
|
91
|
97
|
retrievePwd = item.URL.web;
|
92
|
98
|
// window.location.href=retrievePwd;
|
|
@@ -162,7 +168,20 @@ function initEvent() {
|
162
|
168
|
$('.alert-info').hide();
|
163
|
169
|
$('.loading-wrapper').hide();
|
164
|
170
|
})
|
165
|
|
-
|
|
171
|
+
|
|
172
|
+ //阻止冒泡
|
|
173
|
+ $(".dialog-wrapper").click(function (){
|
|
174
|
+ return false
|
|
175
|
+ })
|
|
176
|
+
|
|
177
|
+ //点击mask阴影
|
|
178
|
+ $(".mask").click(function() {
|
|
179
|
+ $('.mask').removeClass('bg-white').hide().siblings().show();
|
|
180
|
+ $('#tid').hide();
|
|
181
|
+ $('.alert-info').hide();
|
|
182
|
+ $('.loading-wrapper').hide();
|
|
183
|
+ })
|
|
184
|
+
|
166
|
185
|
// 解析协议checkBox选中/取消选中事件
|
167
|
186
|
$('.check').click(function() {
|
168
|
187
|
var currentItem = $(this);
|