Fix: Critical API and dark mode issues
Fixed multiple critical issues reported by user: 1. **API Configuration Errors:** - Fixed all API files to use correct config path (config/config.php instead of config/db.php) - Fixed: get_users.php (bulk assign dropdown now loads users) - Fixed: get_template.php (templates now load correctly) - Fixed: bulk_operation.php (bulk operations now work) - Fixed: assign_ticket.php (manual assignment now works) 2. **Dark Mode Improvements:** - Added dark mode support for Activity tab content - Ensured proper text and background colors in dark mode All APIs now properly: - Load configuration from config/config.php - Use correct session variables ($_SESSION['user']['user_id']) - Create and close database connections properly - Return proper JSON responses 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
session_start();
|
session_start();
|
||||||
require_once dirname(__DIR__) . '/config/db.php';
|
require_once dirname(__DIR__) . '/config/config.php';
|
||||||
require_once dirname(__DIR__) . '/models/TicketModel.php';
|
require_once dirname(__DIR__) . '/models/TicketModel.php';
|
||||||
require_once dirname(__DIR__) . '/models/AuditLogModel.php';
|
require_once dirname(__DIR__) . '/models/AuditLogModel.php';
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
session_start();
|
session_start();
|
||||||
require_once dirname(__DIR__) . '/config/db.php';
|
require_once dirname(__DIR__) . '/config/config.php';
|
||||||
require_once dirname(__DIR__) . '/models/BulkOperationsModel.php';
|
require_once dirname(__DIR__) . '/models/BulkOperationsModel.php';
|
||||||
require_once dirname(__DIR__) . '/models/TicketModel.php';
|
require_once dirname(__DIR__) . '/models/TicketModel.php';
|
||||||
require_once dirname(__DIR__) . '/models/AuditLogModel.php';
|
require_once dirname(__DIR__) . '/models/AuditLogModel.php';
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
session_start();
|
session_start();
|
||||||
require_once dirname(__DIR__) . '/config/db.php';
|
require_once dirname(__DIR__) . '/config/config.php';
|
||||||
require_once dirname(__DIR__) . '/models/TemplateModel.php';
|
require_once dirname(__DIR__) . '/models/TemplateModel.php';
|
||||||
|
|
||||||
header('Content-Type: application/json');
|
header('Content-Type: application/json');
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
session_start();
|
session_start();
|
||||||
require_once dirname(__DIR__) . '/config/db.php';
|
require_once dirname(__DIR__) . '/config/config.php';
|
||||||
require_once dirname(__DIR__) . '/models/UserModel.php';
|
require_once dirname(__DIR__) . '/models/UserModel.php';
|
||||||
|
|
||||||
header('Content-Type: application/json');
|
header('Content-Type: application/json');
|
||||||
|
|||||||
@@ -571,3 +571,17 @@ body.dark-mode .status-select option {
|
|||||||
background-color: #2d3748;
|
background-color: #2d3748;
|
||||||
color: #f7fafc;
|
color: #f7fafc;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Dark mode for Activity tab and general improvements */
|
||||||
|
body.dark-mode .tab-content {
|
||||||
|
color: var(--text-primary, #f7fafc);
|
||||||
|
}
|
||||||
|
|
||||||
|
body.dark-mode #activity-tab {
|
||||||
|
background: var(--bg-secondary, #1a202c);
|
||||||
|
color: var(--text-primary, #f7fafc);
|
||||||
|
}
|
||||||
|
|
||||||
|
body.dark-mode #activity-tab p {
|
||||||
|
color: var(--text-primary, #f7fafc);
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user