Commit a22df499b1bd2572c0a559406c41bf84e622ba39
1 parent
faae2a63
提交0.0.4
Showing
3 changed files
with
29 additions
and
20 deletions
CNLiveServiceCenterModule.podspec
| @@ -8,7 +8,7 @@ | @@ -8,7 +8,7 @@ | ||
| 8 | 8 | ||
| 9 | Pod::Spec.new do |s| | 9 | Pod::Spec.new do |s| |
| 10 | s.name = 'CNLiveServiceCenterModule' | 10 | s.name = 'CNLiveServiceCenterModule' |
| 11 | - s.version = '0.0.3' | 11 | + s.version = '0.0.4' |
| 12 | s.summary = '网家家企业端服务中心模块' | 12 | s.summary = '网家家企业端服务中心模块' |
| 13 | 13 | ||
| 14 | # This description is used to generate tags and improve search results. | 14 | # This description is used to generate tags and improve search results. |
| @@ -87,8 +87,7 @@ Pod::Spec.new do |s| | @@ -87,8 +87,7 @@ Pod::Spec.new do |s| | ||
| 87 | ### 所有github三方管理库(非频繁更新) | 87 | ### 所有github三方管理库(非频繁更新) |
| 88 | ######################################## | 88 | ######################################## |
| 89 | s.dependency 'CNLiveTripartiteManagement' | 89 | s.dependency 'CNLiveTripartiteManagement' |
| 90 | - | ||
| 91 | -# s.dependency 'CNLiveOrganizationValidationModule' | 90 | + s.dependency 'CNLiveOrganizationValidationModule' |
| 92 | 91 | ||
| 93 | 92 | ||
| 94 | end | 93 | end |
CNLiveServiceCenterModule/Classes/CNLiveServiceCenterModule/Controller/CNLiveBServiceCenterController.m
| @@ -60,7 +60,7 @@ | @@ -60,7 +60,7 @@ | ||
| 60 | - (void)viewWillAppear:(BOOL)animated { | 60 | - (void)viewWillAppear:(BOOL)animated { |
| 61 | [super viewWillAppear:animated]; | 61 | [super viewWillAppear:animated]; |
| 62 | self.navigationController.navigationBarHidden = YES; | 62 | self.navigationController.navigationBarHidden = YES; |
| 63 | -// [self loadStatus]; | 63 | + // [self loadStatus]; |
| 64 | } | 64 | } |
| 65 | 65 | ||
| 66 | - (void)viewDidLoad { | 66 | - (void)viewDidLoad { |
| @@ -140,7 +140,7 @@ | @@ -140,7 +140,7 @@ | ||
| 140 | if (indexPath.row == 0) { | 140 | if (indexPath.row == 0) { |
| 141 | [certificationCell configUI:[CNLiveBServiceCenterModel new] type:CNLiveBServiceCertificationCellTypePerson]; | 141 | [certificationCell configUI:[CNLiveBServiceCenterModel new] type:CNLiveBServiceCertificationCellTypePerson]; |
| 142 | }else { | 142 | }else { |
| 143 | - [certificationCell configUI:[CNLiveBServiceCenterModel new] type:CNLiveBServiceCertificationCellTypeInstitutions]; | 143 | + [certificationCell configUI:[CNLiveBServiceCenterModel new] type:CNLiveBServiceCertificationCellTypeInstitutions]; |
| 144 | } | 144 | } |
| 145 | return certificationCell; | 145 | return certificationCell; |
| 146 | }else if (indexPath.row == 2){ | 146 | }else if (indexPath.row == 2){ |
| @@ -269,18 +269,18 @@ | @@ -269,18 +269,18 @@ | ||
| 269 | NSString *appId = [NSString stringWithFormat:@"%@",AppId]; | 269 | NSString *appId = [NSString stringWithFormat:@"%@",AppId]; |
| 270 | NSString *uid = [NSString stringWithFormat:@"%@",@"10514333"];//CNUserShareModel.uid | 270 | NSString *uid = [NSString stringWithFormat:@"%@",@"10514333"];//CNUserShareModel.uid |
| 271 | NSString *token = [NSString stringWithFormat:@"%@",@"RkFYeLkl/u5S7tW8UcOkT/BgxDgw4wRl2IcNNhtX0dlnOLY/PL7CjnmmJyhKGpkj"];//CNUserShareModel.token | 271 | NSString *token = [NSString stringWithFormat:@"%@",@"RkFYeLkl/u5S7tW8UcOkT/BgxDgw4wRl2IcNNhtX0dlnOLY/PL7CjnmmJyhKGpkj"];//CNUserShareModel.token |
| 272 | -// //将参数进行排序,用 a=b&c=d 的拼接成字符串,最后拼上 key=AppKey | ||
| 273 | -// NSString *sortString = [NSString stringWithFormat:@"%@&key=%@", [TIMTools sortParameters:params], APPKey]; | ||
| 274 | -// //对排序过的参数进行sha1加密,并转成大写 | ||
| 275 | -// NSString *signString = [[TIMTools sha1:sortString] uppercaseString]; | 272 | + // //将参数进行排序,用 a=b&c=d 的拼接成字符串,最后拼上 key=AppKey |
| 273 | + // NSString *sortString = [NSString stringWithFormat:@"%@&key=%@", [TIMTools sortParameters:params], APPKey]; | ||
| 274 | + // //对排序过的参数进行sha1加密,并转成大写 | ||
| 275 | + // NSString *signString = [[TIMTools sha1:sortString] uppercaseString]; | ||
| 276 | #pragma mark - TODO:请求路径刷新 | 276 | #pragma mark - TODO:请求路径刷新 |
| 277 | NSDictionary *dict = @{ | 277 | NSDictionary *dict = @{ |
| 278 | - @"appId":appId, | ||
| 279 | - @"uid":uid, | ||
| 280 | - @"clientPlat":@"i", | ||
| 281 | - @"token":token, | ||
| 282 | -// @"sign":@"2A5F8868275C4562801D8F75DDE21D2BF9CA156F", | ||
| 283 | - }; | 278 | + @"appId":appId, |
| 279 | + @"uid":uid, | ||
| 280 | + @"clientPlat":@"i", | ||
| 281 | + @"token":token, | ||
| 282 | + // @"sign":@"2A5F8868275C4562801D8F75DDE21D2BF9CA156F", | ||
| 283 | + }; | ||
| 284 | [CNLiveNetworking setAllowRequestDefaultArgument:YES]; | 284 | [CNLiveNetworking setAllowRequestDefaultArgument:YES]; |
| 285 | [CNLiveNetworking setupShowDataResult:NO]; | 285 | [CNLiveNetworking setupShowDataResult:NO]; |
| 286 | [CNLiveNetworking requestNetworkWithMethod:CNLiveRequestMethodPOST URLString:strUrl Param:dict CacheType:CNLiveNetworkCacheTypeNetworkOnly CompletionBlock:^(NSURLSessionTask *requestTask, id responseObject, NSError *error) { | 286 | [CNLiveNetworking requestNetworkWithMethod:CNLiveRequestMethodPOST URLString:strUrl Param:dict CacheType:CNLiveNetworkCacheTypeNetworkOnly CompletionBlock:^(NSURLSessionTask *requestTask, id responseObject, NSError *error) { |
| @@ -303,7 +303,7 @@ | @@ -303,7 +303,7 @@ | ||
| 303 | 303 | ||
| 304 | 304 | ||
| 305 | }]; | 305 | }]; |
| 306 | - | 306 | + |
| 307 | 307 | ||
| 308 | } | 308 | } |
| 309 | 309 | ||
| @@ -342,22 +342,27 @@ | @@ -342,22 +342,27 @@ | ||
| 342 | NSDictionary *dicContent = (NSDictionary *)data; | 342 | NSDictionary *dicContent = (NSDictionary *)data; |
| 343 | if (dicContent) { | 343 | if (dicContent) { |
| 344 | if ([dicContent containsObjectForKey:@"isCertification"]) { | 344 | if ([dicContent containsObjectForKey:@"isCertification"]) { |
| 345 | - NSString *isCertificationStr = [NSString stringWithFormat:@"%@"[dicContent objectForKey:@"isCertification"]]; | 345 | + NSString *isCertificationStr = [NSString stringWithFormat:@"%@",[dicContent objectForKey:@"isCertification"]]; |
| 346 | if ([isCertificationStr isEqualToString:@"0"]) { | 346 | if ([isCertificationStr isEqualToString:@"0"]) { |
| 347 | /// 填表页 | 347 | /// 填表页 |
| 348 | id<CNLiveBOrganizationValidationProtocol> organizationValidationProtocol = [[BeeHive shareInstance] createService:@protocol(CNLiveBOrganizationValidationProtocol)]; | 348 | id<CNLiveBOrganizationValidationProtocol> organizationValidationProtocol = [[BeeHive shareInstance] createService:@protocol(CNLiveBOrganizationValidationProtocol)]; |
| 349 | - UIViewController *vc = [organizationValidationProtocol getOrganizationValidationController:@{}]; | 349 | + UIViewController *vc = [organizationValidationProtocol getOrganizationValidationController:dicContent]; |
| 350 | [self.navigationController pushViewController:vc animated:YES]; | 350 | [self.navigationController pushViewController:vc animated:YES]; |
| 351 | 351 | ||
| 352 | isEnter = YES; | 352 | isEnter = YES; |
| 353 | }else if ([isCertificationStr isEqualToString:@"1"]) { | 353 | }else if ([isCertificationStr isEqualToString:@"1"]) { |
| 354 | /// 详情页 | 354 | /// 详情页 |
| 355 | id<CNLiveBOrganizationValidationProtocol> organizationValidationProtocol = [[BeeHive shareInstance] createService:@protocol(CNLiveBOrganizationValidationProtocol)]; | 355 | id<CNLiveBOrganizationValidationProtocol> organizationValidationProtocol = [[BeeHive shareInstance] createService:@protocol(CNLiveBOrganizationValidationProtocol)]; |
| 356 | - UIViewController *vc = [organizationValidationProtocol getOrganizationDetailController:@{}]; | 356 | + UIViewController *vc = [organizationValidationProtocol getOrganizationDetailController:dicContent]; |
| 357 | [self.navigationController pushViewController:vc animated:YES]; | 357 | [self.navigationController pushViewController:vc animated:YES]; |
| 358 | 358 | ||
| 359 | isEnter = YES; | 359 | isEnter = YES; |
| 360 | }else if ([isCertificationStr isEqualToString:@"2"]) { | 360 | }else if ([isCertificationStr isEqualToString:@"2"]) { |
| 361 | +#pragma mark - TODO: 测试先用 | ||
| 362 | + /// 详情页 | ||
| 363 | + id<CNLiveBOrganizationValidationProtocol> organizationValidationProtocol = [[BeeHive shareInstance] createService:@protocol(CNLiveBOrganizationValidationProtocol)]; | ||
| 364 | + UIViewController *vc = [organizationValidationProtocol getOrganizationDetailController:dicContent]; | ||
| 365 | + [self.navigationController pushViewController:vc animated:YES]; | ||
| 361 | 366 | ||
| 362 | isEnter = YES; | 367 | isEnter = YES; |
| 363 | } | 368 | } |
| @@ -372,7 +377,7 @@ | @@ -372,7 +377,7 @@ | ||
| 372 | }else { | 377 | }else { |
| 373 | 378 | ||
| 374 | } | 379 | } |
| 375 | - | 380 | + |
| 376 | }]; | 381 | }]; |
| 377 | 382 | ||
| 378 | 383 |
Example/CNLiveServiceCenterModule/CNLIVEBAppDelegate.m
| @@ -65,6 +65,11 @@ static NSString * uuid; | @@ -65,6 +65,11 @@ static NSString * uuid; | ||
| 65 | NSLog(@"打印appkey%@",APPKey); | 65 | NSLog(@"打印appkey%@",APPKey); |
| 66 | [CNLiveNetworking setAllowRequestDefaultArgument:YES]; | 66 | [CNLiveNetworking setAllowRequestDefaultArgument:YES]; |
| 67 | [CNLiveNetworking setResponseSerializerType:CNLiveResponseSerializerJSON]; | 67 | [CNLiveNetworking setResponseSerializerType:CNLiveResponseSerializerJSON]; |
| 68 | + | ||
| 69 | + CNUserShareModel.faceUrl = @"http://yweb0.cnliveimg.com/images/headImg/2019/1211/1576034177571_small.jpg"; | ||
| 70 | + CNUserShareModel.nickname = @""; | ||
| 71 | + CNUserShareModel.mobile = @"15027621766"; | ||
| 72 | + CNUserShareModel.uid = @"10514578"; | ||
| 68 | 73 | ||
| 69 | } | 74 | } |
| 70 | - (NSString *)appUUIDString | 75 | - (NSString *)appUUIDString |