Browse Source

added api

pull/1/head
gme_2 6 years ago
parent
commit
916fc97fe6
  1. 21
      GMERemittance/Module/Resend/Application Logic/Service/ResendServiceType.swift
  2. 16
      GMERemittance/Module/Resend/User Interface/View/ResendViewController.swift

21
GMERemittance/Module/Resend/Application Logic/Service/ResendServiceType.swift

@ -7,7 +7,28 @@
// //
import Foundation import Foundation
import Alamofire
protocol ResendServiceType: class { protocol ResendServiceType: class {
} }
protocol FetchResendTransactionList: ApiServiceType {
func fetch()
}
extension FetchResendTransactionList {
func fetch() {
// http://localhost:9500/api/v1/resend/list
let url = baseUrl + "v1/resend/list"
auth.request(method: .post, url: url, params: nil, success: { (response: SuccessMessageContainer) in
print(response)
}) { (error) in
print(error.localizedDescription)
}
}
}

16
GMERemittance/Module/Resend/User Interface/View/ResendViewController.swift

@ -33,6 +33,17 @@ class ResendViewController: UIViewController {
self.setup() self.setup()
} }
override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
self.navigationItem.title = "Resend"
self.fetch()
}
override func viewWillDisappear(_ animated: Bool) {
super.viewWillDisappear(animated)
self.navigationItem.title = ""
}
// MARK: IBActions // MARK: IBActions
// MARK: Other Functions // MARK: Other Functions
@ -116,3 +127,8 @@ extension ResendViewController {
} }
} }
extension ResendViewController: FetchResendTransactionList {
}
Loading…
Cancel
Save