| | |
| | | tableView.separatorStyle = .none |
| | | tableView.register(UINib(nibName: "GoodsItemTCell", bundle: nil), forCellReuseIdentifier: "_GoodsItemTCell") |
| | | view.addSubview(tableView) |
| | | tableView.snp.makeConstraints { make in |
| | | tableView.snp.makeConstraints {[weak self] make in |
| | | guard let weakSelf = self else { return } |
| | | make.left.equalTo(159 * Config.RatioW) |
| | | make.right.equalTo(-159 * Config.RatioW) |
| | | make.top.equalTo(self.view.safeAreaLayoutGuide.snp.top).offset(27 * Config.RatioW) |
| | | make.bottom.equalTo(self.view.safeAreaLayoutGuide.snp.bottom).offset(-5) |
| | | make.top.equalTo(weakSelf.view.safeAreaLayoutGuide.snp.top).offset(27 * Config.RatioW) |
| | | make.bottom.equalTo(weakSelf.view.safeAreaLayoutGuide.snp.bottom).offset(-5) |
| | | } |
| | | } |
| | | |
| | | override func setRx() { |
| | | NotificationCenter.default.rx.notification(Refresh_MarketExchange_Noti).take(until: self.rx.deallocated).subscribe(onNext: {_ in |
| | | self.viewModel.beginRefresh() |
| | | NotificationCenter.default.rx.notification(Refresh_MarketExchange_Noti).take(until: self.rx.deallocated).subscribe(onNext: {[weak self] _ in |
| | | self?.viewModel.beginRefresh() |
| | | }).disposed(by: disposeBag) |
| | | } |
| | | } |
| | |
| | | func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { |
| | | return viewModel.dataSource.value.count |
| | | } |
| | | |
| | | // func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat { |
| | | //// return 215 |
| | | // } |
| | | |
| | | |
| | | } |