Ejemplo n.º 1
0
        public CuisineBTO UpdateCuisine(CuisineBTO cuisineBto)
        {
            CuisineDTO cuisine = new CuisineDTO();

            if (cuisineBto != null)
            {
                cuisine = cuisineRepository.Update(cuisineBto.BTOToCuisineDomain().ToDTO());
                return(cuisine?.DTOToCuisineDomain().ToBTO() ?? null);
            }
            return(null);
        }
Ejemplo n.º 2
0
        public CuisineBTO AddCuisine(CuisineBTO cuisineBto)
        {
            CuisineDTO cuisine = new CuisineDTO();

            if (cuisineBto != null)
            {
                cuisine = cuisineRepository.Create(cuisineBto.BTOToCuisineDomain().ToDTO());
                return(cuisine.DTOToCuisineDomain().ToBTO());
            }
            return(null);
        }