예제 #1
0
        public IActionResult GetByName(string name)
        {
            var colors   = ColorsRepository.Get();
            var response = colors.Where(x => x.Name.ToLower() == name.ToLower()).FirstOrDefault();

            return(Ok(response));
        }
예제 #2
0
        public IActionResult GetAllColors()
        {
            var colors = ColorsRepository.Get();

            return(Ok(colors));
        }