CommentCell.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. /**
  2. 做cell也有一个流程。
  3. 先写一个简单的view,填假数据,显示。
  4. 创建model,只写一个属性。加载model,并传给cell。显示这个真数据。
  5. 接下来,就简单了。
  6. */
  7. #import <UIKit/UIKit.h>
  8. //#import "Comment.h"
  9. #import "RDImageView.h"
  10. typedef enum{
  11. /**试题分析,没有星星
  12. */
  13. CommentCellStyleQuestion,
  14. /**驾校/教练点评,有星星
  15. */
  16. CommentCellStyleSchool
  17. }CommentCellStyle;
  18. @protocol CommentCellDelegate;
  19. @interface CommentCell : UITableViewCell
  20. {
  21. UIImageView* honorIv;
  22. UILabel* celDateLbl;
  23. RDImageView* rdImgV;
  24. CommentCellStyle cellStyle;
  25. }
  26. @property (nonatomic, copy) NSString *VCName;
  27. /**暂时只有对驾校的评论。教练的是空的。
  28. */
  29. @property(nonatomic,strong)NSDictionary* dict;
  30. /**cell的model
  31. */
  32. //@property(nonatomic,strong)Comment* model;
  33. /**
  34. 试题评论页面用
  35. */
  36. @property (nonatomic, strong) NSDictionary *commentDic;
  37. /**点赞按钮
  38. */
  39. @property(nonatomic,strong)UIButton* upBtn;
  40. @property(assign)id <CommentCellDelegate>delegate2;
  41. +(CommentCell*)cellForTableView:(UITableView*)tableView Style:(CommentCellStyle )style;
  42. @end
  43. @protocol CommentCellDelegate <NSObject>
  44. -(void)approveComId:(NSString*)comId;
  45. @end