Merge: UI/UX-Feature-Branch integrieren + Security-Patches re-applien

Integriert die Feature-Branch (Dark Mode, i18n DE/EN, mobile Admin-Layout,
shared admin_nav, Toasts, Voucher-Templates, Bulk-Erstellung, konfigurierbare
Defaults, Password-Reset, Audit-Log-UI + Audit-Logging) mit der bestehenden
Security-/Updater-Arbeit.

Konfliktauflösung (6 Dateien: index.php + admin/*): Feature-Version als Basis,
darauf die Security-Patches re-appliziert:
- display_errors=0 + log_errors in allen neuen/gemergten Entry-Points
- Crypto::encrypt/decrypt an allen Site-Passwort-Pfaden (sites/index/vouchers/
  dashboard-Sync, inkl. doCreateVoucher + Bulk)
- CSRF-Prüfung für ALLE Voucher-Erstellungen (auch anonym/öffentlich), Token
  unbedingt im Formular; Session-Throttle gegen Spam
- Updater-Maintenance-Hook am Anfang von index.php wiederhergestellt

Auto-Merge verifiziert: Auth.php enthält Session-Timeout UND writeAuditLog;
login.php behält display_errors=0 + OAuth-state. Updater-Link in shared
admin_nav.php (i18n-Key nav_update DE/EN). Alle PHP-Dateien linten sauber.
This commit is contained in:
Claude 2026-06-05 19:10:18 +00:00
commit 526c43e8ee
No known key found for this signature in database
20 changed files with 5328 additions and 5521 deletions

289
lang/en.php Normal file
View file

@ -0,0 +1,289 @@
<?php
return [
// Navigation
'nav_dashboard' => 'Dashboard',
'nav_sites' => 'Manage Sites',
'nav_users' => 'Manage Users',
'nav_vouchers' => 'Live Vouchers',
'nav_templates' => 'Voucher Profiles',
'nav_audit_log' => 'Audit Log',
'nav_settings' => 'Settings',
'nav_update' => 'System Update',
'nav_back' => 'Back to Home',
'nav_administration'=> 'Administration',
// Common buttons
'btn_save' => 'Save',
'btn_cancel' => 'Cancel',
'btn_add' => 'Add',
'btn_edit' => 'Edit',
'btn_delete' => 'Delete',
'btn_create' => 'Create',
'btn_close' => 'Close',
'btn_back' => 'Back',
'btn_login' => 'Sign In',
'btn_logout' => 'Sign Out',
'btn_refresh' => 'Refresh',
'btn_export_csv' => 'Export CSV',
'btn_print' => 'Print',
'btn_send' => 'Send',
'btn_test' => 'Test',
'btn_generate' => 'Generate',
'btn_copy' => 'Copy',
'btn_new_code' => 'Create Another Code',
// Common labels
'label_name' => 'Name',
'label_email' => 'Email',
'label_password' => 'Password',
'label_status' => 'Status',
'label_actions' => 'Actions',
'label_created' => 'Created',
'label_site' => 'Location',
'label_sites' => 'Sites',
'label_role' => 'Role',
'label_code' => 'Code',
'label_note' => 'Note',
'label_usage' => 'Usage',
'label_expires' => 'Expires',
'label_devices' => 'Devices',
'label_duration' => 'Duration',
'label_description' => 'Description',
'label_language' => 'Language',
// Status texts
'status_active' => 'Active',
'status_inactive' => 'Inactive',
'status_valid' => 'Valid',
'status_used' => 'Used',
'status_expired' => 'Expired',
'status_admin' => 'Admin',
'status_user' => 'User',
'status_public' => 'Public',
'status_all' => 'All',
// Dashboard
'dashboard_title' => 'Dashboard',
'dashboard_subtitle'=> 'Overview of your UniFi Voucher System',
'dashboard_active_sites' => 'Active Sites',
'dashboard_users' => 'Users',
'dashboard_valid' => 'Valid Vouchers',
'dashboard_used' => 'Used',
'dashboard_expired' => 'Expired',
'dashboard_total' => 'Total',
'dashboard_live_refresh' => 'Live Refresh',
'dashboard_trend' => 'Voucher Trend (Last 7 Days)',
'dashboard_top_users'=> 'Top 5 Users (Last 30 Days)',
'dashboard_recent' => 'Recent Vouchers (from Database)',
'dashboard_creator' => 'Creator',
'dashboard_public' => 'Public',
'dashboard_vouchers_per_site' => 'Live: Vouchers per Site',
'dashboard_no_data' => 'No data available yet',
'dashboard_no_vouchers' => 'No vouchers created yet',
// Voucher creation
'voucher_name_label' => 'Voucher Name *',
'voucher_name_hint' => 'e.g. Meeting Room 3, Guest John Doe',
'voucher_devices_label' => 'How many devices may connect? *',
'voucher_site_label' => 'Location *',
'voucher_site_select' => 'Please select...',
'voucher_email_send' => 'Send code via email',
'voucher_email_label' => 'Recipient email address',
'voucher_email_hint' => 'guest@example.com',
'voucher_create_btn' => 'Create Voucher',
'voucher_creating' => 'Creating Voucher...',
'voucher_success_title' => '✓ Your Access Code',
'voucher_validity' => 'Valid for {minutes} minutes from creation',
'voucher_qr_label' => 'Scan QR code to connect',
'voucher_print_btn' => 'Print Code',
'voucher_no_sites' => 'No available sites found.',
'voucher_no_sites_admin'=> 'Click here to create sites',
'voucher_no_sites_user' => 'Please contact your administrator.',
'voucher_template_select'=> '-- No Profile (manual) --',
'voucher_template_label'=> 'Quick Profile (optional)',
// Bulk creation
'bulk_tab' => 'Single',
'bulk_tab_bulk' => 'Create Multiple',
'bulk_quantity' => 'Number of Vouchers',
'bulk_quantity_hint'=> 'How many vouchers should be created?',
'bulk_name_prefix' => 'Name / Prefix',
'bulk_create_btn' => 'Create {count} Vouchers',
'bulk_creating' => 'Creating {count} vouchers...',
'bulk_success' => '{count} vouchers created successfully!',
'bulk_print_all' => 'Print All',
'bulk_results' => 'Created Vouchers ({count})',
// Templates
'templates_title' => 'Voucher Profiles',
'templates_subtitle'=> 'Predefined voucher configurations',
'templates_add' => 'New Profile',
'templates_name' => 'Profile Name',
'templates_devices' => 'Max. Devices',
'templates_duration'=> 'Validity (Minutes)',
'templates_desc' => 'Description (optional)',
'templates_none' => 'No profiles found.',
'templates_add_hint'=> 'Create profiles for frequently used voucher configurations.',
'templates_edit' => 'Edit Profile',
'templates_added' => 'Profile created successfully!',
'templates_updated' => 'Profile updated successfully!',
'templates_deleted' => 'Profile deleted successfully!',
// Users
'users_title' => 'Manage Users',
'users_add' => 'New User',
'users_all' => 'All Users',
'users_site_access' => 'Site Access',
'users_last_login' => 'Last Login',
'users_never' => 'Never',
'users_you' => 'You',
'users_all_sites' => 'All Sites',
'users_none' => 'None',
'users_add_title' => 'Create New User',
'users_edit_title' => 'Edit User',
'users_admin_check' => 'Administrator Rights',
'users_admin_hint' => 'Admins have access to all sites and settings',
'users_password_hint'=> 'At least 8 characters',
'users_site_hint' => 'Select the sites this user should have access to',
'users_no_sites' => 'No sites available. Please create sites first.',
'users_added' => 'User created successfully!',
'users_updated' => 'User updated successfully!',
'users_deleted' => 'User deleted successfully!',
'users_notified' => ' Notification sent.',
'users_none_found' => 'No users found',
'users_save' => 'Create User',
'users_save_edit' => 'Save Changes',
'users_reset_pw' => 'Send Password Reset Link',
// Sites
'sites_title' => 'Manage Sites',
'sites_add' => 'Add New Site',
'sites_add_title' => 'Add New Site',
'sites_edit_title' => 'Edit Site',
'sites_name' => 'Site Name *',
'sites_site_id' => 'UniFi Site ID *',
'sites_controller' => 'Controller URL *',
'sites_username' => 'Username *',
'sites_password' => 'Password *',
'sites_password_edit'=> 'New Password',
'sites_password_hint'=> 'Leave blank to keep current password',
'sites_public' => 'Public Access (usable without login)',
'sites_none' => 'No sites configured yet. Add your first site!',
'sites_added' => 'Site added successfully!',
'sites_updated' => 'Site updated successfully!',
'sites_deleted' => 'Site deleted successfully!',
'sites_testing' => 'Testing connection...',
'sites_deactivate' => 'Deactivate',
'sites_activate' => 'Activate',
// Voucher admin list
'vouchers_title' => 'Live Voucher Management',
'vouchers_subtitle' => 'Vouchers are fetched directly from the UniFi Controller',
'vouchers_select_site'=> 'Select Site',
'vouchers_select_hint'=> '-- Select Site --',
'vouchers_last_sync'=> 'Last Sync',
'vouchers_no_sites' => 'No active sites available',
'vouchers_search' => 'Search (code, name...)',
'vouchers_filter_all'=> 'All',
'vouchers_filter_valid'=> 'Valid',
'vouchers_filter_used'=> 'Used',
'vouchers_filter_expired'=> 'Expired',
'vouchers_none' => 'No vouchers found.',
'vouchers_per_page' => 'per page',
'vouchers_page_of' => 'Page {current} of {total}',
// Audit Log
'audit_title' => 'Audit Log',
'audit_subtitle' => 'All system actions at a glance',
'audit_action' => 'Action',
'audit_user' => 'User',
'audit_details' => 'Details',
'audit_ip' => 'IP Address',
'audit_time' => 'Time',
'audit_entity' => 'Entity',
'audit_filter_all' => 'All Actions',
'audit_none' => 'No entries found.',
'audit_filter' => 'Filter',
// Settings
'settings_title' => 'Settings',
'settings_subtitle' => 'System configuration and customization',
'settings_tab_general' => 'General',
'settings_tab_defaults' => 'Voucher Defaults',
'settings_tab_cron' => 'Cron Sync',
'settings_tab_m365' => 'Microsoft 365',
'settings_tab_smtp' => 'SMTP',
'settings_tab_templates_email' => 'Templates',
'settings_tab_system' => 'System',
'settings_tab_password' => 'Password',
'settings_saved' => 'Settings saved successfully!',
'settings_app_title' => 'Application Title *',
'settings_logo_url' => 'Logo URL',
'settings_favicon_url' => 'Favicon URL',
'settings_favicon_hint' => 'Browser tab icon (.ico, .png, .svg)',
'settings_instr_header' => 'Instructions - Headline',
'settings_instr_text' => 'Instructions - Text',
'settings_public_access'=> 'Public Access',
'settings_default_expire' => 'Default Validity (Minutes)',
'settings_default_expire_hint'=> 'Default expiry time for new vouchers (480 = 8 hours)',
'settings_default_devices' => 'Default Device Count',
'settings_default_devices_hint'=> 'Pre-filled value in the voucher form',
'settings_max_devices' => 'Maximum Device Count',
'settings_max_devices_hint' => 'Maximum value a user can select',
'settings_pw_current' => 'Current Password',
'settings_pw_new' => 'New Password',
'settings_pw_confirm' => 'Confirm Password',
'settings_pw_changed' => 'Password changed successfully!',
'settings_pw_minlength' => 'At least 8 characters',
// Login / Auth
'login_title' => 'Sign In',
'login_subtitle' => 'Sign in to continue',
'login_email' => 'Email',
'login_password' => 'Password',
'login_btn' => 'Sign In',
'login_ms' => 'Sign in with Microsoft',
'login_local' => 'Sign in with username and password',
'login_back' => '← Back to Code Creation',
'login_forgot' => 'Forgot password?',
'login_error_empty' => 'Please enter email and password',
'login_error_rate' => 'Too many failed attempts. Please wait 10 minutes.',
'login_error_creds' => 'Invalid email or password',
// Password Reset
'reset_title' => 'Forgot Password',
'reset_subtitle' => 'Enter your email we will send you a reset link.',
'reset_email_label' => 'Email Address',
'reset_send_btn' => 'Send Reset Link',
'reset_success' => 'If an account with this email exists, you will receive an email shortly.',
'reset_back_login' => '← Back to Login',
'reset_new_pw' => 'Set New Password',
'reset_new_pw_label'=> 'New Password',
'reset_confirm_label'=> 'Confirm Password',
'reset_set_btn' => 'Set Password',
'reset_invalid' => 'Invalid or expired reset link.',
'reset_done' => 'Your password has been changed successfully.',
// Errors
'error_csrf' => 'Invalid security token',
'error_login_req' => 'You must be logged in',
'error_no_permission'=> 'No permission for this action',
'error_not_found' => 'Not found',
'error_name_req' => 'Please enter a name',
'error_site_req' => 'Please select a location',
'error_devices_range'=> 'Device count must be between 1 and {max}',
'error_email_invalid'=> 'Invalid email address',
'error_site_no_perm'=> 'No permission for this site',
'error_site_not_found'=> 'Site not found',
'error_voucher_invalid'=> 'UniFi did not return a valid voucher',
'error_connection' => 'Connection to UniFi Controller failed',
'error_fill_all' => 'Please fill in all required fields',
// Hello / User
'hello' => 'Hello, {name}',
'minutes_short' => 'min.',
'hours_short' => 'hrs.',
'never' => 'Never',
'unknown' => 'Unknown',
'or' => 'or',
];