群组成员表添加成员索引和获取2个人共同群组的接口
This commit is contained in:
@@ -170,4 +170,10 @@ public class GroupAdmin {
|
||||
return AdminHttpUtils.httpJsonPost(path, inputUserId, OutputGroupIds.class);
|
||||
}
|
||||
|
||||
public static IMResult<OutputGroupIds> getCommonGroups(String user1, String user2) throws Exception {
|
||||
String path = APIPath.Get_Common_Groups;
|
||||
StringPairPojo intput = new StringPairPojo(user1, user2);
|
||||
return AdminHttpUtils.httpJsonPost(path, intput, OutputGroupIds.class);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -617,6 +617,13 @@ public class Main {
|
||||
System.exit(-1);
|
||||
}
|
||||
|
||||
groupIdsIMResult = GroupAdmin.getCommonGroups("user1", "user2");
|
||||
if (groupIdsIMResult != null && groupIdsIMResult.getErrorCode() == ErrorCode.ERROR_CODE_SUCCESS) {
|
||||
System.out.println("get user common groups success");
|
||||
} else {
|
||||
System.out.println("get user common groups failure");
|
||||
System.exit(-1);
|
||||
}
|
||||
|
||||
//仅专业版支持
|
||||
if (commercialServer) {
|
||||
|
||||
Reference in New Issue
Block a user