No Description

FKHomeReform.m 596B

1234567891011121314151617181920212223242526272829
  1. //
  2. // FKHomeReform.m
  3. // FirstLink
  4. //
  5. // Created by 施昌鹏 on 16/7/16.
  6. // Copyright © 2016年 FirstLink. All rights reserved.
  7. //
  8. #import "FKHomeReform.h"
  9. @implementation FKHomeReform
  10. +(NSInteger)parseCouponCount:(NSDictionary *)json {
  11. NSNumber *res = json[@"data"][@"count"];
  12. if ([res isKindOfClass:[NSNumber class]]) {
  13. return res.integerValue;
  14. }
  15. return 0;
  16. }
  17. +(NSString *)parseServerTime:(NSDictionary *)json {
  18. if ([json[@"data"][@"server_time"] isKindOfClass:[NSString class]]) {
  19. return json[@"data"][@"server_time"];
  20. }
  21. return nil;
  22. }
  23. @end