diff --git a/src/articles.php b/src/articles.php index 69b530c..98e2cb0 100644 --- a/src/articles.php +++ b/src/articles.php @@ -656,7 +656,6 @@ document.addEventListener('DOMContentLoaded', function () { updateBulkUI(); } - const bulkSelectedArticles = new Set(); function updateBulkUI() { const count = bulkSelectedArticles.size; document.getElementById('bulk-selected-count').textContent = count; @@ -690,4 +689,11 @@ document.addEventListener('DOMContentLoaded', function () { }); +rTable(); + }); + + renderTable(); +}); + + \ No newline at end of file diff --git a/src/manage_packing_list_items.php b/src/manage_packing_list_items.php index e9f0e54..a43aacf 100644 --- a/src/manage_packing_list_items.php +++ b/src/manage_packing_list_items.php @@ -282,8 +282,9 @@ $conn->close();
Auf dem Tisch
-
- + + +
@@ -1019,10 +1020,15 @@ $conn->close(); if (button.classList.contains('remove-item-btn')) { const isTable = (itemEl.closest('#table-container') !== null); if (isTable) { - if (confirm('Diesen Artikel wirklich aus der Liste entfernen?')) { + if (!window.deleteItemModalInstance) { + window.deleteItemModalInstance = new bootstrap.Modal(document.getElementById('deleteItemModal')); + } + document.getElementById('btn-delete-confirm').onclick = () => { itemEl.remove(); syncListState(); - } + window.deleteItemModalInstance.hide(); + }; + window.deleteItemModalInstance.show(); } else { itemToRemoveId = itemId; itemToRemoveEl = itemEl; @@ -1090,4 +1096,22 @@ $conn->close(); } + + \ No newline at end of file diff --git a/src/storage_locations.php b/src/storage_locations.php index 5881802..34a7563 100644 --- a/src/storage_locations.php +++ b/src/storage_locations.php @@ -279,13 +279,34 @@ document.addEventListener('DOMContentLoaded', function() { }); } }); + +function showBarcode(token, name) { + const baseUrl = window.location.origin + window.location.pathname.replace('storage_locations.php', 'public_location.php?token='); + const url = baseUrl + token; + document.getElementById('barcodeLocationName').textContent = name; + document.getElementById('barcodeImage').src = 'https://bwipjs-api.metafloor.com/?bcid=code128&text=' + encodeURIComponent(url) + '&scale=2&includetext=false'; + document.getElementById('barcodeLink').href = url; + new bootstrap.Modal(document.getElementById('barcodeModal')).show(); +} - -ationName; - }); - } -}); - +