Project 1 - 1811-nov27-net/training-code GitHub Wiki

project 1: pizza store application

November 27 2018 Arlington .NET / Nick Escalona

functionality

  • place pizza order to a location for a user
  • get a suggested order for a user based on his order history
  • search users by name
  • display details of an order
  • display all order history of a location
  • display all order history of a user
  • display order history sorted by earliest, latest, cheapest, most expensive

structure

data access

  • Entity Framework dbcontext and the models in its dbsets should be here
  • repository implementations should be here

class library

  • all business logic should be here
  • use repository pattern to abstract data access in terms of the class library models
  • repository interfaces should be here

user interface

  • ASP.NET MVC web application
  • keep business logic out of this project
  • keep display logic out of the views and in the controllers or other classes
  • client-side validation
  • server-side validation
  • customize the default styling to some extent

unit test

  • use TDD for some of the application
  • focus on unit testing class library, testing the console app is very low priority

object model

user

  • has first name, last name, etc.
  • has a default location to order from
  • cannot place more than one order from the same location within two hours

order

  • has a location
  • has a user
  • has an order time (when the order was placed)
  • can have at most 12 pizzas
  • total value cannot exceed $500

location

  • has an inventory of pizza ingredients
  • inventory decreases when orders are accepted
  • rejects orders that cannot be fulfilled with remaining inventory
  • has order history

pizza

technologies

  • C#/.NET
  • Entity Framework
  • ASP.NET MVC
  • xUnit, NUnit, or MSTest
  • Serilog or NLog