This restaurant system made via C# Web Api (.Net Framework 4.7.2), Angular (8) with Database in MSSQL allows the user to
- Add new ingredients
- Update Ingredient name and price
- Delete them
- Multiple Ingredients can be selected from the multi select list and given a recipe name to store it in the database.
- Every recipe is put again in the list of Ingredients as It may be Intermediate Inventory or used as Ingredient in other recipes
- Every Ingredient or recipe can be deleted -The Ingredients of every recipe and Intermediate Ingredient can be updated
- The price is calculated and shown while you select multiple ingredients
- The price can be manually set as well
- Validation of at least 2 Ingredients to make a recipe
- Name of recipe or ingredient while updating or creating must not be empty
The C# Web Api Project AfinitiAssignment folder has its files and the angular app in AfinitInsightFrontEnd folder.
-
Visual Studio must be installed with .Net Framework 4.7.2
-
Now open the AfinitiAssignment.sln from the folder AfinitAssignment in Visual Studio
-
Right Click on the Solution In Visual Studio and Click Restore Nuget Packages to get any missing packages.
-
NodeJS must be installed.
-
Use the NPM Node package manager in Terminal/Powershell or Command Prompt to install angular
npm install -g @angular/cli
- Go to the AfinitInsightFrontEnd folder and must run
npm install
to install any missing modules
-
Microsft SQL Management Studio 14 or later must be installed
-
Restore the database file Afinit Database.bak from the Afinit Assignment folder. How to Restore
-
In Visual Studio open Web.Config and modify the connection data source part ( .\SQLEXPRESS ) to the name of your SQL Server. Setting up Conenection Strings
- In Visual Studio click start or press f5 to run the web api
- Now from the folder AfinitInsightFrontEnd in Terminal or Command prompt run
ng serve
to start the Angular app and open localhost:4200 in any browser.
- That is it!
- IngredientsController.cs
- RecipesController.cs
- Models Folder all files.
- ingredient.component.ts
- ingredient.component.html
- ingredient.service.ts
- recipe.services.ts
- api.service.ts