Skip navigation

Migrate the index action

Migrate the index action: Migrating from MVC 5 to ASP.NET Core MVC
Migrate the index action: Migrating from MVC 5 to ASP.NET Core MVC

The original Movies controller hard-coded the DbContext as a class level variable, used a simplistic model, and leveraged the ViewBag extensively. The migrated site improves on this by using DI, a more advanced object graph, and View Models. Update the constructor for the Movies controller to accept the two repositories though DI. Then, add in a configuration for AutoMapper. See how to replace the code in the Index action method, and more.

Resume Transcript Auto-Scroll
Skill Level Intermediate
2h 57m
Duration
6,038
Views
Show More Show Less
Skills covered in this course
Web Web Development ASP.NET Core MVC ASP.NET MVC

Continue Assessment

You started this assessment previously and didn't complete it. You can pick up where you left off, or start over.

Start Your Free Trial Now

Start your free trial now, and begin learning software, business and creative skills—anytime, anywhere—with video instruction from recognized industry experts.

Start Your Free Trial Now