Commit 354976b2 authored by Alex朱枝文's avatar Alex朱枝文

解决进入支付结果页没关闭上一级页面

parent 74bfb143
......@@ -8616,7 +8616,7 @@
CODE_SIGN_ENTITLEMENTS = yinheReplayExt/yinheReplayExt.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEVELOPMENT_TEAM = RXHYW88XR7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = yinheReplayExt/Info.plist;
......@@ -8646,7 +8646,7 @@
CODE_SIGN_ENTITLEMENTS = yinheReplayExt/yinheReplayExt.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEVELOPMENT_TEAM = RXHYW88XR7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = yinheReplayExt/Info.plist;
......@@ -8676,7 +8676,7 @@
CODE_SIGN_ENTITLEMENTS = yinheReplayExt/yinheReplayExt.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEVELOPMENT_TEAM = RXHYW88XR7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = yinheReplayExt/Info.plist;
......@@ -8706,7 +8706,7 @@
CODE_SIGN_ENTITLEMENTS = yinheReplayExt/yinheReplayExt.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEVELOPMENT_TEAM = RXHYW88XR7;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = yinheReplayExt/Info.plist;
......@@ -8795,7 +8795,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxyTestEnv.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
......@@ -8944,7 +8944,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxy.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
......@@ -9155,7 +9155,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxyDebug.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
......@@ -9206,7 +9206,7 @@
CODE_SIGN_ENTITLEMENTS = galaxy/galaxy.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 2;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_TEAM = RXHYW88XR7;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
......
......@@ -20,10 +20,12 @@ class YHJsApi: NSObject {
extension YHJsApi {
// 37、查看是否安装了某个应用
@objc func isSomeAppInstalled(_ tag: String, handler: @escaping (String) -> Void) {
if let url = URL(string: tag), UIApplication.shared.canOpenURL(url) {
handler("1")
} else {
handler("0")
DispatchQueue.main.async {
if let url = URL(string: tag), UIApplication.shared.canOpenURL(url) {
handler("1")
} else {
handler("0")
}
}
}
......@@ -500,13 +502,21 @@ extension YHJsApi {
let isFullScreen: Int = jsonObject["isFullScreen"] as? Int ?? 1
let navTitle: String = jsonObject["navTitle"] as? String ?? ""
let hideNavigationTitleFlag: Int = jsonObject["hideNavigationTitleFlag"] as? Int ?? 0
let closeCurrentView: Int = jsonObject["closeCurrentView"] as? Int ?? 0
if isInformationUrl == 1 {
// 资讯详情
let vc = YHHomeWebViewController()
vc.id = id
vc.url = YHBaseUrlManager.shared.curH5URL() + "articleDetail.html" + "?id=\(id)"
self.delegate?.navigationController?.pushViewController(vc)
if let navigationController = UIViewController.current?.navigationController, closeCurrentView == 1, (navigationController.viewControllers.count) > 1 {
var viewControllers = navigationController.viewControllers
viewControllers.removeLast()
viewControllers.append(vc)
navigationController.setViewControllers(viewControllers, animated: true)
} else {
UIViewController.current?.navigationController?.pushViewController(vc)
}
} else {
// 普通界面
if !url.isEmpty {
......@@ -530,7 +540,14 @@ extension YHJsApi {
vc.isFullScreenFlag = isFullScreen == 1 ? true : false
vc.showNavigationTitleFlag = hideNavigationTitleFlag == 0 ? true : false
vc.navTitle = navTitle
self.delegate?.navigationController?.pushViewController(vc)
if let navigationController = UIViewController.current?.navigationController, closeCurrentView == 1, (navigationController.viewControllers.count) > 1 {
var viewControllers = navigationController.viewControllers
viewControllers.removeLast()
viewControllers.append(vc)
navigationController.setViewControllers(viewControllers, animated: true)
} else {
UIViewController.current?.navigationController?.pushViewController(vc)
}
}
}
} else {
......
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