コード例 #1
0
        public JsonResult GetComps(string movieId, string maxResults)
        {
            NetflixProvider provider = new NetflixProvider();
            var             response = provider.GetSimilars(movieId, maxResults);

            NetflixParser parser = new NetflixParser();
            var           model  = parser.ParseCompSearch(response);

            return(Json(model));
        }
コード例 #2
0
        public ActionResult Comps(string movieId, string maxResults, string subjectTitle, string subjectReleaseYear)
        {
            NetflixProvider provider = new NetflixProvider();
            var             response = provider.GetSimilars(movieId, maxResults);

            NetflixParser parser = new NetflixParser();
            var           model  = parser.ParseCompSearch(response);

            return(View(new MovieGridModel()
            {
                Movies = model, MaxResults = maxResults, SubjectTitle = subjectTitle, SubjectReleaseYear = subjectReleaseYear
            }));
        }