| | |
| | | CODE_SIGN_ENTITLEMENTS = WanPai/WanPaiDebug.entitlements; |
| | | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; |
| | | CODE_SIGN_STYLE = Manual; |
| | | CURRENT_PROJECT_VERSION = 12; |
| | | CURRENT_PROJECT_VERSION = 13; |
| | | DEVELOPMENT_TEAM = ""; |
| | | "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 2MWV8K39DV; |
| | | FRAMEWORK_SEARCH_PATHS = ( |
| | |
| | | "$(inherited)", |
| | | "$(PROJECT_DIR)/WanPai/YYPaymentManager/WeChatPay", |
| | | ); |
| | | MARKETING_VERSION = 2.0.2; |
| | | MARKETING_VERSION = 2.0.3; |
| | | OTHER_LDFLAGS = ( |
| | | "$(inherited)", |
| | | "-ObjC", |
| | |
| | | CODE_SIGN_ENTITLEMENTS = WanPai/WanPaiRelease.entitlements; |
| | | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; |
| | | CODE_SIGN_STYLE = Manual; |
| | | CURRENT_PROJECT_VERSION = 12; |
| | | CURRENT_PROJECT_VERSION = 13; |
| | | DEVELOPMENT_TEAM = ""; |
| | | "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 2MWV8K39DV; |
| | | FRAMEWORK_SEARCH_PATHS = ( |
| | |
| | | "$(inherited)", |
| | | "$(PROJECT_DIR)/WanPai/YYPaymentManager/WeChatPay", |
| | | ); |
| | | MARKETING_VERSION = 2.0.2; |
| | | MARKETING_VERSION = 2.0.3; |
| | | OTHER_LDFLAGS = ( |
| | | "$(inherited)", |
| | | "-ObjC", |
| | |
| | | self.navigationController?.popViewController() |
| | | } |
| | | } |
| | | |
| | | |
| | | // if(!checkCameraAuth()){ |
| | | // |
| | | // let authStatus = AVCaptureDevice.authorizationStatus(for: AVMediaType.video) |
| | | // if authStatus == AVAuthorizationStatus.notDetermined { |
| | | // AVCaptureDevice.requestAccess(for: AVMediaType.video) {[weak self] (granted) in |
| | | // if granted{ |
| | | // self?.setupCaptureSession() |
| | | // self?.addSubviews() |
| | | // self?.scanTimer = Timer.scheduledTimer(timeInterval: 3.0, target: self, selector: #selector(startAnimation), userInfo: nil, repeats: true) |
| | | // } |
| | | // } |
| | | // } else if authStatus == AVAuthorizationStatus.restricted || authStatus == AVAuthorizationStatus.denied { |
| | | // let alertController = UIAlertController(title: nil,message: "请在iphone的“设置-隐私-相机”选项中,允许应用访问你的相机", preferredStyle: .alert) |
| | | // let cancelAction = UIAlertAction(title: "取消", style: .cancel, handler: { action in |
| | | // self.navigationController?.popViewController(animated: true) |
| | | // }) |
| | | // |
| | | // let okAction = UIAlertAction(title: "前往", style: .default, handler: {action in |
| | | // let settingUrl = NSURL(string: UIApplication.openSettingsURLString)! |
| | | // if UIApplication.shared.canOpenURL(settingUrl as URL){ |
| | | // if #available(iOS 10.0, *) { |
| | | // UIApplication.shared.open(settingUrl as URL, options: [:], completionHandler: nil) |
| | | // } else { |
| | | // UIApplication.shared.openURL(settingUrl as URL) |
| | | // } |
| | | // } |
| | | // }) |
| | | // |
| | | // alertController.addAction(cancelAction) |
| | | // alertController.addAction(okAction) |
| | | // self.present(alertController, animated: true, completion: nil) |
| | | // } else { |
| | | // |
| | | // } |
| | | // |
| | | // }else{ |
| | | // setupCaptureSession() |
| | | // addSubviews() |
| | | // scanTimer = Timer.scheduledTimer(timeInterval: 3.0, target: self, selector: #selector(startAnimation), userInfo: nil, repeats: true) |
| | | // } |
| | | } |
| | | |
| | | private func limitSuccess(){ |
| | |
| | | |
| | | func addSubviews() { |
| | | let _: CGFloat = (UIScreen.main.bounds.size.width - borderWidth) * 0.5 |
| | | |
| | | // |
| | | |
| | | // let coverImageView = UIImageView(frame: CGRect(x: 0, y: 64, width: UIScreen.main.bounds.size.width, height: UIScreen.main.bounds.size.height - 64)) |
| | | // coverImageView.backgroundColor = UIColor.clear |
| | | // coverImageView.image = self.getCoverView(left: leftMargin, top: topMargin) |
| | | // view.addSubview(coverImageView) |
| | | |
| | | |
| | | |
| | | //扫描边框 |
| | | borderView!.frame = CGRect.init(x: (UIScreen.main.bounds.size.width-(self.view.center.x+30))/2, y: (UIScreen.main.bounds.size.height-(self.view.center.x + 30))/2, width: self.view.center.x + 30, height: self.view.center.x + 30) |
| | |
| | | self?.push(vc: vc) |
| | | } |
| | | } |
| | | case .wechat:break |
| | | case .wechat: |
| | | let req = YYWeChatPayRequest(partnerId: m.partnerid, prepayId: m.prepayid, package: m.package, nonceStr: m.noncestr, timeStamp: m.timestamp, sign: m.sign) |
| | | YYPaymentManager.shared.sendPaymentRequest(req) { result in |
| | | switch result { |
| | | case .success: |
| | | let vc = PaymentResultVC(result: .success, objType: .activityApply) |
| | | self?.push(vc: vc) |
| | | case .cancel: |
| | | alert(msg: "已取消") |
| | | case .failure(_): |
| | | let vc = PaymentResultVC(result: .fail("支付失败",0), objType: .activityApply) |
| | | self?.push(vc: vc) |
| | | } |
| | | } |
| | | case .coin,.free: |
| | | let vc = PaymentResultVC(result: .success, objType: .activityApply) |
| | | self?.push(vc: vc) |
| | |
| | | studentModel.phone = tf_phone.text! |
| | | studentModel.idCard = tf_idCard.text! |
| | | studentModel.name = tf_name.text! |
| | | studentModel.birthday = tf_birthday.text! |
| | | |
| | | if profileImg != nil{ |
| | | showHUD("正在上传头像") |
| | |
| | | guard let weakSelf = self else { return } |
| | | PaymentView.show(enumType:.game,money: (ali: weakSelf.gameListModel.cash, wx: weakSelf.gameListModel.cash, coin: weakSelf.gameListModel.playCoin, course: nil,integral:weakSelf.gameListModel.integral)) { [weak self] payType in |
| | | guard let weakSelf = self else { return } |
| | | Services.payGame(configId: weakSelf.gameListModel.id, gameId: weakSelf.gameListModel.gameId, spaceId: weakSelf.storeId, sutuId: weakSelf.sutuId, type: payType,gameType: weakSelf.gameListModel.gameType).subscribe(onNext: {data in |
| | | Services.payGame(configId: weakSelf.gameListModel.id, gameId: weakSelf.gameListModel.gameId, spaceId: weakSelf.spaceId, sutuId: weakSelf.sutuId, type: payType,gameType: weakSelf.gameListModel.gameType).subscribe(onNext: {data in |
| | | if let m = data.data{ |
| | | |
| | | if m.isStaff{ |
| | |
| | | } |
| | | |
| | | @IBAction func scanAction(_ sender: UIButton) { |
| | | |
| | | |
| | | |
| | | if let model = QRCodeModel.deserialize(from: "{\"scan_type\": 1000, \"space_id\": 27, \"sutu_id\": 1036}"){ |
| | | if model.scan_type == .games{ |
| | | let gamesListVC = GamesListVC(model: model) |
| | | self.push(vc: gamesListVC) |
| | | }else if model.scan_type == .yard{ |
| | | let vc = YardDetailVC(id: model.id!) |
| | | self.push(vc: vc) |
| | | }else if model.scan_type == .course{ |
| | | let vc = CourseDetailVC(id: model.id!) |
| | | self.push(vc: vc) |
| | | } |
| | | }else{ |
| | | alertError(msg: "识别失败") |
| | | } |
| | | |
| | | return |
| | | |
| | | |
| | | let codeVC = CommonScanQRCodeVC {[weak self] text, status in |
| | | if status{ |
| | | if let model = QRCodeModel.deserialize(from: text){ |
| | |
| | | switch type{ |
| | | case .YMD: |
| | | let year = years[pickerView.selectedRow(inComponent: 0)] |
| | | let month = months[pickerView.selectedRow(inComponent: 1)] |
| | | var month = months[pickerView.selectedRow(inComponent: 1)] |
| | | |
| | | if year == Date().jq_nowYear(){ |
| | | month = Date().jq_nowMonth() - pickerView.selectedRow(inComponent: 1) |
| | | } |
| | | if year == Date().jq_nowYear() && month == Date().jq_nowMonth(){ |
| | | return Date().jq_nowDay() |
| | | }else{ |
| | |
| | | if component == 1{ |
| | | switch type{ |
| | | case .YM,.YMD: |
| | | let nowMonth = Date().jq_nowMonth() |
| | | if pickerView.selectedRow(inComponent: 0) == 0{ |
| | | return "\(11 - Date().jq_nowMonth() - row - 1)月" |
| | | return "\(nowMonth - row)月" |
| | | } |
| | | return "\(months[row])月" |
| | | case .HHmm:return String(format: "%02ld分", minutes[row]) |
| | |
| | | import RxSwift |
| | | import RxRelay |
| | | import RxDataSources |
| | | import SnapKit |
| | | |
| | | let WorldCupRefresh_Noti = Notification.Name.init("WorldCupRefresh_Noti") |
| | | |
| | |
| | | import UIKit |
| | | import RxSwift |
| | | import RxCocoa |
| | | import SnapKit |
| | | |
| | | class WorldCupRecordViewModel:RefreshInnerModel<WorldCupMatchRecordDataModel>{ |
| | | |
| | |
| | | import UIKit |
| | | import RxRelay |
| | | import RxSwift |
| | | import SnapKit |
| | | |
| | | class RecordsViewModel:RefreshModel<RecordsModel>{ |
| | | let goodsType = BehaviorRelay<ExchangeType?>(value: nil) |
| | |
| | | YYPaymentManager.shared.sendPaymentRequest(YYAlipayRequest(orderString: m.orderString)) { result in |
| | | switch result { |
| | | case .success: |
| | | self?.getData() |
| | | let vc = PaymentResultVC(result: .success, objType: .activityApply) |
| | | self?.push(vc: vc) |
| | | case .cancel: |
| | |
| | | YYPaymentManager.shared.sendPaymentRequest(YYWeChatPayRequest(partnerId: m.partnerid, prepayId: m.prepayid, package: m.package, nonceStr: m.noncestr, timeStamp: m.timestamp, sign: m.sign)) { result in |
| | | switch result { |
| | | case .success: |
| | | self?.getData() |
| | | let vc = PaymentResultVC(result: .success, objType: .activityApply) |
| | | self?.push(vc: vc) |
| | | case .cancel: |