public static RestaurantReviewsLibrary.Review ReviewDataToObject(RestaurantReviewsData.Review data) { var libModel = new RestaurantReviewsLibrary.Review() { RestaurantID = data.ID, ReviewerName = data.reviewerName, ReviewText = data.reviewText, ReviewScore = (float)data.reviewScore }; return(libModel); }
public static RestaurantReviewsData.Review ReviewOjectToData(RestaurantReviewsLibrary.Review obj) { var dataModel = new RestaurantReviewsData.Review() { restaurantID = obj.RestaurantID, reviewerName = obj.ReviewerName, reviewText = obj.ReviewText, reviewScore = obj.ReviewScore }; return(dataModel); }