|
|
@@ -6,6 +6,7 @@ import 'package:flutter_alibc/alibc_const_key.dart'; |
|
|
|
import 'package:flutter_alibc/flutter_alibc.dart'; |
|
|
|
import 'package:jdsdk/jdsdk.dart'; |
|
|
|
import 'package:provider/provider.dart'; |
|
|
|
import 'package:url_launcher/url_launcher.dart'; |
|
|
|
import 'package:zhiying_comm/pages/login_page/account/login_account_page.dart'; |
|
|
|
import 'package:zhiying_comm/pages/login_page/login_page.dart'; |
|
|
|
import 'package:zhiying_comm/util/dialog/loading/loading.dart'; |
|
|
@@ -48,7 +49,7 @@ class RouterUtil { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// TODO webView 临时代码,IOS添加原生WebView需要改动这里 |
|
|
|
|
|
|
|
if (skipModel?.skipIdentifier == 'pub.flutter.url') { |
|
|
|
if (skipModel?.url?.contains("sourceType=jd") ?? false) { |
|
|
|
Loading.show(context); |
|
|
@@ -57,10 +58,11 @@ class RouterUtil { |
|
|
|
var detailUrl = responds?.realUri?.toString(); |
|
|
|
Logger.debug(detailUrl ?? ""); |
|
|
|
Loading.dismiss(); |
|
|
|
Jdsdk.openUrl(url: detailUrl); |
|
|
|
return; |
|
|
|
if (await canLaunch(detailUrl)) { |
|
|
|
Jdsdk.openUrl(url: detailUrl); |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
RouterUtil.openWebview(skipModel?.url, context); |
|
|
|
return; |
|
|
|
} |
|
|
|