RQPlaceDetaiIQuestionCell.m 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. //
  2. // RQPlaceDetaiIQuestionCell.m
  3. // JiaPei
  4. //
  5. // Created by 张嵘 on 2023/4/21.
  6. //
  7. #import "RQPlaceDetaiIQuestionCell.h"
  8. @interface RQPlaceDetaiIQuestionCell ()
  9. @property (nonatomic, readwrite, strong) RQPlaceDetaiIQuestionItemViewModel *viewModel;
  10. @property (weak, nonatomic) IBOutlet UIImageView *myBgImageView;
  11. @end
  12. @implementation RQPlaceDetaiIQuestionCell
  13. #pragma mark - PublicMethods
  14. + (instancetype)cellWithTableView:(UITableView *)tableView {
  15. static NSString *ID = @"RQPlaceDetaiIQuestionCell";
  16. RQPlaceDetaiIQuestionCell *cell = [tableView dequeueReusableCellWithIdentifier:ID];
  17. if (!cell) {
  18. cell = [self rq_viewFromXib];
  19. cell.selectionStyle = UITableViewCellSelectionStyleNone;
  20. }
  21. return cell;
  22. }
  23. - (void)bindViewModel:(RQPlaceDetaiIQuestionItemViewModel *)viewModel {
  24. _viewModel = viewModel;
  25. }
  26. #pragma mark - SystemMethods
  27. - (void)awakeFromNib {
  28. [super awakeFromNib];
  29. UIImage *image = [UIImage imageNamed:@"课程介绍框"];
  30. image = [image resizableImageWithCapInsets:UIEdgeInsetsMake(16.f, 16.f, 16.f, 16.f) resizingMode:UIImageResizingModeTile];
  31. _myBgImageView.image = image;
  32. }
  33. - (void)setSelected:(BOOL)selected animated:(BOOL)animated {
  34. [super setSelected:selected animated:animated];
  35. // Configure the view for the selected state
  36. }
  37. @end