createCard method

Future<MsgModel> createCard({
  1. String senderInfo = "",
  2. required String convId,
  3. List<String> atUsers = const [],
  4. required CardContent content,
  5. MsgOptionsModel? options,
  6. required MsgOfflinePushModel offlinePush,
  7. String ext = "",
})

创建名片消息

Implementation

Future<MsgModel> createCard({
  String senderInfo = "",
  required String convId,
  List<String> atUsers = const [],
  required CardContent content,
  MsgOptionsModel? options,
  required MsgOfflinePushModel offlinePush,
  String ext = "",
}) {
  return _sdkManager.createMsg(
    senderInfo: senderInfo,
    convId: convId,
    atUsers: atUsers,
    contentType: MsgContentType.card,
    content: content.toJson(),
    options: options ??
        MsgOptionsModel(
          storageForServer: true,
          storageForClient: true,
          needDecrypt: false,
          offlinePush: true,
          updateConvMsg: true,
          updateUnreadCount: true,
        ),
    offlinePush: offlinePush,
    ext: ext,
  );
}