GlobalMethod+Authority.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. //
  2. // GlobalMethod+Authority.h
  3. // 乐销
  4. //
  5. // Created by 隋林栋 on 2017/6/16.
  6. // Copyright © 2017年 ping. All rights reserved.
  7. //
  8. #import "GlobalMethod.h"
  9. //权限类型
  10. typedef NS_ENUM(NSUInteger, AUTHORITY_TYPE) {
  11. AUTHORITY_PHOTO,
  12. AUTHORITY_CAMERA,
  13. AUTHORITY_ADDRESSBOOK,
  14. AUTHORITY_MIC,
  15. AUTHORITY_LOCAL,//没写
  16. };
  17. @interface GlobalMethod (Authority)
  18. //获取相册权限
  19. + (void)fetchPhotoAuthorityBlock:(void (^)(void))block;
  20. //获取照相机权限
  21. + (void)fetchCameraAuthorityBlock:(void (^)(void))block;
  22. // 通讯录
  23. + (void)fetchAddressBookAuthorityBlock:(void (^)(void))block;
  24. // 麦克风
  25. + (void)fetchMicAuthorityBlock:(void (^)(void))block;
  26. #pragma mark - 定位
  27. + (void)fetchLocalAuthorityBlock:(void (^)(void))block;
  28. /**
  29. 调用电话功能
  30. @param ViewController 调用类
  31. @param phoneStr 电话号码
  32. */
  33. +(void)gotoCallPhoneClick:(UIViewController *)ViewController phone:(NSString *)phoneStr;
  34. /**
  35. 获取设备唯一信息 包括 UUID系统(逻辑) 运营商 版本号 系统名
  36. */
  37. + (NSString *)fetchDeviceID;
  38. @end