This repository contains a Proof-Of-Concept (POC) Web Application made for a Final Year Project.
Use the Developer Powershell (Tools -> Command Line -> Developer Powershell) and key in the following commands.
If the "Migrations" folder does not exist:
dotnet tool install --global dotnet-ef
dotnet ef migrations add init --context prmsdbcontext
dotnet ef database update --context prmsdbcontextIf the "Migrations" folder exists:
dotnet tool install --global dotnet-ef
dotnet ef database update --context prmsdbcontextBelow is the seeding data used (Follow the sequence of the tables when entering data):
This folder is used to place functions that requires a lot more handling/will make the code too cluttered. Such as Excel Methods.
This folder is where the object attributes are declared.
Save the File and PRMSDbContext upon changing of any Objects.
Then run
dotnet ef migrations add [version_name] --prmsdbcontextand
dotnet ef database update --prmsdbcontextafter checking against the migration folder
More details on how to use dotnet ef here.
This folder contains all the pages and routing. Layouts are declared in the ViewStart of each folder.
This folder contains all the dotnet ef commands. (Anything related to the database is called and declared here.
22/23 Sem 2 Advice:
The database has flaws for future purposes. Feel free to make changes to:
Item Table such as the Category, domainCategory and setType Columns, break it up into more tables
User Table such as the AccountType Column, change the representation to words or use a separate table and reference as foreign key. Foreign keys can be slightly tricky, refer to the Models and the PRMSDbContext to see how it is declared as it may vary.
More on it here.
For all the Suggestions above, changes will have to be made in the Javascript on certain pages as well, as it was not accounted for prior to minor scope creeps.
*Do make the effort to make these changes as it will make your life easier later on.