|
@@ -140,17 +140,17 @@ extension RecommendSimilarCell: UICollectionViewDelegateFlowLayout,UICollectionV
|
|
|
}
|
|
|
|
|
|
func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell {
|
|
|
- let cell = SearchContentListCollectionCell.cellWith(collectionView: collectionView, indexPath: indexPath)
|
|
|
- cell.communityPostDataModel = communityPostDataModels?[indexPath.row]
|
|
|
-// cell.userClosure = {
|
|
|
-// [weak self] in
|
|
|
-// if cell.communityPostDataModel?.uid != UserModel.shared().getModel()?.uid {
|
|
|
-// let vc = OtherPersonalCenterViewController()
|
|
|
-// vc.uid = cell.communityPostDataModel?.uid ?? 0
|
|
|
-// self?.findViewController().navigationController?.pushViewController(vc, animated: true)
|
|
|
-// }
|
|
|
-// }
|
|
|
- return cell
|
|
|
+ weak var cell = SearchContentListCollectionCell.cellWith(collectionView: collectionView, indexPath: indexPath)
|
|
|
+ cell?.communityPostDataModel = communityPostDataModels?[indexPath.row]
|
|
|
+ cell?.userClosure = {
|
|
|
+ [weak self] in
|
|
|
+ if cell?.communityPostDataModel?.uid != UserModel.shared().getModel()?.uid {
|
|
|
+ let vc = OtherPersonalCenterViewController()
|
|
|
+ vc.uid = cell?.communityPostDataModel?.uid ?? 0
|
|
|
+ self?.findViewController().navigationController?.pushViewController(vc, animated: true)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return cell!
|
|
|
}
|
|
|
|
|
|
func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
|