Upload via GUI (452 Dateien)

This commit is contained in:
2026-11-05 21:21:48 +00:00
parent e90c1a4563
commit 10578475f0
14 changed files with 543 additions and 18 deletions
+2 -2
View File
@@ -1,6 +1,6 @@
<?php
require_once __DIR__ . '/../includes/bootstrap.php';
$staff = require_staff_login();
$staff = require_admin_or_permission('manage_customers');
$pdo = get_db();
$errors = [];
@@ -10,7 +10,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
verify_csrf();
$action = $_POST['action'] ?? '';
if ($action === 'assign_org' && $staff['role'] === 'admin') {
if ($action === 'assign_org') {
$userId = (int) $_POST['user_id'];
$orgId = $_POST['organization_id'] !== '' ? (int) $_POST['organization_id'] : null;
$pdo->prepare('UPDATE users SET organization_id = ? WHERE id = ?')->execute([$orgId, $userId]);