public ActionResult <IEnumerable <CommandReadDto> > GetCommands() { var commandItems = _repoistory.GetCommands(); return(Ok( _mapper.Map <IEnumerable <CommandReadDto> >(commandItems) )); }
public ActionResult <IEnumerable <CommandReadDTO> > GetAllCommands() { var commandItems = _repository.GetCommands(); if (commandItems != null) { return(Ok(_mapper.Map <IEnumerable <CommandReadDTO> >(commandItems))); } return(NotFound()); }
public ActionResult <IEnumerable <Command> > GetAllCommands() { try { var commondItems = _commanderRepo.GetCommands(); if (commondItems != null) { return(Ok(commondItems)); } return(NotFound()); } catch (System.Exception) { throw; } }
public ActionResult <IEnumerable <CommandReadDTO> > GetAllCommands() { var data = _command_repo.GetCommands(); return(Ok(_mapper.Map <IEnumerable <CommandReadDTO> >(data))); }
// GET: CommanderController public ActionResult Index() { return(View(_repo.GetCommands())); }
public ActionResult <IEnumerable <CommandDto> > GetCommands() { var commands = _repo.GetCommands(); return(Ok(_map.Map <IEnumerable <CommandDto> >(commands))); }
public ActionResult <IEnumerable <Command> > GetAllCommands() { var commands = _commanderRepo.GetCommands(); return(Ok(_mapper.Map <IEnumerable <CommandReadDto> >(commands))); }
public ActionResult <IEnumerable <CommandRest> > GetCommands() => Ok(_repository.GetCommands());