public ActionResult <IEnumerable <CommandReadDto> > GetAllCommands() { // var commandItems = repository.GetAllCommands(); var mockRepo = new MockCommanderRepo(); var commandItems = mockRepo.GetAllCommands(); var commandReadDtos = mapper.Map <IEnumerable <CommandReadDto> >(commandItems); return(Ok(commandReadDtos)); }
public CommandsController(MockCommanderRepo repository, IMapper mapper) { _repository = repository; _mapper = mapper; }