feat(drone-dock): 新增独立套餐收款页并接入收款接口
This commit is contained in:
@@ -6,6 +6,17 @@ import UIKit
|
||||
enum DroneDockPreview {
|
||||
/// 启动参数存在时返回预览导航,正常冷启动继续使用原业务根页面。
|
||||
static func navigationController(arguments: [String]) -> UINavigationController? {
|
||||
if (arguments.contains("--dock-payment-live") || arguments.contains("--dock-receipts-live")), AppStore.shared.session.isLoggedIn {
|
||||
let home = DroneDockHomeViewController()
|
||||
let payment = DroneDockPaymentViewController()
|
||||
let navigation = UINavigationController()
|
||||
if arguments.contains("--dock-receipts-live") {
|
||||
navigation.setViewControllers([home, payment, payment.makeReceiptsController()], animated: false)
|
||||
} else {
|
||||
navigation.setViewControllers([home, payment], animated: false)
|
||||
}
|
||||
return navigation
|
||||
}
|
||||
if arguments.contains("--dock-home-live"), AppStore.shared.session.isLoggedIn {
|
||||
return UINavigationController(rootViewController: DroneDockHomeViewController())
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user