public virtual ChatMessageInfo BuildChatParticipantInvitedMessage(IChatParticipantInvitedEvent <ChatParticipant> @event) { return(new ChatMessageInfo(MessageType.ChatRef, 0, style: MessageStyle("ParticipantInvited"), contacts: new List <ContactMessage>() { new ContactMessage(@event.Participant) })); }
public virtual async Task Handle(IChatParticipantInvitedEvent <TChatParticipant> @event, IChatBusContext chatBusContext) { if (ChatWorkersConfiguration.DisableSystemMessages) { return; } var messageInfo = SystemMessagesBuilder.BuildChatParticipantInvitedMessage(@event); await AddMessage(@event, messageInfo, chatBusContext); }
public virtual IChatParticipantInvitedNotification <ChatParticipant> BuildChatParticipantInvitedNotification(IChatParticipantInvitedEvent <ChatParticipant> @event) { return(new ChatParticipantInvitedNotification(@event.InitiatorUserId, @event.ChatId, @event.Participant)); }
public virtual async Task Handle(IChatParticipantInvitedEvent <TChatParticipant> @event, IChatBusContext chatBusContext) { var notification = ChatParticipantsNotificationBuilder.BuildChatParticipantInvitedNotification(@event); await Notify(@event.ChatId, notification); }