Ejemplo n.º 1
0
 public IActionResult GetTop10()
 {
     if (Top10Id == null)
     {
         var res = new Top10Model
         {
             MovieOnTop10      = AdministrationRepository.GetTop10(),
             Top10             = AdministrationRepository.GetTop(),
             Top10s            = AdministrationRepository.GetTop10List(),
             MoviesNotAssigned = AdministrationRepository.GetMoviesNotAssigned()
         };
         return(View(res));
     }
     else
     {
         var res = new Top10Model
         {
             MovieOnTop10      = AdministrationRepository.GetTop10(Top10Id),
             Top10             = AdministrationRepository.GetTop(Top10Id),
             Top10s            = AdministrationRepository.GetTop10List(),
             MoviesNotAssigned = AdministrationRepository.GetMoviesNotAssigned(Top10Id)
         };
         return(View(res));
     }
 }