NYLIVipAuthorityNewItemViewModel.m 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. //
  2. // NYLIVipAuthorityNewItemViewModel.m
  3. // jiaPei
  4. //
  5. // Created by Ning.ge on 2025/2/6.
  6. // Copyright © 2025 JCZ. All rights reserved.
  7. //
  8. #import "NYLIVipAuthorityNewItemViewModel.h"
  9. @interface NYLIVipAuthorityNewItemViewModel ()
  10. @property (nonatomic, readwrite, strong) RQTypeModel *chooseTypeModel;
  11. @property (nonatomic, readwrite, strong) NSString *bgImageName;
  12. @property (nonatomic, readwrite, strong) NSString *authorityTitle;
  13. @property (nonatomic, readwrite, strong) NSString *authorityTitle01;
  14. @property (nonatomic, readwrite, strong) NSString *authorityTitle02;
  15. @end
  16. @implementation NYLIVipAuthorityNewItemViewModel
  17. - (instancetype)initWithChooseTypeModel:(RQTypeModel *)chooseTypeModel {
  18. if (self = [super init]) {
  19. self.chooseTypeModel = chooseTypeModel;
  20. CGFloat RQVipAuthorityCellWidth = RQ_SCREEN_WIDTH;
  21. CGFloat RQVipAuthorityCellHeight = RQVipAuthorityCellWidth * (145.f / 375.f) + 10;
  22. if ([chooseTypeModel.dictLabel containsString:@"科一特训包"]) {
  23. self.bgImageName = @"li_zu_kbg01";
  24. self.authorityTitle = @"尊享科一特训包权益";
  25. self.authorityTitle01 = @"精选 500题,覆盖高频考点";
  26. self.authorityTitle02 = @"尊分类讲解,深入解析易错题同款题库模拟,助你轻松过关";
  27. } else if ([chooseTypeModel.dictLabel containsString:@"科四特训包"]) {
  28. self.bgImageName = @"li_zu_kbg02";
  29. self.authorityTitle = @"尊享科四特训包权益";
  30. self.authorityTitle01 = @"精选 300题,直击考场重点";
  31. self.authorityTitle02 = @"分类讲解,掌握技巧与核心内容同款题库模拟,快速提升通过率";
  32. } else if ([chooseTypeModel.dictLabel containsString:@"科一科四特训包"]) {
  33. self.bgImageName = @"li_zu_kbg03";
  34. self.authorityTitle = @"尊享科一科四特训包权益";
  35. self.authorityTitle01 = @"包含科目一 500题和科目四300题";
  36. self.authorityTitle02 = @"分类精讲,强化记忆,双科高效速通同款题库配套,精准还原考试体验";
  37. }
  38. self.itemSize = CGSizeMake(RQVipAuthorityCellWidth, RQVipAuthorityCellHeight);
  39. }
  40. return self;
  41. }
  42. - (NSString *)itemClassName {
  43. return @"NYLIVipAuthorityNewCell";
  44. }
  45. @end