New some function
This commit is contained in:
@@ -333,6 +333,38 @@ class GroupManager {
|
||||
'operationID': Utils.checkOperationID(operationID),
|
||||
}));
|
||||
|
||||
/// Enable group mute
|
||||
/// 开启群禁言
|
||||
Future<dynamic> changeGroupMute({
|
||||
required String groupID,
|
||||
required bool mute,
|
||||
String? operationID,
|
||||
}) =>
|
||||
_channel.invokeMethod(
|
||||
'changeGroupMute',
|
||||
_buildParam({
|
||||
'gid': groupID,
|
||||
'mute': mute,
|
||||
'operationID': Utils.checkOperationID(operationID),
|
||||
}));
|
||||
|
||||
/// Mute group members
|
||||
/// 禁言群成员
|
||||
Future<dynamic> changeGroupMemberMute({
|
||||
required String groupID,
|
||||
required String userID,
|
||||
int seconds = 0,
|
||||
String? operationID,
|
||||
}) =>
|
||||
_channel.invokeMethod(
|
||||
'changeGroupMemberMute',
|
||||
_buildParam({
|
||||
'gid': groupID,
|
||||
'uid': userID,
|
||||
'seconds': seconds,
|
||||
'operationID': Utils.checkOperationID(operationID),
|
||||
}));
|
||||
|
||||
static Map _buildParam(Map param) {
|
||||
param["ManagerName"] = "groupManager";
|
||||
return param;
|
||||
|
||||
Reference in New Issue
Block a user