Exemplo n.º 1
0
        public async Task <ActionResult <IEnumerable <SessionDto> > > GetAllSessionsAsync()
        {
            var request = new GetAllSessionsRequest();

            var response = await _mediator.Send(request);

            return(Ok(response.Select(s => _mapper.Map <SessionDto>(s))));
        }
Exemplo n.º 2
0
 public Task <IEnumerable <Session> > Handle(GetAllSessionsRequest request, CancellationToken cancellationToken)
 {
     return(_mediaServerApi.GetAllSessionsAsync());
 }