mirror of
https://github.com/itflow-org/itflow
synced 2026-11-22 04:17:24 +00:00
QoL 66: bulk windows that set a location, contact, status or referral require a pick and are marked required, and assigning a location to contacts with none picked asks for one instead of clearing their locations
This commit is contained in:
@@ -232,7 +232,7 @@ Update from Maintenance > Update — Queue Update hands the job to cron, which u
|
||||
- Screen readers: every window's close button is read out as Close, and the arrow beside a list's New button and the ⋮ menus on record pages as More actions, rather than as a button with no name or just More.
|
||||
- Counts: the counts in menus, tabs, list headers and under every list - Showing 1 to 25 of 1,834 records - have a thousands separator, as the dashboard, reports and audit log already did.
|
||||
- Confirmations: archiving a credential from an asset, contact, vendor, service or license page no longer asks first, as archiving anywhere else doesn't - the message's Undo puts it back. Taking a related ticket off a ticket, or a ticket off a service's page, asks first, as the ticket page's other × buttons do. Hints under a few fields - a statement's From, a cron job's schedule, a quote's price per hour - look like every other field's.
|
||||
- Required fields: every field marked * has to be filled in before the window saves, and every field that has to be filled in is marked * - a few had one without the other, such as a credit's note, the comment when merging several tickets, and the dates when activating, renewing or ending a contract. Hints under fields look the same in every window.
|
||||
- Required fields: every field marked * has to be filled in before the window saves, and every field that has to be filled in is marked * - a few had one without the other, such as a credit's note, the comment when merging several tickets, the dates when activating, renewing or ending a contract, and the one choice in the windows that set a location, contact, status or referral on the ticked records. Hints under fields look the same in every window.
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
@@ -298,6 +298,7 @@ Update from Maintenance > Update — Queue Update hands the job to cron, which u
|
||||
- Invoice links: asking to pay by card when card payments weren't set up went to a page that doesn't exist. It goes back to the invoice and says card payments are not set up.
|
||||
- Assets: Bulk Action > Delete deleted the ticked assets straight away, without asking first as every other list's Delete does.
|
||||
- Assets: moving the ticked assets to another client with no client picked moved them to no client at all. It now asks for the client.
|
||||
- Contacts: Assign Location with no location picked took the ticked contacts' location away. It now asks for the location, as the same action on assets does.
|
||||
|
||||
### Developer Updates
|
||||
|
||||
|
||||
@@ -26,10 +26,10 @@ ob_start();
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="mb-3">
|
||||
<label class="form-label">Contact</label>
|
||||
<label class="form-label">Contact <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fas fa-fw fa-user"></i></span>
|
||||
<select class="form-select select2" name="bulk_contact_id">
|
||||
<select class="form-select select2" name="bulk_contact_id" required>
|
||||
<option value="">- Select a contact -</option>
|
||||
<?php
|
||||
|
||||
|
||||
@@ -27,10 +27,10 @@ ob_start();
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="mb-3">
|
||||
<label class="form-label">Location</label>
|
||||
<label class="form-label">Location <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fas fa-fw fa-map-marker-alt"></i></span>
|
||||
<select class="form-select select2" name="bulk_location_id">
|
||||
<select class="form-select select2" name="bulk_location_id" required>
|
||||
<option value="">- Select a location -</option>
|
||||
<?php
|
||||
|
||||
|
||||
@@ -21,10 +21,10 @@ ob_start();
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="mb-3">
|
||||
<label class="form-label">Status</label>
|
||||
<label class="form-label">Status <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fas fa-fw fa-circle"></i></span>
|
||||
<select class="form-select select2" name="bulk_status">
|
||||
<select class="form-select select2" name="bulk_status" required>
|
||||
<option value="">- Select a status -</option>
|
||||
<?= categoryOptionsHtml('asset_status') ?>
|
||||
</select>
|
||||
|
||||
@@ -21,10 +21,10 @@ ob_start();
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="mb-3">
|
||||
<label class="form-label">Referral</label>
|
||||
<label class="form-label">Referral <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fas fa-fw fa-link"></i></span>
|
||||
<select class="form-select select2" name="bulk_referral">
|
||||
<select class="form-select select2" name="bulk_referral" required>
|
||||
<option value="">- Select a referral -</option>
|
||||
<?= categoryOptionsHtml('Referral') ?>
|
||||
</select>
|
||||
|
||||
@@ -25,10 +25,10 @@ ob_start();
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="mb-3">
|
||||
<label class="form-label">Location</label>
|
||||
<label class="form-label">Location <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fas fa-fw fa-map-marker-alt"></i></span>
|
||||
<select class="form-select select2" name="bulk_location_id">
|
||||
<select class="form-select select2" name="bulk_location_id" required>
|
||||
<option value="">- Select a location -</option>
|
||||
<?php
|
||||
|
||||
|
||||
@@ -361,8 +361,12 @@ if (isset($_POST['bulk_assign_contact_location'])) {
|
||||
// Get Location name for logging and Notification
|
||||
$sql = mysqli_query($mysqli,"SELECT location_name, location_client_id FROM locations WHERE location_id = $location_id");
|
||||
$row = mysqli_fetch_assoc($sql);
|
||||
$location_name = escapeSql($row['location_name'] ?? '');
|
||||
$client_id = intval($row['location_client_id'] ?? 0);
|
||||
if (!$row) {
|
||||
flashAlert('Pick a location to move them to.', 'error');
|
||||
redirect();
|
||||
}
|
||||
$location_name = escapeSql($row['location_name']);
|
||||
$client_id = intval($row['location_client_id']);
|
||||
|
||||
enforceClientAccess();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user