Commit 9ee7d7a3 authored by David黄金龙's avatar David黄金龙

我的方案跳转

parent c54f30bc
......@@ -55,13 +55,9 @@ extension YHMineSchemeViewController: UITableViewDelegate, UITableViewDataSource
func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
if indexPath.row == 0 {
return 199
}
if indexPath.row == 1 {
} else if indexPath.row == 1 {
return 251
}
if indexPath.row == 2 {
} else if indexPath.row == 2 {
return 190
}
return 0
......
......@@ -171,7 +171,7 @@ class YHSchemeTableHeadView: UIView {
button.setTitleColor(UIColor(hex:0xd48638), for: .normal)
button.layer.cornerRadius = kCornerRadius4
button.clipsToBounds = true
// button.addTarget(self, action: #selector(goNext), for: .touchUpInside)
button.addTarget(self, action: #selector(goNext), for: .touchUpInside)
return button
}()
addSubview(titleButton)
......@@ -230,4 +230,9 @@ class YHSchemeTableHeadView: UIView {
}
}
}
@objc func goNext() {
UIViewController.current?.navigationController?.pushViewController(YHScoreDetailViewController())
}
}
......@@ -112,7 +112,7 @@ class YHSchemeTableViewCell: UITableViewCell {
button.setTitleColor(UIColor(hex:0xd48638), for: .normal)
button.layer.cornerRadius = kCornerRadius4
button.clipsToBounds = true
// button.addTarget(self, action: #selector(goNext), for: .touchUpInside)
button.addTarget(self, action: #selector(goNext), for: .touchUpInside)
return button
}()
centerView.addSubview(titleButton)
......@@ -165,4 +165,16 @@ class YHSchemeTableViewCell: UITableViewCell {
mainMessageLabel.attributedText = newString
subMessageLabel.text = model.subMessage
}
@objc func goNext() {
if let title = titleButton.titleLabel?.text {
if title.contains("资料清单") {
UIViewController.current?.navigationController?.pushViewController(YHFileListViewController())
} else if title.contains("文书写作") {
UIViewController.current?.navigationController?.pushViewController(YHMyDocumentsListViewController())
}
}
}
}
......@@ -82,15 +82,18 @@ extension YHScoreDetailViewController {
private func loadData() {
guard let orderId = orderId else { return}
let param = ["order_id":orderId]
serviceCenterMainReqVM.getMyScoreDetail(params: param) { success, error in
if success == true {
} else {
YHHUD.flash(message: error?.errorMsg ?? "发生错误,请重试")
if let orderID = UserDefaults.standard.value(forKey: "orderIdForPreview") {
let param = ["order_id":orderID]
serviceCenterMainReqVM.getMyScoreDetail(params: param) { success, error in
if success == true {
} else {
YHHUD.flash(message: error?.errorMsg ?? "发生错误,请重试")
}
self.homeTableView.reloadData()
}
self.homeTableView.reloadData()
} else {
YHHUD.flash(message: "订单号不存在")
}
}
......
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