Commit a87f9b3f authored by pete谢兆麟's avatar pete谢兆麟

国家

parent 8e312416
......@@ -14,11 +14,9 @@ class YHSelectCountryViewModel: NSObject {
}
func requestCountry(_ key: String, callBackBlock:@escaping (_ success: [YHCountryMessage?]?, _ error:YHErrorModel?)->()) {
let strUrl = YHBaseUrlManager.shared.curURL() + YHAllApiName.OrderInformation.countryInformation
// "frontend/country?keyword=\(key)"
let params: [String : Any] = ["keyword": key]
let strUrl = YHBaseUrlManager.shared.curURL() + YHAllApiName.OrderInformation.countryInformation + "?keyword = \(key)"
YHNetRequest.getRequest(url: strUrl, params: params) { [weak self] json, code in
YHNetRequest.getRequest(url: strUrl) { [weak self] json, code in
//1. json字符串 转 对象
guard let self = self else { return }
guard let model = NetBaseModel.deserialize(dict: json) else {
......
......@@ -155,50 +155,46 @@ extension YHMyViewController : UITableViewDelegate, UITableViewDataSource {
}
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
let vc = YHMainApplicantInformationViewController()
vc.orderId = 134438
navigationController?.pushViewController(vc)
if (indexPath.row >= items.count) { return }
// if (indexPath.row >= items.count) { return }
//
// if !checkLogin() {
// let vc = UINavigationController(rootVC: YHPhoneLoginViewController())
// vc.modalPresentationStyle = .custom
// self.navigationController?.present(vc, animated: true)
// } else {
// YHHUD.flash(message: "已登录: 功能完善中...")
// }
// return //for test hjl
//
// let item: PersonalModuleItem = items[indexPath.row];
//
// if item.title == "关于我们" {
// let vc = YHAboutUsViewController()
// self.navigationController?.pushViewController(vc)
//
// } else if item.title == "我的设置" {
//
// let account = "duyu"
// let token = "123456"
// let vc = ConversationController()
if !checkLogin() {
let vc = UINavigationController(rootVC: YHPhoneLoginViewController())
vc.modalPresentationStyle = .custom
self.navigationController?.present(vc, animated: true)
} else {
YHHUD.flash(message: "已登录: 功能完善中...")
}
return //for test hjl
let item: PersonalModuleItem = items[indexPath.row];
if item.title == "关于我们" {
let vc = YHAboutUsViewController()
self.navigationController?.pushViewController(vc)
} else if item.title == "我的设置" {
let account = "duyu"
let token = "123456"
let vc = ConversationController()
self.navigationController?.pushViewController(vc)
IMKitClient.instance.loginIM(account, token) { error in
if let err = error {
print("login error in app : ", err.localizedDescription)
}else {
let _ = NEAtMessageManager.instance
}
}
} else {
// let vc = YHLoginViewController()
// self.navigationController?.pushViewController(vc)
//
// IMKitClient.instance.loginIM(account, token) { error in
// if let err = error {
// print("login error in app : ", err.localizedDescription)
// }else {
// let _ = NEAtMessageManager.instance
//
// }
// }
//
//
//
// } else {
//// let vc = YHLoginViewController()
//// self.navigationController?.pushViewController(vc)
// }
}
}
}
......
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