Exemple #1
0
        private RatingDM Map(RatingSM rating)
        {
            RatingDM video = new RatingDM();

            video.RateId = rating.RateId.ToString();
            video.Rating = rating.Rating;
            return(video);
        }
Exemple #2
0
        private RatingSM Map(RatingDM rating)
        {
            RatingSM video = new RatingSM();

            video.RateId = Convert.ToInt32(rating.RateId);
            video.Rating = rating.Rating;
            return(video);
        }
Exemple #3
0
 public void EditRatingById(RatingSM rating)
 {
     try
     {
         ratingData.EditRatingById(Map(rating));
         logs.LogError("Event ", "User was able to update Rating", "Class:RatingLogic, Method:UpdateRatingByRateId");
     }
     catch (Exception e)
     {
         logs.LogError("Error ", "User was unable to update Rating", "Class:RatingLogic, Method:UpdateRatingByRateId");
     }
 }
Exemple #4
0
        public string GetRating(int id)
        {
            RatingSM rating = Map(ratingData.GetRatingById(id));

            return(rating.Rating);
        }