mirror of
https://github.com/itflow-org/itflow
synced 2026-02-28 19:04:52 +00:00
Updated bulk action js to pass the checkboxe names into the get array this allows the use of multiple checkbox name arrays to be passed at once instead of just selected_ids had to update each bulk model from selected_ids to to the array that was passed. This was important so we could mix files and documents together
This commit is contained in:
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$asset_ids = array_map('intval', $_GET['asset_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($asset_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="asset_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($asset_ids as $asset_id) { ?><input type="hidden" name="asset_ids[]" value="<?= $asset_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
@@ -38,7 +38,7 @@ ob_start();
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
|
||||
|
||||
<div class="col">
|
||||
<div class="form-group">
|
||||
<label>Priority <strong class="text-danger">*</strong></label>
|
||||
|
||||
@@ -3,9 +3,9 @@
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$client_id = intval($_GET['client_id']);
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$asset_ids = array_map('intval', $_GET['asset_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($asset_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -20,7 +20,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="asset_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($asset_ids as $asset_id) { ?><input type="hidden" name="asset_ids[]" value="<?= $asset_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
|
||||
@@ -3,9 +3,9 @@
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$client_id = intval($_GET['client_id']);
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$asset_ids = array_map('intval', $_GET['asset_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($asset_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -20,7 +20,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="asset_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($asset_ids as $asset_id) { ?><input type="hidden" name="asset_ids[]" value="<?= $asset_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$asset_ids = array_map('intval', $_GET['asset_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($asset_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="asset_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($asset_ids as $asset_id) { ?><input type="hidden" name="asset_ids[]" value="<?= $asset_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$asset_ids = array_map('intval', $_GET['asset_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($asset_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="asset_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($asset_ids as $asset_id) { ?><input type="hidden" name="asset_ids[]" value="<?= $asset_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
<input type="hidden" name="remove_tags" value="0">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$asset_ids = array_map('intval', $_GET['asset_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($asset_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="asset_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($asset_ids as $asset_id) { ?><input type="hidden" name="asset_ids[]" value="<?= $asset_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$count = count($selected_ids);
|
||||
$asset_ids = array_map('intval', $_GET['asset_ids'] ?? []);
|
||||
$count = count($asset_ids);
|
||||
|
||||
$client_id = intval($_GET['client_id'] ?? 0);
|
||||
if ($client_id) {
|
||||
@@ -25,7 +25,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="asset_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($asset_ids as $asset_id) { ?><input type="hidden" name="asset_ids[]" value="<?= $asset_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
@@ -39,7 +39,7 @@ ob_start();
|
||||
<option value="">- Select Client -</option>
|
||||
<?php
|
||||
$clients_sql = mysqli_query($mysqli, "SELECT client_id, client_name FROM clients WHERE client_archived_at IS NULL $client_select_query");
|
||||
|
||||
|
||||
while ($row = mysqli_fetch_array($clients_sql)) {
|
||||
$client_id_select = intval($row["client_id"]);
|
||||
$client_name_select = nullable_htmlentities($row["client_name"]);
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$client_ids = array_map('intval', $_GET['client_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($client_ids);
|
||||
|
||||
// Generate the HTML form content using output buffering.
|
||||
ob_start();
|
||||
@@ -20,7 +20,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="client_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($client_ids as $client_id) { ?><input type="hidden" name="client_ids[]" value="<?= $client_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
@@ -34,7 +34,7 @@ ob_start();
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
|
||||
|
||||
<div class="col">
|
||||
<div class="form-group">
|
||||
<label>Priority <strong class="text-danger">*</strong></label>
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$client_ids = array_map('intval', $_GET['client_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($client_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,9 +19,9 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="client_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($client_ids as $client_id) { ?><input type="hidden" name="client_ids[]" value="<?= $client_id ?>"><?php } ?>
|
||||
<input type="hidden" name="bulk_remove_tags" value="0">
|
||||
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group form-check">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$client_ids = array_map('intval', $_GET['client_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($client_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="client_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($client_ids as $client_id) { ?><input type="hidden" name="client_ids[]" value="<?= $client_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$client_ids = array_map('intval', $_GET['client_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($client_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="client_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($client_ids as $client_id) { ?><input type="hidden" name="client_ids[]" value="<?= $client_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$client_ids = array_map('intval', $_GET['client_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($client_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,8 +18,8 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="client_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
|
||||
<?php foreach ($client_ids as $client_id) { ?><input type="hidden" name="client_ids[]" value="<?= $client_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$client_ids = array_map('intval', $_GET['client_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($client_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="client_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($client_ids as $client_id) { ?><input type="hidden" name="client_ids[]" value="<?= $client_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -3,9 +3,9 @@
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$client_id = intval($_GET['client_id']);
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$contact_ids = array_map('intval', $_GET['contact_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($contact_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="contact_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($contact_ids as $contact_id) { ?><input type="hidden" name="contact_ids[]" value="<?= $contact_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$contact_ids = array_map('intval', $_GET['contact_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($contact_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="contact_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($contact_ids as $contact_id) { ?><input type="hidden" name="contact_ids[]" value="<?= $contact_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
<input type="hidden" name="bulk_remove_tags" value="0">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$contact_ids = array_map('intval', $_GET['contact_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($contact_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="contact_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($contact_ids as $contact_id) { ?><input type="hidden" name="contact_ids[]" value="<?= $contact_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
|
||||
<label>Department / Group</label>
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$contact_ids = array_map('intval', $_GET['contact_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($contact_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="contact_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($contact_ids as $contact_id) { ?><input type="hidden" name="contact_ids[]" value="<?= $contact_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
|
||||
<label>Phone</label>
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$contact_ids = array_map('intval', $_GET['contact_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($contact_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="contact_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($contact_ids as $contact_id) { ?><input type="hidden" name="contact_ids[]" value="<?= $contact_id ?>"><?php } ?>
|
||||
<input type="hidden" name="bulk_contact_important" value="0">
|
||||
<input type="hidden" name="bulk_contact_billing" value="0">
|
||||
<input type="hidden" name="bulk_contact_technical" value="0">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$contact_ids = array_map('intval', $_GET['contact_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($contact_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="contact_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($contact_ids as $contact_id) { ?><input type="hidden" name="contact_ids[]" value="<?= $contact_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
|
||||
<label>From Email / Display Name</label>
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$credential_ids = array_map('intval', $_GET['credential_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($credential_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="credential_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($credential_ids as $credential_id) { ?><input type="hidden" name="credential_ids[]" value="<?= $credential_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
<input type="hidden" name="bulk_remove_tags" value="0">
|
||||
|
||||
@@ -64,4 +64,4 @@ ob_start();
|
||||
</form>
|
||||
|
||||
<?php
|
||||
require_once '../../../includes/modal_footer.php';
|
||||
require_once '../../../includes/modal_footer.php';
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$expense_ids = array_map('intval', $_GET['expense_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($expense_ids);
|
||||
|
||||
// Generate the HTML form content using output buffering.
|
||||
ob_start();
|
||||
@@ -13,7 +13,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?> <input type="hidden" name="expense_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($expense_ids as $expense_id) { ?> <input type="hidden" name="expense_ids[]" value="<?= $expense_id ?>"><?php } ?>
|
||||
<div class="modal-body text-center">
|
||||
|
||||
<div class="mb-4" style="text-align: center;">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$expense_ids = array_map('intval', $_GET['expense_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($expense_ids);
|
||||
|
||||
// Generate the HTML form content using output buffering.
|
||||
ob_start();
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?> <input type="hidden" name="expense_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($expense_ids as $expense_id) { ?> <input type="hidden" name="expense_ids[]" value="<?= $expense_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$expense_ids = array_map('intval', $_GET['expense_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($expense_ids);
|
||||
|
||||
// Generate the HTML form content using output buffering.
|
||||
ob_start();
|
||||
@@ -21,8 +21,8 @@ ob_start();
|
||||
<div class="modal-body">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php
|
||||
foreach ($selected_ids as $id) { ?>
|
||||
<input type="hidden" name="expense_ids[]" value="<?= $id ?>">
|
||||
foreach ($expense_ids as $expense_id) { ?>
|
||||
<input type="hidden" name="expense_ids[]" value="<?= $expense_id ?>">
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$expense_ids = array_map('intval', $_GET['expense_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($expense_ids);
|
||||
|
||||
// Generate the HTML form content using output buffering.
|
||||
ob_start();
|
||||
@@ -19,9 +19,9 @@ ob_start();
|
||||
</div>
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
|
||||
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?> <input type="hidden" name="expense_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($expense_ids as $expense_id) { ?> <input type="hidden" name="expense_ids[]" value="<?= $expense_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -2,17 +2,26 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$client_id = intval($_GET['client_id']);
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$client_id = intval($_GET['client_id'] ?? 0);
|
||||
$current_folder_id = intval($_GET['current_folder_id'] ?? 0);
|
||||
|
||||
$count = count($selected_ids);
|
||||
// Selected IDs from JS (may be empty arrays)
|
||||
$file_ids = array_map('intval', $_GET['file_ids'] ?? []);
|
||||
$document_ids = array_map('intval', $_GET['document_ids'] ?? []);
|
||||
|
||||
$count_files = count($file_ids);
|
||||
$count_docs = count($document_ids);
|
||||
$total = $count_files + $count_docs;
|
||||
|
||||
ob_start();
|
||||
|
||||
?>
|
||||
|
||||
<div class="modal-header bg-dark">
|
||||
<h5 class="modal-title"><i class="fa fa-fw fa-exchange-alt mr-2"></i>Move <strong><?= $count ?></strong> Files</h5>
|
||||
<h5 class="modal-title">
|
||||
<i class="fa fa-fw fa-exchange-alt mr-2"></i>
|
||||
Move <strong><?= $total ?></strong> Item<?= $total === 1 ? '' : 's' ?>
|
||||
</h5>
|
||||
<button type="button" class="close text-white" data-dismiss="modal">
|
||||
<span>×</span>
|
||||
</button>
|
||||
@@ -20,10 +29,22 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="file_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
|
||||
<?php foreach ($file_ids as $id): ?>
|
||||
<input type="hidden" name="file_ids[]" value="<?= $id ?>">
|
||||
<?php endforeach; ?>
|
||||
|
||||
<?php foreach ($document_ids as $id): ?>
|
||||
<input type="hidden" name="document_ids[]" value="<?= $id ?>">
|
||||
<?php endforeach; ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
<p>
|
||||
Files: <strong><?= $count_files ?></strong><br>
|
||||
Documents: <strong><?= $count_docs ?></strong>
|
||||
</p>
|
||||
|
||||
<div class="form-group">
|
||||
<label>Target Folder</label>
|
||||
<div class="input-group">
|
||||
@@ -32,75 +53,81 @@ ob_start();
|
||||
</div>
|
||||
<select class="form-control select2" name="bulk_folder_id">
|
||||
<option value="0">/</option>
|
||||
<?php
|
||||
// Fetch all folders for the client
|
||||
$sql_all_folders = mysqli_query($mysqli, "SELECT folder_id, folder_name, parent_folder FROM folders WHERE folder_location = 1 AND folder_client_id = $client_id ORDER BY folder_name ASC");
|
||||
$folders = array();
|
||||
<?php
|
||||
// NOTE: folder_location is gone now, so just use folder_client_id
|
||||
$sql_all_folders = mysqli_query(
|
||||
$mysqli,
|
||||
"SELECT folder_id, folder_name, parent_folder
|
||||
FROM folders
|
||||
WHERE folder_client_id = $client_id
|
||||
ORDER BY folder_name ASC"
|
||||
);
|
||||
|
||||
// Build an associative array of folders indexed by folder_id
|
||||
while ($row = mysqli_fetch_assoc($sql_all_folders)) {
|
||||
$folders[$row['folder_id']] = array(
|
||||
'folder_id' => intval($row['folder_id']),
|
||||
'folder_name' => nullable_htmlentities($row['folder_name']),
|
||||
'parent_folder' => intval($row['parent_folder']),
|
||||
'children' => array()
|
||||
);
|
||||
$folders = [];
|
||||
|
||||
while ($row = mysqli_fetch_assoc($sql_all_folders)) {
|
||||
$folders[$row['folder_id']] = [
|
||||
'folder_id' => (int)$row['folder_id'],
|
||||
'folder_name' => nullable_htmlentities($row['folder_name']),
|
||||
'parent_folder'=> (int)$row['parent_folder'],
|
||||
'children' => []
|
||||
];
|
||||
}
|
||||
|
||||
// Build hierarchy
|
||||
foreach ($folders as $id => &$folder) {
|
||||
if ($folder['parent_folder'] != 0 && isset($folders[$folder['parent_folder']])) {
|
||||
$folders[$folder['parent_folder']]['children'][] = &$folder;
|
||||
}
|
||||
}
|
||||
unset($folder);
|
||||
|
||||
// Build the folder hierarchy
|
||||
foreach ($folders as $id => &$folder) {
|
||||
if ($folder['parent_folder'] != 0 && isset($folders[$folder['parent_folder']])) {
|
||||
$folders[$folder['parent_folder']]['children'][] = &$folder;
|
||||
$root_folders = [];
|
||||
foreach ($folders as $id => $folder) {
|
||||
if ($folder['parent_folder'] == 0) {
|
||||
$root_folders[] = $folder;
|
||||
}
|
||||
}
|
||||
|
||||
// Optional: if you want to default-select current folder, pass it in GET
|
||||
$current_folder_id = intval($_GET['current_folder_id'] ?? 0);
|
||||
|
||||
$stack = [];
|
||||
foreach (array_reverse($root_folders) as $folder) {
|
||||
$stack[] = ['folder' => $folder, 'level' => 0];
|
||||
}
|
||||
|
||||
while (!empty($stack)) {
|
||||
$node = array_pop($stack);
|
||||
$folder = $node['folder'];
|
||||
$level = $node['level'];
|
||||
|
||||
$indentation = str_repeat(' ', $level * 4);
|
||||
|
||||
$selected = ($folder['folder_id'] === $current_folder_id) ? 'selected' : '';
|
||||
|
||||
echo "<option value=\"{$folder['folder_id']}\" $selected>$indentation{$folder['folder_name']}</option>";
|
||||
|
||||
if (!empty($folder['children'])) {
|
||||
foreach (array_reverse($folder['children']) as $child) {
|
||||
$stack[] = ['folder' => $child, 'level' => $level + 1];
|
||||
}
|
||||
}
|
||||
unset($folder); // Break the reference
|
||||
|
||||
// Prepare a list of root folders
|
||||
$root_folders = array();
|
||||
foreach ($folders as $id => $folder) {
|
||||
if ($folder['parent_folder'] == 0) {
|
||||
$root_folders[] = $folder;
|
||||
}
|
||||
}
|
||||
|
||||
// Display the folder options iteratively
|
||||
$stack = array();
|
||||
foreach (array_reverse($root_folders) as $folder) {
|
||||
$stack[] = array('folder' => $folder, 'level' => 0);
|
||||
}
|
||||
|
||||
while (!empty($stack)) {
|
||||
$node = array_pop($stack);
|
||||
$folder = $node['folder'];
|
||||
$level = $node['level'];
|
||||
|
||||
// Indentation for subfolders
|
||||
$indentation = str_repeat(' ', $level * 4);
|
||||
|
||||
// Check if this folder is selected
|
||||
$selected = '';
|
||||
if ($folder['folder_id'] == $get_folder_id) {
|
||||
$selected = 'selected';
|
||||
}
|
||||
|
||||
echo "<option value=\"{$folder['folder_id']}\" $selected>$indentation{$folder['folder_name']}</option>";
|
||||
|
||||
// Add children to the stack
|
||||
if (!empty($folder['children'])) {
|
||||
foreach (array_reverse($folder['children']) as $child_folder) {
|
||||
$stack[] = array('folder' => $child_folder, 'level' => $level + 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
}
|
||||
?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="modal-footer">
|
||||
<button type="submit" name="bulk_move_files" class="btn btn-primary text-bold"><i class="fa fa-check mr-2"></i>Move Files</button>
|
||||
<button type="button" class="btn btn-light" data-dismiss="modal"><i class="fa fa-times mr-2"></i>Cancel</button>
|
||||
<button type="submit" name="bulk_move_files" class="btn btn-primary text-bold">
|
||||
<i class="fa fa-check mr-2"></i>Move Files
|
||||
</button>
|
||||
<button type="button" class="btn btn-light" data-dismiss="modal">
|
||||
<i class="fa fa-times mr-2"></i>Cancel
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$invoice_ids = array_map('intval', $_GET['invoice_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($invoice_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="invoice_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($invoice_ids as $invoice_id) { ?><input type="hidden" name="invoice_ids[]" value="<?= $invoice_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$location_ids = array_map('intval', $_GET['location_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($location_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
</div>
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="location_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($location_ids as $location_id) { ?><input type="hidden" name="location_ids[]" value="<?= $location_id ?>"><?php } ?>
|
||||
<input type="hidden" name="bulk_remove_tags" value="0">
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$recurring_ticket_ids = array_map('intval', $_GET['recurring_ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($recurring_ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($recurring_ticket_ids as $recurring_ticket_id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $recurring_ticket_id ?>"><?php } ?>
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
@@ -34,7 +34,7 @@ ob_start();
|
||||
$sql_users_select = mysqli_query($mysqli, "SELECT user_id, user_name FROM users
|
||||
WHERE user_type = 1
|
||||
AND user_status = 1
|
||||
AND user_archived_at IS NULL
|
||||
AND user_archived_at IS NULL
|
||||
ORDER BY user_name DESC"
|
||||
);
|
||||
while ($row = mysqli_fetch_array($sql_users_select)) {
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$recurring_ticket_ids = array_map('intval', $_GET['recurring_ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($recurring_ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,8 +19,8 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
|
||||
<?php foreach ($recurring_ticket_ids as $recurring_ticket_id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $recurring_ticket_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$recurring_ticket_ids = array_map('intval', $_GET['recurring_ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($recurring_ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($recurring_ticket_ids as $recurring_ticket_id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $recurring_ticket_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$recurring_ticket_ids = array_map('intval', $_GET['recurring_ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($recurring_ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,8 +19,8 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
|
||||
<?php foreach ($recurring_ticket_ids as $recurring_ticket_id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $recurring_ticket_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$recurring_ticket_ids = array_map('intval', $_GET['recurring_ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($recurring_ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($recurring_ticket_ids as $recurring_ticket_id) { ?><input type="hidden" name="recurring_ticket_ids[]" value="<?= $recurring_ticket_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$ticket_ids = array_map('intval', $_GET['ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,8 +19,8 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
|
||||
<?php foreach ($ticket_ids as $ticket_id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $ticket_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
@@ -32,7 +32,7 @@ ob_start();
|
||||
<select class="form-control select2" name="project_id">
|
||||
<option value="0">No Project</option>
|
||||
<?php
|
||||
$sql_projects_select = mysqli_query($mysqli, "SELECT project_id, project_name, project_prefix, project_number FROM projects
|
||||
$sql_projects_select = mysqli_query($mysqli, "SELECT project_id, project_name, project_prefix, project_number FROM projects
|
||||
WHERE project_archived_at IS NULL
|
||||
AND project_completed_at IS NULL
|
||||
ORDER BY project_name DESC"
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$ticket_ids = array_map('intval', $_GET['ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($ticket_ids as $ticket_id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $ticket_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
@@ -35,7 +35,7 @@ ob_start();
|
||||
$sql_users_select = mysqli_query($mysqli, "SELECT user_id, user_name FROM users
|
||||
WHERE user_type = 1
|
||||
AND user_status = 1
|
||||
AND user_archived_at IS NULL
|
||||
AND user_archived_at IS NULL
|
||||
ORDER BY user_name ASC"
|
||||
);
|
||||
while ($row = mysqli_fetch_array($sql_users_select)) {
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$ticket_ids = array_map('intval', $_GET['ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($ticket_ids as $ticket_id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $ticket_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$ticket_ids = array_map('intval', $_GET['ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,8 +19,8 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
|
||||
<?php foreach ($ticket_ids as $ticket_id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $ticket_id ?>"><?php } ?>
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
@@ -46,4 +46,4 @@ ob_start();
|
||||
</form>
|
||||
|
||||
<?php
|
||||
require_once '../../../includes/modal_footer.php';
|
||||
require_once '../../../includes/modal_footer.php';
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$ticket_ids = array_map('intval', $_GET['ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($ticket_ids as $ticket_id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $ticket_id ?>"><?php } ?>
|
||||
<input type="hidden" id="current_ticket_id" value="0"> <!-- Can't currently bulk check this -->
|
||||
<input type="hidden" name="merge_move_replies" value="0"> <!-- Default 0 -->
|
||||
<div class="modal-body">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$ticket_ids = array_map('intval', $_GET['ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -19,7 +19,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($ticket_ids as $ticket_id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $ticket_id ?>"><?php } ?>
|
||||
<input type="hidden" name="bulk_private_reply" value="0">
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
require_once '../../../includes/modal_header.php';
|
||||
|
||||
$selected_ids = array_map('intval', $_GET['selected_ids'] ?? []);
|
||||
$ticket_ids = array_map('intval', $_GET['ticket_ids'] ?? []);
|
||||
|
||||
$count = count($selected_ids);
|
||||
$count = count($ticket_ids);
|
||||
|
||||
ob_start();
|
||||
|
||||
@@ -18,7 +18,7 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<?php foreach ($selected_ids as $id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $id ?>"><?php } ?>
|
||||
<?php foreach ($ticket_ids as $ticket_id) { ?><input type="hidden" name="ticket_ids[]" value="<?= $ticket_id ?>"><?php } ?>
|
||||
<input type="hidden" name="bulk_private_note" value="0">
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
Reference in New Issue
Block a user