From f249a4552c27c194b5bc96bcde0b9e7cc24755ea Mon Sep 17 00:00:00 2001 From: Spacelord Date: Tue, 6 Jun 2023 23:49:16 +0200 Subject: [PATCH] Frontend update --- src/frontend/dashboard.eta.html | 4 +- src/frontend/items.eta.html | 24 ++++--- src/frontend/partials/controls.eta.html | 11 ++- src/frontend/partials/controlsFoot.eta.html | 6 +- src/frontend/partials/deleteModal.eta.html | 2 +- static/css/dashboard.css | 3 +- static/js/editItems.js | 77 +++++++++++++++++++++ static/js/formHandler.js | 3 +- static/js/searchBox.js | 4 +- 9 files changed, 119 insertions(+), 15 deletions(-) create mode 100644 static/js/editItems.js diff --git a/src/frontend/dashboard.eta.html b/src/frontend/dashboard.eta.html index 71074cb..ee5aa54 100644 --- a/src/frontend/dashboard.eta.html +++ b/src/frontend/dashboard.eta.html @@ -38,7 +38,9 @@ <% it.recents.forEach(function(user){ %> - <%= user.SKU %> + <% if (user.SKU == null) { %> + No SKU assigned + <% } else { %> <%= user.SKU %> <% } %> <%= user.name %> <% if(user.status == "normal") { %> diff --git a/src/frontend/items.eta.html b/src/frontend/items.eta.html index 7990d54..b7562d0 100644 --- a/src/frontend/items.eta.html +++ b/src/frontend/items.eta.html @@ -1,4 +1,4 @@ -<%~ E.includeFile("partials/head.eta.html", {"title": "Items"}) %> <%~ E.includeFile("partials/controls.eta.html", {"active": "Items"}) %> +<%~ E.includeFile("partials/head.eta.html", {"title": "Items"}) %> <%~ E.includeFile("partials/controls.eta.html", {"active": "Items"}) %> <%~ E.includeFile("./partials/deleteModal.eta.html") %> - + <%~ E.includeFile("partials/controlsFoot.eta.html") %> <%~ E.includeFile("partials/foot.eta.html") %> diff --git a/src/frontend/partials/controls.eta.html b/src/frontend/partials/controls.eta.html index 4e78b04..49004b7 100644 --- a/src/frontend/partials/controls.eta.html +++ b/src/frontend/partials/controls.eta.html @@ -14,7 +14,7 @@ @@ -28,6 +28,15 @@ +
+ +
+
- \ No newline at end of file + + \ No newline at end of file diff --git a/src/frontend/partials/deleteModal.eta.html b/src/frontend/partials/deleteModal.eta.html index d4ad5a5..22ed8bb 100644 --- a/src/frontend/partials/deleteModal.eta.html +++ b/src/frontend/partials/deleteModal.eta.html @@ -3,7 +3,7 @@