Commit 1b3087bd0ce04f745f24a11bf0c54aa86b0702fa

Authored by liushiyu
1 parent 0b8f3858

兼容网家家环境库

metaCode/Classes/Environment/CNLiveEnvironment.swift
... ... @@ -6,6 +6,7 @@
6 6 //
7 7  
8 8 import Foundation
  9 +import CNLiveEnvironment
9 10  
10 11 ///当前应用的APPID
11 12 let APPId: String = CNLiveEnvironmentManager.shared.appId
... ... @@ -135,10 +136,13 @@ class CNLiveEnvironmentManager: NSObject{
135 136 switch environment {
136 137 case .development:
137 138 self.developmentEnvironment()
  139 + CNLiveEnvironmentManager.shared.setupEnvironment(environment: .development)
138 140 case .testFlight:
139 141 self.testFlightEnvironment()
  142 + CNLiveEnvironmentManager.shared.setupEnvironment(environment: .testFlight)
140 143 case .production:
141 144 self.productionEnvironment()
  145 + CNLiveEnvironmentManager.shared.setupEnvironment(environment: .production)
142 146 }
143 147 }
144 148  
... ...
metaCode/Classes/Main/MinePage/Controller/CNLiveMineAuthFormViewController.swift
... ... @@ -82,8 +82,7 @@ class CNLiveMineAuthFormViewController: CNLiveBaseViewController, UITableViewDel
82 82 guard let cell = tableView.dequeueReusableCell(withIdentifier: kMIneBodyAuthFormViewCellIdentifier) as? MineAuthFormTableViewCell else {
83 83 return MineAuthFormTableViewCell()
84 84 }
85   - cell.indexPath = indexPath
86   - cell.clickBlock = {[weak self] indexPath, view in
  85 + cell.clickBlock = {[weak self] view in
87 86 guard let self = self else { return }
88 87 let titleLabel = view.viewWithTag(1000) as! UILabel
89 88 if titleLabel.text == "个人认证" {
... ... @@ -147,7 +146,7 @@ extension CNLiveMineAuthFormViewController {
147 146 }
148 147 }
149 148  
150   -typealias clickWithClickBlock = (_ indexPath: IndexPath,_ view: UIView) -> Void
  149 +typealias clickWithClickBlock = (_ view: UIView) -> Void
151 150 class MineAuthFormTableViewCell: UITableViewCell {
152 151  
153 152 lazy var mainView: UIImageView = {
... ... @@ -226,7 +225,6 @@ class MineAuthFormTableViewCell: UITableViewCell {
226 225 return descLabel
227 226 }()
228 227  
229   - var indexPath: IndexPath!
230 228 var clickBlock: clickWithClickBlock!
231 229  
232 230 override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
... ... @@ -298,11 +296,11 @@ class MineAuthFormTableViewCell: UITableViewCell {
298 296 }
299 297  
300 298 @objc func clickWithWhiteAction() {
301   - self.clickBlock(indexPath,whiteView)
  299 + self.clickBlock(whiteView)
302 300 }
303 301  
304 302 @objc func clickWithWhite01Action() {
305   - self.clickBlock(indexPath,whiteView01)
  303 + self.clickBlock(whiteView01)
306 304 }
307 305  
308 306 required init?(coder: NSCoder) {
... ...