TeachLogCell.m 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. //
  2. // TeachLogCell.m
  3. // LNManager
  4. //
  5. // Created by EchoShacolee on 2017/4/12.
  6. // Copyright © 2017年 lee. All rights reserved.
  7. //
  8. #import "TeachLogCell.h"
  9. @implementation TeachLogCell
  10. - (void)awakeFromNib {
  11. [super awakeFromNib];
  12. }
  13. -(void)setDataWithDic:(NSDictionary *)dic{
  14. _classId.text = [NSString stringWithFormat:@"%@",dic[@"CRI_CLASSID"]];
  15. _startTime.text = [NSString stringWithFormat:@"%@",dic[@"CRI_STARTTIME"]];
  16. _endTime.text = [NSString stringWithFormat:@"%@",dic[@"CRI_ENDTIME"]];
  17. // _stuNum.text = dic[@"STUNUM"];
  18. _stuNum.text = [NSString stringWithFormat:@"%@",dic[@"STUSIM"]];
  19. _kumu.text = @"";
  20. switch ([[NSString stringWithFormat:@"%@",dic[@"CRI_TRAIN_SUBJECT"]] integerValue]) {
  21. case 1:
  22. _kumu.text = @"科目:科目一";
  23. break;
  24. case 2:
  25. _kumu.text = @"科目:科目二";
  26. break;
  27. case 3:
  28. _kumu.text = @"科目:科目三";
  29. break;
  30. case 4:
  31. _kumu.text = @"科目:科目四";
  32. break;
  33. default:
  34. break;
  35. }
  36. _trainTime.text = [NSString stringWithFormat:@"训练时长:%@分钟",dic[@"CRI_VAILD_TIME"]];
  37. _trainKMeters.text = [NSString stringWithFormat:@"训练里程:%@km",dic[@"CRI_MILEAGE"]];
  38. }
  39. - (void)setSelected:(BOOL)selected animated:(BOOL)animated {
  40. [super setSelected:selected animated:animated];
  41. // Configure the view for the selected state
  42. }
  43. @end