h5
Showing
2 changed files
with
6 additions
and
5 deletions
| ... | @@ -90,10 +90,6 @@ AppClient.prototype.getGPS = function (callbackName, callback, jsonStr) { | ... | @@ -90,10 +90,6 @@ AppClient.prototype.getGPS = function (callbackName, callback, jsonStr) { |
| 90 | 90 | ||
| 91 | 91 | ||
| 92 | if(isAndroid || isiOS) { | 92 | if(isAndroid || isiOS) { |
| 93 | layer.open({ | ||
| 94 | content: "isAndroid"+ isAndroid+'-' +"isiOS"+ isiOS, | ||
| 95 | time: 2 | ||
| 96 | }) | ||
| 97 | function setupWebViewJavascriptBridge(callback) { | 93 | function setupWebViewJavascriptBridge(callback) { |
| 98 | if (window.WebViewJavascriptBridge) { return callback(WebViewJavascriptBridge); } | 94 | if (window.WebViewJavascriptBridge) { return callback(WebViewJavascriptBridge); } |
| 99 | if (window.WVJBCallbacks) { return window.WVJBCallbacks.push(callback); } | 95 | if (window.WVJBCallbacks) { return window.WVJBCallbacks.push(callback); } |
| ... | @@ -105,7 +101,7 @@ if(isAndroid || isiOS) { | ... | @@ -105,7 +101,7 @@ if(isAndroid || isiOS) { |
| 105 | setTimeout(function() { document.documentElement.removeChild(WVJBIframe) }, 0) | 101 | setTimeout(function() { document.documentElement.removeChild(WVJBIframe) }, 0) |
| 106 | } | 102 | } |
| 107 | setupWebViewJavascriptBridge(function(bridge) { | 103 | setupWebViewJavascriptBridge(function(bridge) { |
| 108 | appClient = new AppClient(bridge, false); | 104 | appClient = new AppClient(bridge, isAndroid); |
| 109 | // 此处可以调用一些init的方法 | 105 | // 此处可以调用一些init的方法 |
| 110 | }); | 106 | }); |
| 111 | } else { | 107 | } else { | ... | ... |
| ... | @@ -158,6 +158,11 @@ angular.module('myApp') | ... | @@ -158,6 +158,11 @@ angular.module('myApp') |
| 158 | // return; | 158 | // return; |
| 159 | // } | 159 | // } |
| 160 | $rootScope.openScan = false; | 160 | $rootScope.openScan = false; |
| 161 | |||
| 162 | layer.open({ | ||
| 163 | content: appClient, | ||
| 164 | time: 5 | ||
| 165 | }) | ||
| 161 | if(appClient){ | 166 | if(appClient){ |
| 162 | appClient.appObj.registerHandler('postERCode', function(data, responseCallback) { | 167 | appClient.appObj.registerHandler('postERCode', function(data, responseCallback) { |
| 163 | layer.open({ | 168 | layer.open({ | ... | ... |
-
Please register or sign in to post a comment