mirror of
https://github.com/itflow-org/itflow
synced 2026-12-01 16:48:59 +00:00
Categories stage 2: every form and Bulk Action window picks a category the same way through categoryPicker and categoryOptionsHtml, in the kind's order with each category's color, icon and description, keeping a record's archived category marked (archived) and a status, type or referral that isn't a category marked (not set up) so saving changes neither; the + beside a category picker is admins only and opens the category window stacked over the form, saving in the background as JSON, picking the new category and leaving the form as it was, with a taken name shown in the window, on every form that picks one including a ticket's quote and invoice, Unbilled Time, payment providers, canned responses, the mileage setting and the Bulk Action windows; stacked windows shade the one underneath; agent/post/category.php removed so the window posts to admin/post.php from any page; typed referrals go through categoryEnsure, taking an existing referral's spelling in any case, matching archived ones and no longer making an empty referral on client add, edit and import; fixes the + reloading the page and losing the form, the quote made from a ticket creating an expense category, and a stray < in the license template type picker; changelog updated
This commit is contained in:
@@ -64,21 +64,9 @@ ob_start();
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-tag"></i></span>
|
||||
<select class="form-select select2" name="type" required>
|
||||
<option value="">- Select Type -</option>
|
||||
<<?php
|
||||
$sql_software_types_select = mysqli_query($mysqli, "
|
||||
SELECT category_name, category_color, category_icon FROM categories
|
||||
WHERE category_type = 'software_type'
|
||||
AND category_archived_at IS NULL
|
||||
ORDER BY category_order ASC, category_name ASC
|
||||
");
|
||||
while ($row = mysqli_fetch_assoc($sql_software_types_select)) {
|
||||
$software_type_select = escapeHtml($row['category_name']);
|
||||
?>
|
||||
<option <?php if($software_type == $software_type_select) { echo "selected"; } ?><?= selectOptionColor($row['category_color'] ?? '', $row['category_icon'] ?? '') ?>>
|
||||
<?= $software_type_select ?>
|
||||
</option>
|
||||
<?php } ?>
|
||||
<?= categoryOptionsHtml('software_type', html_entity_decode($software_type, ENT_QUOTES, 'UTF-8')) ?>
|
||||
</select>
|
||||
<?= categoryAddButtonHtml('software_type', 'btn btn-secondary') ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user