public ActionResult <IEnumerable <CommandReadDto> > GetAllCommands() { var commandList = _repository.GetAllCommands(); if (commandList != null) { return(Ok(_mapper.Map <IEnumerable <CommandReadDto> >(commandList))); } return(NotFound()); }
public ActionResult <IEnumerable <CommandItem> > Get() { var commands = _repository.GetAllCommands(); return(Ok(commands)); }