diff --git a/pages/edititem.php b/pages/edititem.php index 6214083..eeed64f 100644 --- a/pages/edititem.php +++ b/pages/edititem.php @@ -24,32 +24,32 @@ $editing = false; if (!is_empty($VARS['id'])) { if ($database->has('items', ['itemid' => $VARS['id']])) { - $editing = true; - $itemdata = $database->select( - 'items', [ - '[>]categories' => [ - 'catid' => 'catid' - ], - '[>]locations' => [ - 'locid' => 'locid' - ] - ], [ - 'name', - 'code1', - 'code2', - 'text1', - 'text2', - 'text3', - 'items.catid', - 'catname', - 'items.locid', - 'locname', - 'loccode', - 'qty', - 'userid' - ], [ - 'itemid' => $VARS['id'] - ])[0]; + $editing = true; + $itemdata = $database->select( + 'items', [ + '[>]categories' => [ + 'catid' => 'catid' + ], + '[>]locations' => [ + 'locid' => 'locid' + ] + ], [ + 'name', + 'code1', + 'code2', + 'text1', + 'text2', + 'text3', + 'items.catid', + 'catname', + 'items.locid', + 'locname', + 'loccode', + 'qty', + 'userid' + ], [ + 'itemid' => $VARS['id'] + ])[0]; } else { // item id is invalid, redirect to a page that won't cause an error when pressing Save header('Location: app.php?page=edititem'); @@ -101,13 +101,23 @@ if (!is_empty($VARS['id'])) {
- +
+ + + + +
- +
+ + + + +
diff --git a/static/css/app.css b/static/css/app.css index 97fa75b..e07d4d8 100644 --- a/static/css/app.css +++ b/static/css/app.css @@ -70,4 +70,12 @@ to replace the rgba()s. .navbar-header .navbar-brand img { display: none; } +} + +.mobile-app-show { + visibility: hidden; +} + +.mobile-app-display { + display: none; } \ No newline at end of file diff --git a/static/js/items.js b/static/js/items.js index 8d1fe51..52e8d11 100644 --- a/static/js/items.js +++ b/static/js/items.js @@ -1,4 +1,4 @@ -$('#itemtable').DataTable({ +var itemtable = $('#itemtable').DataTable({ responsive: { details: { display: $.fn.dataTable.Responsive.display.modal({ @@ -53,4 +53,6 @@ $('#itemtable').DataTable({ return JSON.stringify(json); } } -}); \ No newline at end of file +}); + +$('#itemtable_filter').append(""); \ No newline at end of file