public static RestaurantReviewBusinessLayer.Restaurant ToData(Restaurant webRestaurant) { var dataRestaurant = new RestaurantReviewBusinessLayer.Restaurant() { Id = webRestaurant.Id, Name = webRestaurant.Name, Address = webRestaurant.Address }; return(dataRestaurant); }
private static Restaurant ToWeb(RestaurantReviewBusinessLayer.Restaurant rest) { Restaurant r = new Restaurant { Id = rest.Id, Name = rest.Name, Address = rest.Address, AvgRating = rest.AvgRating, }; return(r); }