public Task <IEnumerable <GetVentilatorModelsQueryResult> > Execute(GetVentilatorModelsQuery query)
 {
     return(Task.FromResult(_ventilatorRepsoitory.AllVentilatorModels.Select(v => new GetVentilatorModelsQueryResult
     {
         Id = v.Id,
         ProductionYear = v.ProductionYear,
         Name = v.Name
     })));
 }
Beispiel #2
0
        public async Task <IEnumerable <GetVentilatorModelsQueryResult> > Handle(GetVentilatorModelsQuery query, CancellationToken cancellationToken)
        {
            var result = await _queryExecutor.Execute(query);

            return(result);
        }