Afulton11 / blog-database

A CIS 560 Databases project using ASP.net core with an SQL database
2 stars 0 forks source link

Website Feature List #10

Open Afulton11 opened 5 years ago

Afulton11 commented 5 years ago

This issue contains a feature list needed for each "page" in the website (updated often)

Key

/

/signin

/signup

/user/{username}

Provided the user exists and is NOT deleted...

User on their own profile

/article/{title}

Update Sql database article constraint Title should be unique for all articles

/category/{category}

/hiscores

?? This entire page may not be added

fenrirmitsuki commented 5 years ago

Okay, I believe I've written procedures for the bulk of what we need (add, update/delete, search) and organized the procedures in the file (so it's easier to browse). If you could, would you take a look at what's there and let me know what else needs to be added?

Afulton11 commented 5 years ago

@fenrirmitsuki I noticed you have 2 have the same procedures for followers: Blog.GetFollowers and your Blog.DisplayArticle query has a GROUP BY clause, but then nothing within it.

Also, you could create a new branch named something like dev-joe or feat-sql-procedures and push to that branch instead. Then, you could create a pull request using Github to merge your branch into dev branch. This way, I could leave a review on it before you commit and make any small changes myself, or point out directly in the code what needs to be fixed before it is pushed to our developer branch.

We still need the following procedures that I could think of:

Something else I noticed too is that on many of your GET procedures you are not checking to see if the entity has already been soft deleted. For example in Blog.GetComments the where clause should be something like

WHERE Com.ArticleID = @ArticleID AND (Com.DeletedAt IS NULL OR Com.DeletedAt > SYSDATETIME())

instead of

WHERE Com.ArticleID = @ArticleID

EDIT: Sorry, comments are the 1 thing that should still exist in the return result even if it is deleted. However, almost everything else needs to be checked of is deleted.