update
This commit is contained in:
parent
cce41e0991
commit
2a9d4a0587
@ -1,6 +1,8 @@
|
|||||||
## 2.1.0
|
## 2.1.0
|
||||||
|
|
||||||
1.Fix bug </br>
|
1.Fix bug </br>
|
||||||
|
2.New getGroupMemberListByJoinTime method </br>
|
||||||
|
3.New group message need read count field groupMemberCount </br>
|
||||||
|
|
||||||
## 2.0.9+3
|
## 2.0.9+3
|
||||||
|
|
||||||
|
@ -41,5 +41,5 @@ android {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation 'io.openim:core-sdk:2.0.9.28@aar'
|
implementation 'io.openim:core-sdk:2.1.0.1@aar'
|
||||||
}
|
}
|
@ -18,7 +18,10 @@ class BaseManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static Long int2long(MethodCall methodCall, String key) {
|
static Long int2long(MethodCall methodCall, String key) {
|
||||||
Integer i = value(methodCall, key);
|
Object i = value(methodCall, key);
|
||||||
return Long.valueOf(i);
|
if (i instanceof Long) {
|
||||||
|
return (Long) i;
|
||||||
|
}
|
||||||
|
return Long.valueOf((Integer) i);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -199,4 +199,16 @@ public class GroupManager extends BaseManager {
|
|||||||
int2long(methodCall, "roleLevel")
|
int2long(methodCall, "roleLevel")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void getGroupMemberListByJoinTimeFilter(MethodCall methodCall, MethodChannel.Result result) {
|
||||||
|
Open_im_sdk.getGroupMemberListByJoinTimeFilter(new OnBaseListener(result, methodCall),
|
||||||
|
value(methodCall, "operationID"),
|
||||||
|
value(methodCall, "groupID"),
|
||||||
|
value(methodCall, "offset"),
|
||||||
|
value(methodCall, "count"),
|
||||||
|
int2long(methodCall, "joinTimeBegin"),
|
||||||
|
int2long(methodCall, "joinTimeEnd"),
|
||||||
|
jsonValue(methodCall, "excludeUserIDList")
|
||||||
|
);
|
||||||
|
}
|
||||||
}
|
}
|
@ -457,6 +457,37 @@ class GroupManager {
|
|||||||
'operationID': Utils.checkOperationID(operationID),
|
'operationID': Utils.checkOperationID(operationID),
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
/// Get the list of group members
|
||||||
|
/// 分页获取组成员列表
|
||||||
|
/// [groupID] 群ID
|
||||||
|
/// [joinTimeBegin] 加入开始时间
|
||||||
|
/// [joinTimeEnd] 加入结束时间
|
||||||
|
/// [offset] 开始下标
|
||||||
|
/// [count] 总数
|
||||||
|
Future<List<GroupMembersInfo>> getGroupMemberListByJoinTime({
|
||||||
|
required String groupID,
|
||||||
|
int offset = 0,
|
||||||
|
int count = 0,
|
||||||
|
int joinTimeBegin = 0,
|
||||||
|
int joinTimeEnd = 0,
|
||||||
|
List<String> excludeUserIDList = const [],
|
||||||
|
String? operationID,
|
||||||
|
}) =>
|
||||||
|
_channel
|
||||||
|
.invokeMethod(
|
||||||
|
'getGroupMemberListByJoinTimeFilter',
|
||||||
|
_buildParam({
|
||||||
|
'groupID': groupID,
|
||||||
|
'offset': offset,
|
||||||
|
'count': count,
|
||||||
|
'joinTimeBegin': joinTimeBegin,
|
||||||
|
'joinTimeEnd': joinTimeEnd,
|
||||||
|
'excludeUserIDList': excludeUserIDList,
|
||||||
|
'operationID': Utils.checkOperationID(operationID),
|
||||||
|
}))
|
||||||
|
.then((value) =>
|
||||||
|
Utils.toList(value, (map) => GroupMembersInfo.fromJson(map)));
|
||||||
|
|
||||||
static Map _buildParam(Map param) {
|
static Map _buildParam(Map param) {
|
||||||
param["ManagerName"] = "groupManager";
|
param["ManagerName"] = "groupManager";
|
||||||
return param;
|
return param;
|
||||||
|
@ -639,6 +639,7 @@ class AttachedInfoElem {
|
|||||||
class GroupHasReadInfo {
|
class GroupHasReadInfo {
|
||||||
List<String>? hasReadUserIDList;
|
List<String>? hasReadUserIDList;
|
||||||
int? hasReadCount;
|
int? hasReadCount;
|
||||||
|
int? groupMemberCount;
|
||||||
|
|
||||||
GroupHasReadInfo.fromJson(Map<String, dynamic> json) {
|
GroupHasReadInfo.fromJson(Map<String, dynamic> json) {
|
||||||
if (json['hasReadUserIDList'] == null) {
|
if (json['hasReadUserIDList'] == null) {
|
||||||
@ -647,12 +648,14 @@ class GroupHasReadInfo {
|
|||||||
hasReadUserIDList = (json['hasReadUserIDList'] as List).cast<String>();
|
hasReadUserIDList = (json['hasReadUserIDList'] as List).cast<String>();
|
||||||
}
|
}
|
||||||
hasReadCount = json['hasReadCount'] ?? 0;
|
hasReadCount = json['hasReadCount'] ?? 0;
|
||||||
|
groupMemberCount = json['groupMemberCount'] ?? 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final data = Map<String, dynamic>();
|
final data = Map<String, dynamic>();
|
||||||
data['hasReadUserIDList'] = this.hasReadUserIDList;
|
data['hasReadUserIDList'] = this.hasReadUserIDList;
|
||||||
data['hasReadCount'] = this.hasReadCount;
|
data['hasReadCount'] = this.hasReadCount;
|
||||||
|
data['groupMemberCount'] = this.groupMemberCount;
|
||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user