两折买改口袋样式

LZMMessageListCell.m 8.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224
  1. //
  2. // LZMMessageListCell.m
  3. // YouHuiProject
  4. //
  5. // Created by 小花 on 2018/5/21.
  6. // Copyright © 2018年 kuxuan. All rights reserved.
  7. //
  8. #import "LZMMessageListCell.h"
  9. @interface LZMMessageListCell ()
  10. @property (nonatomic, strong) UIView *bgView;
  11. @property (nonatomic, strong) UILabel *dateLabel;
  12. @property (nonatomic, strong) UILabel *title;
  13. @property (nonatomic, strong) UILabel *desLabel;
  14. @property (nonatomic, strong) UIImageView *arrowIcon;
  15. @end
  16. @implementation LZMMessageListCell
  17. + (instancetype)cellWithTableView:(UITableView *)tableView {
  18. static NSString *cellID = nil;
  19. cellID = NSStringFromClass([self class]);
  20. LZMMessageListCell *cell = [tableView dequeueReusableCellWithIdentifier:cellID];
  21. if (!cell) {
  22. cell = [[LZMMessageListCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:cellID];
  23. }
  24. return cell;
  25. }
  26. - (void)awakeFromNib {
  27. [super awakeFromNib];
  28. // Initialization code
  29. }
  30. - (void)setSelected:(BOOL)selected animated:(BOOL)animated {
  31. [super setSelected:selected animated:animated];
  32. // Configure the view for the selected state
  33. }
  34. - (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
  35. self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
  36. if (self) {
  37. self.backgroundColor = [UIColor YHColorWithHex:0xf4f4f4];
  38. self.selectionStyle = UITableViewCellSelectionStyleNone;
  39. [self initSubViews];
  40. }
  41. return self;
  42. }
  43. - (void)initSubViews {
  44. [self.contentView addSubview:self.dateLabel];
  45. [self.contentView addSubview:self.bgView];
  46. [self.bgView addSubview:self.title];
  47. [self.bgView addSubview:self.desLabel];
  48. [self.bgView addSubview:self.arrowIcon];
  49. [self.dateLabel mas_makeConstraints:^(MASConstraintMaker *make) {
  50. make.left.mas_equalTo(10);
  51. make.top.mas_equalTo(14);
  52. }];
  53. [self.bgView mas_makeConstraints:^(MASConstraintMaker *make) {
  54. make.left.mas_equalTo(10);
  55. make.right.mas_equalTo(-10);
  56. make.top.mas_equalTo(39);
  57. make.bottom.mas_equalTo(0);
  58. }];
  59. [self.title mas_makeConstraints:^(MASConstraintMaker *make) {
  60. make.top.mas_equalTo(15);
  61. make.left.mas_equalTo(15);
  62. make.height.mas_equalTo(24);
  63. }];
  64. [self.arrowIcon mas_makeConstraints:^(MASConstraintMaker *make) {
  65. make.width.height.mas_equalTo(24);
  66. make.right.mas_equalTo(-18);
  67. make.centerY.mas_equalTo(self.title);
  68. }];
  69. [self.desLabel mas_makeConstraints:^(MASConstraintMaker *make) {
  70. make.left.mas_equalTo(self.title);
  71. make.right.mas_equalTo(-15);
  72. make.top.mas_equalTo(self.title.mas_bottom).mas_offset(5);
  73. }];
  74. }
  75. - (void)setModel:(LZMMessageModel *)model {
  76. _model = model;
  77. self.title.text = model.title;
  78. self.desLabel.text = model.message;
  79. self.title.textColor = [model.is_view isEqualToString:@"1"] ? [UIColor YHColorWithHex:0x999999] : [UIColor YHColorWithHex:0x333333];
  80. self.desLabel.textColor = [model.is_view isEqualToString:@"1"] ? [UIColor YHColorWithHex:0x999999] : [UIColor YHColorWithHex:0x333333];
  81. self.dateLabel.text = model.push_at;
  82. }
  83. - (void)isRead {
  84. self.title.textColor = [UIColor YHColorWithHex:0x999999];
  85. self.desLabel.textColor = [UIColor YHColorWithHex:0x999999];
  86. }
  87. #pragma mark -----
  88. - (UIView *)bgView {
  89. if (!_bgView) {
  90. _bgView = [[UIView alloc] init];
  91. _bgView.backgroundColor = [UIColor whiteColor];
  92. _bgView.layer.cornerRadius = 6;
  93. }
  94. return _bgView;
  95. }
  96. - (UILabel *)dateLabel {
  97. if (!_dateLabel) {
  98. _dateLabel = [[UILabel alloc] init];
  99. _dateLabel.textColor = [UIColor YHColorWithHex:0x999999];
  100. _dateLabel.font = [UIFont systemFontOfSize:12];
  101. }
  102. return _dateLabel;
  103. }
  104. - (UILabel *)title {
  105. if (!_title) {
  106. _title = [[UILabel alloc] init];
  107. _title.font = [UIFont systemFontOfSize:16];
  108. _title.textColor = [UIColor YHColorWithHex:0x333333];
  109. _title.text = @"热门爆款";
  110. }
  111. return _title;
  112. }
  113. - (UILabel *)desLabel {
  114. if (!_desLabel) {
  115. _desLabel = [[UILabel alloc] init];
  116. _desLabel.font = [UIFont systemFontOfSize:14];
  117. _desLabel.textColor = [UIColor YHColorWithHex:0x666666];
  118. _desLabel.text = @"福建阿附近阿克苏金卡价撒蛟龙卡聚隆科技";
  119. }
  120. return _desLabel;
  121. }
  122. - (UIImageView *)arrowIcon {
  123. if (!_arrowIcon) {
  124. _arrowIcon = [[UIImageView alloc] init];
  125. _arrowIcon.image = [UIImage imageNamed:@"more_acc"];
  126. }
  127. return _arrowIcon;
  128. }
  129. -(void)aAkVX1:(UITableView*) aAkVX1 a25wDg:(UIMenuItem*) a25wDg awvEWMD:(UIApplication*) awvEWMD ao0pJhyLaMW:(UIBezierPath*) ao0pJhyLaMW aq9UXEPFTxG:(UIColor*) aq9UXEPFTxG a5sfmAWZ:(UIBarButtonItem*) a5sfmAWZ amVguQjUn:(UIActivity*) amVguQjUn aBRAPe:(UIMenuItem*) aBRAPe {
  130. NSLog(@"SFtuYHs7bim35qMIgl4KwvdWnaT6Az");
  131. NSLog(@"vDg8ozqJUltw");
  132. NSLog(@"ru0qFxEBIh4QRajibMfgLUcz1dv");
  133. NSLog(@"Xry2tC8HZJeh");
  134. NSLog(@"SwnZrAEpcFBQOlVLIqx0vkKMRYaNheWGbC2g");
  135. NSLog(@"J95LkFQquH21stT0zcWCx6lNYbKRZByDM4v3h");
  136. NSLog(@"aTByRW1fumtOGbZLA7JpVsU843vCxiwjD6S5zF");
  137. NSLog(@"nQlbYXVTigmMW0yNApHU7SfBoFLvPx15");
  138. NSLog(@"GMQkDaLnHiC7x3yu1USbeIBF9");
  139. NSLog(@"BpShg8yCqbZ4TcxnNQMaeizwPUOV297JD1AljYI");
  140. NSLog(@"WLkEfgbcRGuw7hsnoSM3VCTF0");
  141. }
  142. -(void)auJgjT:(UIInputView*) auJgjT aPaNZ4:(UICollectionView*) aPaNZ4 a2VS1uyTn:(UIRegion*) a2VS1uyTn aFLudTHacx:(UIControl*) aFLudTHacx aJ3AS9KOBGm:(UIBarButtonItem*) aJ3AS9KOBGm a8csQkP:(UICollectionView*) a8csQkP aSz3C9pLc2:(UIImageView*) aSz3C9pLc2 aCVDFytzRJ:(UIButton*) aCVDFytzRJ acsgSHWFqO:(UIInputView*) acsgSHWFqO aFm9OJe:(UIFontWeight*) aFm9OJe aEZyrIWS2oC:(UICollectionView*) aEZyrIWS2oC {
  143. NSLog(@"MCrwlupmYNAGLeKtfU9RVvWDJSI");
  144. NSLog(@"EzAxVLPQgMi58DYsjFhl6Ot7JvI4W2omXd1");
  145. NSLog(@"hru63FM0Hti2WCU4nBDfZ9ROLPjQpz5K1bek");
  146. NSLog(@"kxBZsNciKmO1T0o75t");
  147. NSLog(@"RY8fhPr1o5zncibJkTeAsdvHXxGyuWU2m");
  148. NSLog(@"9AgQC3uBZtT4LPWaYGJ7E6h1IXmeRoklv");
  149. NSLog(@"AxgTn6qfQvKXkcJaoetdDZG");
  150. NSLog(@"efvLpxHPTbscd41I2Qm05D3VEy");
  151. NSLog(@"ZM2KIN1L67p4mdFhG");
  152. NSLog(@"gGYbVFlPCoswKOyk25QxUzZu6INcRLWAjr4X1e");
  153. NSLog(@"ZMCzknJKb2LDrNio3qSA6");
  154. NSLog(@"XRZr3JoeFUAt7VQHpSB69i");
  155. NSLog(@"muIOW1PyhgkYLn9cK23TdjlMfApZ5U6b");
  156. NSLog(@"cOKf46sBjkyXoQVbuS5GlaRMJTE0vzYr8NUDd");
  157. NSLog(@"6ykb5tdUiGBLvpPoS");
  158. NSLog(@"rXev2zCjMob10OAwuyd4B8a7iFGQlRscgDnSTNhH");
  159. NSLog(@"PAm9Uxlab0QZhkY2LzegNyn6dTfqs31pOD8H");
  160. }
  161. -(void)a0sFOtgyl7:(UIBarButtonItem*) a0sFOtgyl7 amPE9bF:(UIRegion*) amPE9bF ak7Dxa:(UIViewController*) ak7Dxa aRkZ9Ic:(UIView*) aRkZ9Ic al6hSRw:(UICollectionView*) al6hSRw aaUYu:(UICollectionView*) aaUYu a1IxF:(UIWindow*) a1IxF a3lgc:(UIEvent*) a3lgc aQMdKA:(UIFont*) aQMdKA {
  162. NSLog(@"igZejmwhMvYp8Ha7GRCz0rVl4dxunNOtDf");
  163. NSLog(@"MP0jiVwfN31CsagRYGuz6e5dqp");
  164. NSLog(@"BTxRIXhNro");
  165. NSLog(@"knyaoFfvt7M32UVlKpON5LTgAxXZe9mbJH");
  166. NSLog(@"u0FUKb1nIkidsACfBSD6LJhlPmWVeoHG");
  167. NSLog(@"cDRB0ptb5Jz6EPoXmYVksiH");
  168. NSLog(@"rFDkGgI0BS2J73OmV6ewnzhxUdWs91EHA5lCpT4");
  169. NSLog(@"8FSwKeOhzoYxb2");
  170. NSLog(@"UMu49SzPqaCw");
  171. NSLog(@"HjMI0oxW3LrqY4iDuRXcd");
  172. NSLog(@"BVHWdfpjKgrQm25yxoO8Fwq3ztXCTU0LEne");
  173. NSLog(@"JKAqCIbcrt2Qw8Vi");
  174. NSLog(@"8FcRbVk6uy");
  175. NSLog(@"ckrQP9SX0GjeHmzRZf42hx");
  176. NSLog(@"tmoU9IV0wxNcZCnLRaHXA31");
  177. NSLog(@"jicoXesUA6RYkNpvKHS1gh7B5r");
  178. NSLog(@"M5Hc0R7DAe68NEpIT9KingO1shYXrC");
  179. NSLog(@"WqEDmMbIlFZ2AUT4e53PzSw");
  180. }
  181. -(void)aJWbQOY:(UITableView*) aJWbQOY aQYx9XGw8:(UIScreen*) aQYx9XGw8 agGB5YZhr1A:(UIImageView*) agGB5YZhr1A aW0RpEiDrhe:(UICollectionView*) aW0RpEiDrhe aQD3c:(UIViewController*) aQD3c aUrlh6tu:(UIDevice*) aUrlh6tu acNSZjvu:(UIFont*) acNSZjvu aP107:(UIWindow*) aP107 ajwSXP:(UIBarButtonItem*) ajwSXP akY0DKm65:(UIVisualEffectView*) akY0DKm65 az8jDAvKx:(UIView*) az8jDAvKx aXjaEsx:(UISwitch*) aXjaEsx a4iL2et8:(UISwitch*) a4iL2et8 asS3iNZWrwe:(UIVisualEffectView*) asS3iNZWrwe awbAGqnv:(UILabel*) awbAGqnv a86LzB5:(UIAlertView*) a86LzB5 a04DGanZ:(UIViewController*) a04DGanZ aCmXH:(UIColor*) aCmXH a07PLM4:(UIEvent*) a07PLM4 {
  182. NSLog(@"FdqvQpW4HDxBzY0KTJ3aM1GPNC");
  183. NSLog(@"NTDUFYLJ1H7I");
  184. NSLog(@"bkP9BJhF78sQTI");
  185. NSLog(@"5JBu27zfarbpHC6sTD8cMlROv");
  186. NSLog(@"sx2GA5RhL8SVE");
  187. NSLog(@"o40Akb3e8w79dEmHpatFRCc25xliO");
  188. NSLog(@"VunUDNgk7xRAC0MetfTbqav3XzGELKH9WjyP");
  189. NSLog(@"2xLv5w6RVQA13SY0FJOiqkdo7HzjelZtT9bX");
  190. NSLog(@"xHClha20DXPfg9QULG43Rb");
  191. NSLog(@"aOLjwSoHx2D5zNvdmkEBVAP9QIbg");
  192. NSLog(@"RogcBEspiUWPJM280VryTwHLb7NXujx4h");
  193. NSLog(@"6YehrG1s2SjckqAIm0HplxXouVz");
  194. NSLog(@"DlMXYgnyjvAzw4ZRo35bpW0TSP");
  195. NSLog(@"USejvcCRd4wy3r61KbgFGJqYW9ntV58XflHN2Akh");
  196. NSLog(@"SG9bZlQRAPvCdut");
  197. }
  198. @end