From 10868018fb0143746ab767879cd1a57d3dee8d0b Mon Sep 17 00:00:00 2001 From: Derek Holloway Date: Thu, 7 Aug 2025 23:22:53 -0700 Subject: [PATCH] Update to use Auth.Mistox.Com --- .vscode/tasks.json | 1 + database/mistox.sql | 39 --- src/MistoxWebsite.Client/src/app/app.html | 17 +- .../src/app/app.routes.ts | 21 +- src/MistoxWebsite.Client/src/app/app.ts | 35 ++- .../src/app/models/Account.ts | 14 +- .../src/app/models/Product.ts | 2 +- .../src/app/models/WebsiteData.ts | 2 +- .../forgotpassword.component.html | 23 -- .../forgotpassword.component.ts | 55 ---- .../pages/account/login/login.component.html | 35 --- .../pages/account/login/login.component.ts | 57 ---- .../account/logout/logout.component.html | 0 .../pages/account/logout/logout.component.ts | 27 -- .../account/register/register.component.html | 35 --- .../account/register/register.component.ts | 85 ----- .../resetpassword.component.html | 29 -- .../resetpassword/resetpassword.component.ts | 69 ---- .../account/settings/settings.component.html | 0 .../account/settings/settings.component.ts | 29 -- .../verifyemail/verifyemail.component.html | 8 - .../verifyemail/verifyemail.component.ts | 54 ---- .../pages/legal/about/about.component.html | 28 -- .../app/pages/legal/about/about.component.ts | 19 -- .../store/admin/edititem/edit.component.ts | 4 +- .../store/admin/newitem/new.component.ts | 2 +- .../store/catalog/catalog.component.html | 6 +- .../src/app/services/Authentication.ts | 61 +--- .../Controllers/AuthenticationController.cs | 294 ++---------------- .../Controllers/MistoxControllerBase.cs | 31 +- .../Controllers/ProductController.cs | 4 +- .../Entities/DatabaseObjects.cs | 10 +- .../MistoxWebsite.Server.csproj | 1 + src/MistoxWebsite.Server/Program.cs | 110 ++++++- .../Services/DatabaseService/Account.cs | 160 ---------- 35 files changed, 216 insertions(+), 1151 deletions(-) delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/forgotpassword/forgotpassword.component.html delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/forgotpassword/forgotpassword.component.ts delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/login/login.component.html delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/login/login.component.ts delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/logout/logout.component.html delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/logout/logout.component.ts delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/register/register.component.html delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/register/register.component.ts delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/resetpassword/resetpassword.component.html delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/resetpassword/resetpassword.component.ts delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/settings/settings.component.html delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/settings/settings.component.ts delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/verifyemail/verifyemail.component.html delete mode 100644 src/MistoxWebsite.Client/src/app/pages/account/verifyemail/verifyemail.component.ts delete mode 100644 src/MistoxWebsite.Client/src/app/pages/legal/about/about.component.html delete mode 100644 src/MistoxWebsite.Client/src/app/pages/legal/about/about.component.ts delete mode 100755 src/MistoxWebsite.Server/Services/DatabaseService/Account.cs diff --git a/.vscode/tasks.json b/.vscode/tasks.json index f10308d..a0ae14b 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -22,6 +22,7 @@ }, "args": [ "build", + "--configuration=development", "--base-href=http://localhost:5000" ], "problemMatcher": "$msCompile" diff --git a/database/mistox.sql b/database/mistox.sql index cb19208..fff0eef 100755 --- a/database/mistox.sql +++ b/database/mistox.sql @@ -1,20 +1,6 @@ CREATE DATABASE IF NOT EXISTS `mistox`; USE `mistox`; -CREATE TABLE IF NOT EXISTS `Account` ( - `ID` int(11) NOT NULL AUTO_INCREMENT, - `UserName` varchar(60) DEFAULT NULL, - `Email` varchar(60) DEFAULT NULL, - `EmailVerified` tinyint(4) DEFAULT NULL, - `PasswordHash` varchar(100) DEFAULT NULL, - `FailedPasswordLock` tinyint(4) DEFAULT NULL, - `PasswordAttempts` int(11) DEFAULT NULL, - `CurrentPasswordAttempts` int(11) DEFAULT NULL, - `Role` varchar(45) DEFAULT NULL, - `EmailToken` varchar(45) DEFAULT NULL, - PRIMARY KEY (`ID`) -) AUTO_INCREMENT=1; - CREATE TABLE IF NOT EXISTS `Product` ( `ID` int(11) NOT NULL AUTO_INCREMENT, `Name` varchar(45) DEFAULT NULL, @@ -60,29 +46,4 @@ CREATE TABLE IF NOT EXISTS `Receipt` ( `TaxAmount` int(11) DEFAULT NULL, `TotalCost` int(11) DEFAULT NULL, PRIMARY KEY (`AccountID`,`ProductID`,`ReceiptID`) -); - -INSERT INTO Account ( - ID, - UserName, - Email, - EmailVerified, - PasswordHash, - FailedPasswordLock, - PasswordAttempts, - CurrentPasswordAttempts, - Role, - EmailToken -) VALUES ( - 1, - 'admin', - 'admin@mistox.com', - 1, - '$2a$11$0UeWLLqTXe3FG161QVuI0OQJ9rulspUpMG581DI6KSzDXBbFKd00S', - 1, - 1, - 5, - 0, - 'Admin', - '' ); \ No newline at end of file diff --git a/src/MistoxWebsite.Client/src/app/app.html b/src/MistoxWebsite.Client/src/app/app.html index 7834107..ad13f46 100644 --- a/src/MistoxWebsite.Client/src/app/app.html +++ b/src/MistoxWebsite.Client/src/app/app.html @@ -41,13 +41,18 @@