public async Task <ActionResult <TypesDTO> > GetTypes(string name) { TypesDTO type = await typeBO.getSingleTypeByName(name); if (type == null) { return(NotFound()); } return(type); }
public async Task <ActionResult <TypesDTO> > GetTypes(int id) { TypesDTO type = await typeBO.getSingleTypeById(id); if (type == null) { return(NotFound()); } return(type); }