From aba8fd69495e761782d4204c592f20b8e1d43097 Mon Sep 17 00:00:00 2001 From: InKwon James Kim Date: Fri, 22 Nov 2019 15:24:05 +0900 Subject: [PATCH] add inbound delete api --- GME Remit/APIs/Router/APIRouter.swift | 6 ++++++ .../Login/User Interface/View/Login.storyboard | 11 ++++------- .../Interactor/InboundAccountsInteractor.swift | 12 ++++++++++++ .../Interactor/InboundAccountsInteractorIO.swift | 1 + .../Service/InboundAccountsService.swift | 8 ++++++++ .../Service/InboundAccountsServiceType.swift | 6 ++++++ .../Presenter/InboundAccountsPresenter.swift | 6 ++++++ .../View/InboundAccountsViewController.swift | 9 ++++++--- 8 files changed, 49 insertions(+), 10 deletions(-) diff --git a/GME Remit/APIs/Router/APIRouter.swift b/GME Remit/APIs/Router/APIRouter.swift index 089f5026..3cab930f 100644 --- a/GME Remit/APIs/Router/APIRouter.swift +++ b/GME Remit/APIs/Router/APIRouter.swift @@ -74,6 +74,7 @@ enum APIRouter { case penneyTestCertified(model: PenneyTestVerify) case fetchInboundAccounts case fetchInboundTransactionHistory(from: String, to: String) + case deleteInboundAccount(model: InboundAccount) } // MARK: - Request @@ -482,6 +483,9 @@ extension APIRouter { case .fetchInboundTransactionHistory: let senderId = GMEDB.shared.user.string(.senderId) ?? "" return "\(baseUrl)/inbound/mobile/tranHistory/\(senderId)" + case .deleteInboundAccount(let model): + let senderId = GMEDB.shared.user.string(.senderId) ?? "" + return "\(baseUrl)/inbound/mobile/deleteInboundAccount/\(senderId)/\(model.accountNo ?? "")" } } } @@ -560,6 +564,8 @@ extension APIRouter { return .post case .fetchInboundTransactionHistory: return .post + case .deleteInboundAccount: + return .post } } diff --git a/GME Remit/Modules/Login/User Interface/View/Login.storyboard b/GME Remit/Modules/Login/User Interface/View/Login.storyboard index 570f77b8..65c18d51 100644 --- a/GME Remit/Modules/Login/User Interface/View/Login.storyboard +++ b/GME Remit/Modules/Login/User Interface/View/Login.storyboard @@ -77,16 +77,16 @@ - +