Commit d316844566c42ef3cfef6d680e99845e007285f1

Authored by daojian
1 parent e75edadd

0.2.5 版本,云测bug修改

CNLiveNewIMAManagerKit.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 = 'CNLiveNewIMAManagerKit' 10 s.name = 'CNLiveNewIMAManagerKit'
11 - s.version = '0.2.4' 11 + s.version = '0.2.5'
12 s.summary = 'A short description of CNLiveNewIMAManagerKit.' 12 s.summary = 'A short description of CNLiveNewIMAManagerKit.'
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.
CNLiveNewIMAManagerKit/Classes/Playform/IMAContactManager.m
@@ -64,6 +64,7 @@ @@ -64,6 +64,7 @@
64 [self.friendsList removeAllObjects]; 64 [self.friendsList removeAllObjects];
65 65
66 for (TIMFriend *friend in list) { 66 for (TIMFriend *friend in list) {
  67 + if ([friend.identifier hasPrefix:@"daren_"]) continue;
67 IMAUser *user = [[IMAUser alloc] initWithUserInfo:friend.profile]; 68 IMAUser *user = [[IMAUser alloc] initWithUserInfo:friend.profile];
68 user.remark = friend.remark; 69 user.remark = friend.remark;
69 NSLog(@"%@",friend.customInfo); 70 NSLog(@"%@",friend.customInfo);
CNLiveNewIMAManagerKit/Classes/Playform/IMAConversationManager.m
@@ -847,6 +847,46 @@ @@ -847,6 +847,46 @@
847 }]; 847 }];
848 848
849 [[NSNotificationCenter defaultCenter] postNotificationName:kIMAMSG_GroupMemberDeleteNotification object:[dic objectForKey:@"deleteGroupMemberData"] userInfo:dic]; 849 [[NSNotificationCenter defaultCenter] postNotificationName:kIMAMSG_GroupMemberDeleteNotification object:[dic objectForKey:@"deleteGroupMemberData"] userInfo:dic];
  850 +
  851 + /**标识是否是管理员退出了群聊*/
  852 + BOOL isExitAdmin = NO;
  853 + /**退出成员的id*/
  854 + NSString *memberId = deleteGroupMemberData[@"toSid"];
  855 +
  856 + for (int i = 0; i < group.adminArray.count; i++) {
  857 + TIMGroupMemberInfo *adminMemberInfo = group.adminArray[i];
  858 + if ([memberId isEqualToString:adminMemberInfo.member]) {
  859 + //说明退出群聊的是管理员
  860 + isExitAdmin = YES;
  861 + [group.adminArray removeObject:adminMemberInfo];
  862 + break;
  863 + }
  864 + }
  865 +
  866 + if (isExitAdmin) {
  867 + [[NSNotificationCenter defaultCenter] postNotificationName:kIMAMSG_updataAdmin object:nil];
  868 + //同步数据库数据
  869 + dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{
  870 + NSMutableArray *array = [[NSMutableArray alloc] init];
  871 + //把所有管理员id保存到h数据库
  872 + for (TIMGroupMemberInfo *memberInfo in group.adminArray) {
  873 + [array addObject:memberInfo.member];
  874 + }
  875 + CNAdiminFMDBManager *manger = [CNAdiminFMDBManager manager];
  876 + if ([manger searchById:group.groupId]) {
  877 + //数据库存在去更新
  878 + CNAdiminObject *obj = [[CNAdiminObject alloc] initWith:group.groupId adiminArray:array];
  879 + [manger updateObject:obj];
  880 + }
  881 + else
  882 + {
  883 + //数据库不存在 插入新数据
  884 + CNAdiminObject *obj = [[CNAdiminObject alloc] initWith:group.groupId adiminArray:array];
  885 + [manger insterObject:obj];
  886 + }
  887 + });
  888 + }
  889 +
850 isBreak = YES; 890 isBreak = YES;
851 } 891 }
852 else if ([dic[@"type"] integerValue] == CustomMsgTypeOrderStatus) 892 else if ([dic[@"type"] integerValue] == CustomMsgTypeOrderStatus)
CNLiveNewIMAManagerKit/Classes/TIMModel/MSG/IMAMsg.h
@@ -186,6 +186,7 @@ typedef NS_ENUM(NSUInteger, CustomMsgType) { @@ -186,6 +186,7 @@ typedef NS_ENUM(NSUInteger, CustomMsgType) {
186 186
187 CustomMsgTypeUGCLivePlayShare = 4005, //UGC直播分享 187 CustomMsgTypeUGCLivePlayShare = 4005, //UGC直播分享
188 CustomMsgTypeUGCLivePlayEnd = 4006, //UGC直播结束 188 CustomMsgTypeUGCLivePlayEnd = 4006, //UGC直播结束
  189 + CustomMsgTypeUGCLiveGoodsListUpate = 4007, //UGC直播间商品列表发生更新
189 CustomMsgTypeScanCodePay = 5001, //扫码支付消息 190 CustomMsgTypeScanCodePay = 5001, //扫码支付消息
190 CustomMsgTypeShareLink = 6001, //分享链接 191 CustomMsgTypeShareLink = 6001, //分享链接
191 192