MonthModel.h 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. //
  2. // MonthModel.h
  3. // BJTResearch
  4. //
  5. // Created by yunlong on 17/5/12.
  6. // Copyright © 2017年 yunlong. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. #import <UIKit/UIKit.h>
  10. typedef enum : NSUInteger {
  11. DayModelStateNormal = 0,
  12. DayModelStateStart,
  13. DayModelStateEnd,
  14. DayModelStateSelected,
  15. DayModelStatePast,
  16. } DayModelState;
  17. typedef enum : NSUInteger {
  18. Sunday = 1,
  19. Monday,
  20. Tuesday,
  21. Wednesday,
  22. Thursday,
  23. Friday,
  24. Saturday,
  25. } DayModelOfTheWeek;
  26. @interface DayModel : NSObject
  27. /**
  28. * 年
  29. */
  30. @property(nonatomic,assign)NSInteger year;
  31. /**
  32. * 月
  33. */
  34. @property(nonatomic,assign)NSInteger month;
  35. /**
  36. * 日
  37. */
  38. @property(nonatomic,assign)NSInteger day;
  39. /**
  40. * 日期
  41. */
  42. @property(nonatomic,strong)NSDate *dayDate;
  43. /**
  44. * 星期
  45. */
  46. @property(nonatomic,assign)DayModelOfTheWeek dayOfTheWeek;
  47. /**
  48. * 日期的状态
  49. */
  50. @property(nonatomic,assign)DayModelState state;
  51. /**
  52. * 日期是不是今天
  53. */
  54. @property(nonatomic,assign)BOOL isToday;
  55. /**
  56. * 第几天
  57. */
  58. @property(nonatomic,assign)int Daysort;
  59. /**
  60. * 都选好了
  61. */
  62. @property(nonatomic,assign)BOOL isEndTimeOK;
  63. /**
  64. * 是否是过去时间
  65. */
  66. @property(nonatomic,assign)BOOL isStatePast;
  67. @end
  68. @interface MonthModel : NSObject
  69. /**
  70. * 年
  71. */
  72. @property(nonatomic,assign)NSInteger year;
  73. /**
  74. * 月
  75. */
  76. @property(nonatomic,assign)NSInteger month;
  77. /**
  78. * 一个月中UICollectionViewCell的个数
  79. */
  80. @property(nonatomic,assign)NSInteger cellNum;
  81. /**
  82. * 月UITableViewCell的高度
  83. */
  84. @property(nonatomic,assign)CGFloat cellHight;
  85. /**
  86. * UICollectionViewCell开始的位置
  87. */
  88. @property(nonatomic,assign)NSInteger cellStartNum;
  89. /**
  90. * 月UITableViewCell的高度
  91. */
  92. @property(nonatomic,strong)NSArray<DayModel *> * days;
  93. @end