Exemplo n.º 1
0
        public SendNotificationCommand SendNotificationAboutMessage(MessageSetup message)
        {
            var command = new SendNotificationCommand();

            command.Message = message;
            return(command);
        }
Exemplo n.º 2
0
 public MessagePageVm(IMediator mediator, IMapper mapper)
 {
     this._mediator = mediator;
     this._mapper   = mapper;
     this.isLoaded  = false;
     Offices        = new List <Office>();
     Users          = new List <ApplicationUser>();
     MessageSetup   = new MessageSetup();
 }
Exemplo n.º 3
0
        public async Task <BaseResult> SendMessage()
        {
            foreach (var user in Users)
            {
                await SaveMessageForEachUser(user);
            }

            await _mediator.Send(_mediator.Notifications().SendNotificationAboutMessage(MessageSetup));

            MessageSetup = new MessageSetup();
            return(new BaseResult());
        }
 public void NewMessages(MessageSetup message)
 {
     Event_MessageSent.Raise(message, new EventArgs());
 }