Commit 48939923 authored by linxin's avatar linxin

解决iframe兼容

parent 39115620
Pipeline #4713 canceled with stages
...@@ -13,5 +13,5 @@ module.exports = merge(prodEnv, { ...@@ -13,5 +13,5 @@ module.exports = merge(prodEnv, {
filePath: '"http://180.104.121.66:8088/r/api/app/fileViewSvc?sysName=XCMG_DEV&apiName=file_view&"', filePath: '"http://180.104.121.66:8088/r/api/app/fileViewSvc?sysName=XCMG_DEV&apiName=file_view&"',
ocrPath: '"http://180.104.121.66:8088/r/api"', ocrPath: '"http://180.104.121.66:8088/r/api"',
appId: '"com.xcmg.app"', appId: '"com.xcmg.app"',
currentVersion: '"1.7.3"', currentVersion: '"1.7.6"',
}) })
...@@ -948,12 +948,20 @@ export default { ...@@ -948,12 +948,20 @@ export default {
) { ) {
let authUrl = await vm.getNpCertificationUrl() let authUrl = await vm.getNpCertificationUrl()
if (authUrl) { if (authUrl) {
const u = navigator.userAgent
const isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/)
if (isiOS) {
cordova.InAppBrowser.open(authUrl, '_blank', 'location=yes')
console.log('ios')
} else {
vm.$router.push({ vm.$router.push({
name: 'Certification', name: 'Certification',
params: { params: {
authUrl: authUrl, authUrl: authUrl,
}, },
}) })
console.log('android')
}
} else { } else {
// hlsPopup.showLongCenter('获取认证url失败') // hlsPopup.showLongCenter('获取认证url失败')
} }
......
<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no,width=device-width,viewport-fit=cover"><meta name=format-detection content="telephone=no"><meta name=format-detection content="email=no"><meta name=apple-mobile-web-app-capable content=yes><meta name=apple-mobile-web-app-status-bar-style content=black><script type=text/javascript src=./static/vuePlatform.js></script><script type=text/javascript src=./static/prototype.js></script><script type=text/javascript src=cordova.js></script><script type=text/javascript src="http://api.map.baidu.com/api?v=2.0&ak=Eoo0EtfjYCdAy7r8D19gZ0vMojdZpHqU"></script><title>徐工金服</title><link href=./static/css/app.066328e36fcb8234cf43603ff5b52b8e.css rel=stylesheet></head><body><div id=app-box></div><script type=text/javascript src=./static/js/manifest.5b23605dc2d9cfefc737.js></script><script type=text/javascript src=./static/js/vendor.64c4110c2ef75634c410.js></script><script type=text/javascript src=./static/js/app.aed9db43d8c5905b8c49.js></script></body></html> <!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no,width=device-width,viewport-fit=cover"><meta name=format-detection content="telephone=no"><meta name=format-detection content="email=no"><meta name=apple-mobile-web-app-capable content=yes><meta name=apple-mobile-web-app-status-bar-style content=black><script type=text/javascript src=./static/vuePlatform.js></script><script type=text/javascript src=./static/prototype.js></script><script type=text/javascript src=cordova.js></script><script type=text/javascript src="http://api.map.baidu.com/api?v=2.0&ak=Eoo0EtfjYCdAy7r8D19gZ0vMojdZpHqU"></script><title>徐工金服</title><link href=./static/css/app.bf12f36459a8557699346754da6efd18.css rel=stylesheet></head><body><div id=app-box></div><script type=text/javascript src=./static/js/manifest.5b23605dc2d9cfefc737.js></script><script type=text/javascript src=./static/js/vendor.64c4110c2ef75634c410.js></script><script type=text/javascript src=./static/js/app.dd5894f1024fda4ea85c.js></script></body></html>
\ No newline at end of file \ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment