Permalink
Browse files

1.1 Create Web Application

  • Loading branch information...
Cyricx committed Jul 23, 2015
1 parent 9172bd0 commit 6168937fc90ef65ca34251c3c165805fc7be6264
Showing with 33 additions and 32 deletions.
  1. +33 −32 README.md
View
@@ -3,35 +3,36 @@
This repository is the code to follow the tutorial at
[ChrisByram.com/Blog](http://www.chrisbyram.com/blog/2015/07/26/code-first-ef-with-web-api-2)
## 1: Setup:
1. Create Web Application
## 2: Entity Framework Code First:
1. Install EF and setup Nuget Restore
2. Add Models for Ticket and TicketCategory
3. Add Connection String
4. Add Database Context
## 3: Setup Views:
1. Add Home Controller & Index View
## 4: EntityFramework Controllers
1. Add Ticket Controller & Ticket Category Controller
2. Add navigation
## 5: Data Initializer
1. Add Initializer
2. Define initializer in web.config
3. Add tickets
4. Disable data initialization in web.config
## 6: Migrations
1. Enable Migrations and run update database
2. Uncomment new property in Ticket
3. add-migration ticket-important-property then update database
4. add-migration ticket-important-not-needed then update database
## 7: Web API
1. Add Ticket and TicketCategories api controllers.
2. Switch Web API to use JSON and handle circular reference issue.
3. Create TicketCategoryJsonModel as another way to handle references.
## 1.0 Setup:
* [1.1](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/1.1) Create Web Application
## 2.0 Entity Framework Code First:
* [2.1](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/2.1) Install EF and setup Nuget Restore
* [2.2](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/2.2) Add Models for Ticket and TicketCategory
* [2.3](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/2.3) Add Connection String
* [2.4](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/2.4) Add Database Context
## 3.0 Setup Views:
* [3.1](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/3.1) Add Home Controller & Index View
## 4.0 EntityFramework Controllers
* [4.1](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/4.1) Add Ticket Controller & Ticket Category Controller
* [4.2](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/4.2) Add navigation
## 5.0 Data Initializer
* [5.1](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/5.1) Add Initializer
* [5.2](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/5.2) Define initializer in web.config
* [5.3](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/5.3) Add tickets
* [5.4](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/5.4) Disable data initialization in web.config
## 6.0 Migrations
* [6.1](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/6.1) Enable Migrations and run update database
* [6.2](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/6.2) Uncomment new property in Ticket
* [6.3](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/6.3) add-migration ticket-important-property then update database
* [6.4](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/6.4) add-migration ticket-important-not-needed then update database
## 7.0 Web API
* [7.1](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/7.1) Add Ticket and TicketCategories api controllers.
* [7.2](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/7.2) Switch Web API to use JSON and handle circular reference issue.
* [7.3](https://github.com/Cyricx/CodeFirstWithWebAPI2/releases/tag/7.3) Create TicketCategoryJsonModel as another way to handle references.

0 comments on commit 6168937

Please sign in to comment.