getMessageReceiptDetails method
Implementation
void getMessageReceiptDetails({
@required dynamic target, /// (JMSingle | JMGroup)
@required String msgId,
@required JMCallback callback,
}) async {
print(flutterLog + "getMessageUnreceiptCount" + " msgid = $msgId");
if (msgId == null || msgId.length == 0 || target == null) {
callback(null,null);
return ;
}
Map param = target.toJson();
param["id"] = msgId;
Map resultMap = await _channel.invokeMethod('getMessageReceiptDetails', param..removeWhere((key,value) => value == null));
if (resultMap != null) {
List receiptJosnList = resultMap["receiptList"];
List unreceiptJosnList = resultMap["unreceiptList"];
List<JMUserInfo> receiptUserList = receiptJosnList.map((json) => JMUserInfo.fromJson(json)).toList();
List<JMUserInfo> unreceiptUserList = unreceiptJosnList.map((json) => JMUserInfo.fromJson(json)).toList();
callback(receiptUserList,unreceiptUserList);
}else{
callback(null,null);
}
}