| | |
| | | btn_moreMatchStore.isHidden = (label_storeNames.text?.count ?? 0) < 50 |
| | | |
| | | label_title.text = activityDetailModel.name |
| | | label_joinCondition.text = activityDetailModel.registerCondition.strTitle |
| | | label_joinCondition.text = activityDetailModel.registerCondition.strTitle + "参与" |
| | | label_address.text = activityDetailModel.address |
| | | label_duetime.text = activityDetailModel.registerEndTime |
| | | label_starttime.text = activityDetailModel.startTime |
| | |
| | | weakSelf.payment(type: type) |
| | | } |
| | | } |
| | | } |
| | | }else{ |
| | | NotificationCenter.default.post(name: ChooseHomeStore_Noti, object: nil) |
| | | } |
| | | } |
| | | } |
| | | |
| | |
| | | let vc = PaymentResultVC(result: .success, objType: .activityApply) |
| | | vc.modalPresentationStyle = .fullScreen |
| | | weakSelf.present(vc, animated: true) |
| | | weakSelf.btn_enroll.setTitle("已报名", for: .normal) |
| | | weakSelf.btn_enroll.backgroundColor = UIColor.gray.withAlphaComponent(0.5) |
| | | // weakSelf.btn_enroll.setTitle("已报名", for: .normal) |
| | | // weakSelf.btn_enroll.backgroundColor = UIColor.gray.withAlphaComponent(0.5) |
| | | case .cancel: |
| | | alert(msg: "已取消") |
| | | case .failure(let error): |
| | |
| | | let vc = PaymentResultVC(result: .success, objType: .activityApply) |
| | | vc.modalPresentationStyle = .fullScreen |
| | | weakSelf.present(vc, animated: true) |
| | | weakSelf.btn_enroll.setTitle("已报名", for: .normal) |
| | | weakSelf.btn_enroll.backgroundColor = UIColor.gray.withAlphaComponent(0.5) |
| | | // weakSelf.btn_enroll.setTitle("已报名", for: .normal) |
| | | // weakSelf.btn_enroll.backgroundColor = UIColor.gray.withAlphaComponent(0.5) |
| | | default:break |
| | | } |
| | | } |
| | | },onError: {[weak self] error in |
| | | guard let weakSelf = self else { return } |
| | | if let er = error as? NetworkRequest.NetRequestError{ |
| | | switch er { |
| | | case .Other(_,let string): |
| | | let vc = PaymentResultVC(result: .fail(string), objType: .yard,handleVC: nil) |
| | | vc.modalPresentationStyle = .fullScreen |
| | | weakSelf.present(vc, animated: true) |
| | | default: |
| | | let vc = PaymentResultVC(result: .fail("支付失败"), objType: .yard,handleVC: nil) |
| | | vc.modalPresentationStyle = .fullScreen |
| | | weakSelf.present(vc, animated: true) |
| | | } |
| | | } |
| | | }).disposed(by: disposeBag) |
| | | } |
| | | } |