diff --git a/src/frontend/items.eta.html b/src/frontend/items.eta.html index 0c5efbc..9487ebb 100644 --- a/src/frontend/items.eta.html +++ b/src/frontend/items.eta.html @@ -21,7 +21,7 @@
- <% it.storeLocs.forEach(function(locs){ %> diff --git a/static/js/editItems.js b/static/js/editItems.js index e40c163..61d1e6d 100644 --- a/static/js/editItems.js +++ b/static/js/editItems.js @@ -41,6 +41,7 @@ function getDataForEdit(id) { // Select the correct option in the dropdown const modal_itemCategoryOptions = modal_itemCategory.options; + modal_itemCategoryOptions[0].selected = true; for (let i = 0; i < modal_itemCategoryOptions.length; i++) { if (modal_itemCategoryOptions[i].value == result.categoryId) { modal_itemCategoryOptions[i].selected = true; @@ -49,6 +50,7 @@ function getDataForEdit(id) { // Select the correct option in the dropdown const modal_itemStatusOptions = modal_itemStatus.options; + modal_itemStatusOptions[0].selected = true; for (let i = 0; i < modal_itemStatusOptions.length; i++) { if (modal_itemStatusOptions[i].value == result.statusId) { modal_itemStatusOptions[i].selected = true; @@ -57,6 +59,7 @@ function getDataForEdit(id) { // Select the correct option in the dropdown const modal_itemStorageLocationOptions = modal_itemStorageLocation.options; + modal_itemStorageLocationOptions[0].selected = true; for (let i = 0; i < modal_itemStorageLocationOptions.length; i++) { if (modal_itemStorageLocationOptions[i].value == result.storageLocationId) { modal_itemStorageLocationOptions[i].selected = true;