diff --git a/CHANGELOG.md b/CHANGELOG.md index fb7a1a4cd..bd638c5c3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,26 @@ This file documents all notable changes made to ITFlow. +## [26.09.1] Maint Release + +### Upgrading to 26.09.1 + +Update from Maintenance > Update — Queue Update hands the job to cron and it applies on its own. There is no database change in this release, so nothing else is required. + +### Breaking Changes and Notes + +- API: a contact must be archived before the delete endpoint will remove it. Deleting an active contact is refused and reports nothing deleted, so archive it first and then delete. Thanks to @Wrongecho. + +### Bug Fixes + +- Assets: IP address fields demanded all three digits of every octet, so `10.0.0.1` had to be entered as `010.000.000.001`. They take natural input again, and a field holding DHCP is now left alone rather than being emptied the moment the modal opens. +- Networks: in the IP list, an empty hostname or description shows a dash rather than a blank cell, the column headings match the rest of the app, and the table is tighter so more addresses fit on screen. + +### Developer Updates + +- The IPv4 mask in `js/app.js` is a regex mask rather than four `IMask.MaskedRange` blocks. A pattern mask will not advance past a separator until the current block reaches its `maxLength`, which is what forced the three-digit octets. A regex mask has no per-block completeness rule and tests the whole value on each keystroke, so a partial `10.0.` is valid on its own. Octets are still bounded to 0-255 and leading zeros are still accepted, matching what the old jquery.inputmask `ip` alias allowed. Any value not made purely of digits and dots is skipped, because `interface_ip` and `asset_ip` are `varchar(200)` and also carry the literal `DHCP` written by the checkbox on those same modals. +- Dead display variables removed from the asset, expense and product listings. `$asset_description_display`, `$client_name_display` and `$product_description_display` are folded into `?: '-'` at the point of assignment. + ## [26.09] ### Upgrading to 26.09 diff --git a/agent/assets.php b/agent/assets.php index 3e62841ec..e0d310c87 100644 --- a/agent/assets.php +++ b/agent/assets.php @@ -556,11 +556,6 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()")); $asset_type = escapeHtml($row['asset_type']); $asset_name = escapeHtml($row['asset_name']); $asset_description = escapeHtml($row['asset_description']); - if ($asset_description) { - $asset_description_display = $asset_description; - } else { - $asset_description_display = "-"; - } $asset_make = escapeHtml($row['asset_make']); $asset_model = escapeHtml($row['asset_model']); $asset_serial = escapeHtml($row['asset_serial']); diff --git a/agent/expenses.php b/agent/expenses.php index dee986761..63f82d5e5 100644 --- a/agent/expenses.php +++ b/agent/expenses.php @@ -268,12 +268,7 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()")); $category_name = escapeHtml($row['category_name']); $account_name = escapeHtml($row['account_name']); $expense_account_id = intval($row['expense_account_id']); - $client_name = escapeHtml($row['client_name']); - if(empty($client_name)) { - $client_name_display = "-"; - } else { - $client_name_display = $client_name; - } + $client_name = escapeHtml($row['client_name']) ?: '-'; $expense_client_id = intval($row['expense_client_id']); if (empty($expense_receipt)) { @@ -307,7 +302,7 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()")); - +