예제 #1
0
        public async Task <ActionResult <TypesDTO> > GetTypes(string name)
        {
            TypesDTO type = await typeBO.getSingleTypeByName(name);

            if (type == null)
            {
                return(NotFound());
            }

            return(type);
        }
예제 #2
0
        public async Task <ActionResult <TypesDTO> > GetTypes(int id)
        {
            TypesDTO type = await typeBO.getSingleTypeById(id);

            if (type == null)
            {
                return(NotFound());
            }

            return(type);
        }