mirror of
https://github.com/itflow-org/itflow
synced 2026-12-04 10:09:01 +00:00
Undo: the message after archiving, a move or a bulk change has Undo, which puts it back as it was unless it changed since, and archiving no longer asks first except for clients; covers archiving every kind on Archived with contact roles, document links and a client's recurring invoices, file, document, folder and rack moves, and the bulk changes that set a field on tickets, assets, contacts, clients, projects, invoices, products and IP addresses
This commit is contained in:
@@ -156,6 +156,7 @@ if (isset($_POST['bulk_ip_type'])) {
|
||||
redirect();
|
||||
}
|
||||
|
||||
$undo = undoSnapshot('network_ips', 'ip_id', $_POST['network_ip_ids'] ?? [], ['ip_type'], ''); // for Undo on the message
|
||||
$count = 0;
|
||||
foreach (networkIpsForBulk(2) as $ip_id => $row) {
|
||||
mysqli_query($mysqli, "UPDATE network_ips SET ip_type = '$type' WHERE ip_id = $ip_id");
|
||||
@@ -164,6 +165,7 @@ if (isset($_POST['bulk_ip_type'])) {
|
||||
}
|
||||
|
||||
flashAlert("Made <strong>$count</strong> address" . ($count === 1 ? '' : 'es') . " <strong>" . strtolower(NETWORK_IP_TYPES[$type][3]) . "</strong>");
|
||||
undoOfferChanges($undo, "Type put back on <strong>{n}</strong> address{s}", 'module_support', 2, 'es', '');
|
||||
|
||||
redirect();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user