|
@ -237,8 +237,6 @@ class HomeViewController: UIViewController, UICollectionViewDelegateFlowLayout { |
|
|
presenter?.showPennyTest() |
|
|
presenter?.showPennyTest() |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
private func update() { |
|
|
|
|
|
let platform = self.user?.platforms ?? [] |
|
|
|
|
|
guard let ios = platform.filter({ $0.os ?? "" == "IOS"}).first else {return} |
|
|
guard let ios = platform.filter({ $0.os ?? "" == "IOS"}).first else {return} |
|
|
|
|
|
|
|
|
let critical = ios.critical ?? "N" |
|
|
let critical = ios.critical ?? "N" |
|
@ -777,7 +775,7 @@ extension HomeViewController { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
private func checkKFTCToken() { |
|
|
private func checkKFTCToken() { |
|
|
if !isShowTokenRenewAlert { |
|
|
|
|
|
|
|
|
if !UserDefaults.standard.bool(forKey: AppConstants.isOpenedTokenRenwalAlert) { |
|
|
// TODO: Show Alert for token refresh (navigation push) |
|
|
// TODO: Show Alert for token refresh (navigation push) |
|
|
guard |
|
|
guard |
|
|
let remind = UserDefaults.standard.string(forKey: UserKeys.remindKFTCTokenDay), |
|
|
let remind = UserDefaults.standard.string(forKey: UserKeys.remindKFTCTokenDay), |
|
@ -798,11 +796,11 @@ extension HomeViewController { |
|
|
cancelTitle: "later_text".localized(), |
|
|
cancelTitle: "later_text".localized(), |
|
|
okAction: { |
|
|
okAction: { |
|
|
AutoDebitWireframe().pushMainView(on: self) |
|
|
AutoDebitWireframe().pushMainView(on: self) |
|
|
self.isShowTokenRenewAlert = true |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
UserDefaults.standard.set(true, forKey: AppConstants.isOpenedTokenRenwalAlert) |
|
|
|
|
|
}, |
|
|
cancelAction : { |
|
|
cancelAction : { |
|
|
self.isShowTokenRenewAlert = true |
|
|
|
|
|
self.popUpNotification() |
|
|
self.popUpNotification() |
|
|
|
|
|
UserDefaults.standard.set(true, forKey: AppConstants.isOpenedTokenRenwalAlert) |
|
|
} |
|
|
} |
|
|
) |
|
|
) |
|
|
} else { |
|
|
} else { |
|
@ -812,8 +810,6 @@ extension HomeViewController { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
private func popUpNotification() { |
|
|
private func popUpNotification() { |
|
|
self.isShowTokenRenewAlert = true |
|
|
|
|
|
|
|
|
|
|
|
// FIXME: Temporary expire date |
|
|
// FIXME: Temporary expire date |
|
|
let dateformat = DateFormatter() |
|
|
let dateformat = DateFormatter() |
|
|
dateformat.dateFormat = "yyyy-MM-dd" |
|
|
dateformat.dateFormat = "yyyy-MM-dd" |
|
|