ASP.Net MVC Quick Start

Build a basic CRUD (Create, Update, Delete) web application with MVC and the Entity Framework in a weekend.

This course is a very quick workshop to take you through the basic actions that will be required for you to create an awesome CRUD web application in just a few hours (you could do it over a weekend very easily) using ASP.Net MVC, the Entity Framework (code-first development approach), and the built-in scaffolding capabilities of ASP.Net MVC.
MVC = Model, View, Controller, and is a well-known and established design pattern. Microsoft has made it extremely easy and convenient to create your web solutions using this pattern. In Microsoft's MVC framework, we find that convention is favored over configuration, so as long as we follow a few simple guidelines, the system will do a lot of the work for us.

We'll also be taking a quick look at how we can use the Entity Framework to easily model and create a database for us. By using the code-first approach, we'll simply create our models and then look at writing a DBContext to store the models. We'll also create an initializer class which will see our database for us, so that we can quickly and easily test our system.

After we've learned about the different aspects of our application, we'll quickly create a controller and use ASP.Net MVC's built-in view and scaffolding generators to easily build our CRUD operations against our database.

Other things we will learn throughout the course involve the use of Git for source control, pushing our repository to BitBucket, and linking an AppHarbor project to BitBucket so that we can get continuous integration setup.

To close out the course, we'll put DataTables.js on our Index view so that we can easily show the data, as well as provide built-in javascript tools that will filter and sort the data for us.

By the end of the course, you'll be familiar with the major working parts of creating an Asp.Net MVC CRUD application and publishing to a public-facing website with a fairly nice and responsive UI. You'll have working knowledge of Models, Views, and Controllers, as well as how they interact to create a functional web application. You'll also be exposed to the Entity Framework and Code First Migrations with use of a SQL Server backend.

The best part is that although all of this information sounds pretty daunting, it's actually quite easy with a majority of the work done for us.

Intended Audience: Anyone who wants to learn Asp.Net MVC

Introduction, Welcome, and Overview
The Job Posting
Installing Visual Studio 2015 Community Edition
Making Sure We Have the Tools We Need
Creating The Project
Change the Folder Structure
Get JQuery
Get Bootstrap
Get a Bootswatch Theme
Get DataTables
Create Site.css
Fix Bundle Config
Fix Layout.cshtml and Run the Application
Git For Windows
Create the Repository
Get an account and push our source to BitBucket
Get an Account at AppHarbor
Link our BitBucket account to AppHarbor
Supplemental Instruction
Create your app on Facebook
Add Facebook Authentication to the project
Register with our Facebook ID
Register using native built-in authentication
Create the database on AppHarbor
Add Release configuration for database settings to point to App Harbor
Setup Test Application On Facebook
Make our AppId and AppSecret pull from web.config
Deploy by checking Changes into Source Control
Fixing Web.Config transforms to point to correct AppId and AppSecret
Restore from Source Control
The Contact Model
Reminder: Check your changes into source control.
Create the Contacts Controller
Looking at the controller views
Review the Views
More Source Control Info
Create the ContactWeb Migrations
Add the ContactWebContext db connection to the web.config.release
Find Our User Id
Seed some data
Add Authentication
Check in and Make sure the changes propagate and work on AppHarbor
Final Fixes for successful deploy
Render Across the Whole Page
Cleaning up the NavBar
Finish Cleaning up our Layout
Index Table Layout and Adding Scripts to Our Views
Adding DataTables to our Index view
The Create View
JQueryUI for DatePicker
The Edit View
The Details and Delete View
Including the Images in the Deploy
How can we make the site better?
Next Steps
Course Wrap-Up

What's included

  • 56 Video Lessons

  • Works on all devices
  • Certificate of completion

Brian Gorman

Instructor