diff --git a/admin/manage_categories.php b/admin/manage_categories.php index c90aebc8..c3c85e98 100644 --- a/admin/manage_categories.php +++ b/admin/manage_categories.php @@ -93,10 +93,11 @@ while ($mycat = hesk_dbFetchAssoc($res)) { ?>
-
+ + +

@@ -253,6 +255,7 @@ while ($mycat = hesk_dbFetchAssoc($res)) {

+ - - - - - - - - - - - +
+
+ +
+
+
+ + + + + + + + + + + + + + ' + $usage = array( + 0 => '', - 1 => '', - 2 => ' ' - ); + 1 => '', + 2 => ' ' + ); - while ($mycat = hesk_dbFetchAssoc($res)) { - $j++; + while ($mycat = hesk_dbFetchAssoc($res)) { + $j++; - if (isset($_SESSION['selcat2']) && $mycat['id'] == $_SESSION['selcat2']) { - $color = 'admin_green'; - unset($_SESSION['selcat2']); - } else { - $color = $i ? 'admin_white' : 'admin_gray'; - } + if (isset($_SESSION['selcat2']) && $mycat['id'] == $_SESSION['selcat2']) { + $color = 'admin_green'; + unset($_SESSION['selcat2']); + } else { + $color = $i ? 'admin_white' : 'admin_gray'; + } - $tmp = $i ? 'White' : 'Blue'; - $style = 'background: ' . $mycat['background_color']; - $backgroundVolatile = 'background-volatile'; - if ($mycat['foreground_color'] != 'AUTO') { - $style .= '; color: ' . $mycat['foreground_color']; - $backgroundVolatile = ''; + $tmp = $i ? 'White' : 'Blue'; + $style = 'background: ' . $mycat['background_color']; + $backgroundVolatile = 'background-volatile'; + if ($mycat['foreground_color'] != 'AUTO') { + $style .= '; color: ' . $mycat['foreground_color']; + $backgroundVolatile = ''; - if ($mycat['display_border_outline']) { - $style .= '; border: solid 1px ' . $mycat['foreground_color']; - } - } + if ($mycat['display_border_outline']) { + $style .= '; border: solid 1px ' . $mycat['foreground_color']; + } + } - if ($mycat['foreground_color'] == 'AUTO') { - $mycat['foreground_color'] = ''; - } + if ($mycat['foreground_color'] == 'AUTO') { + $mycat['foreground_color'] = ''; + } - $i = $i ? 0 : 1; + $i = $i ? 0 : 1; - /* Number of tickets and graph width */ - $all = isset($tickets_all[$mycat['id']]) ? $tickets_all[$mycat['id']] : 0; - $width_all = 0; - if ($tickets_total && $all) { - $width_all = round(($all / $tickets_total) * 100); - } + /* Number of tickets and graph width */ + $all = isset($tickets_all[$mycat['id']]) ? $tickets_all[$mycat['id']] : 0; + $width_all = 0; + if ($tickets_total && $all) { + $width_all = round(($all / $tickets_total) * 100); + } - /* Deleting category with ID 1 (default category) is not allowed */ - if ($mycat['id'] == 1) { - $remove_code = ' '; - } else { - $remove_code = ' '; - } + /* Deleting category with ID 1 (default category) is not allowed */ + if ($mycat['id'] == 1) { + $remove_code = ' '; + } else { + $remove_code = ' '; + } - /* Is category private or public? */ - if ($mycat['type']) { - $type_code = ''; - } else { - $type_code = ''; - } + /* Is category private or public? */ + if ($mycat['type']) { + $type_code = ''; + } else { + $type_code = ''; + } - /* Is auto assign enabled? */ - if ($hesk_settings['autoassign']) { - if ($mycat['autoassign']) { - $autoassign_code = ''; - } else { - $autoassign_code = ''; - } - } else { - $autoassign_code = ''; - } + /* Is auto assign enabled? */ + if ($hesk_settings['autoassign']) { + if ($mycat['autoassign']) { + $autoassign_code = ''; + } else { + $autoassign_code = ''; + } + } else { + $autoassign_code = ''; + } - echo ' + echo ' 1) { - if ($j == 1) { - echo ' '; - } elseif ($j == $num) { - echo ''; - } else { - echo ' + if ($orderBy != 'name' && $num > 1) { + if ($j == 1) { + echo ' '; + } elseif ($j == $num) { + echo ''; + } else { + echo '   '; - } - } - echo ''; - echo $remove_code . ' + } + } + echo ''; + echo $remove_code . ' '; - } // End while + } // End while - ?> -
+ ?> + + +
+
diff --git a/api/index.php b/api/index.php index a41b13fc..fbe12a8b 100644 --- a/api/index.php +++ b/api/index.php @@ -206,21 +206,21 @@ Link::all(array( /* Internal use only routes */ // Resend email response '/v1-internal/staff/tickets/{i}/resend-email' => - action(\Controllers\Tickets\ResendTicketEmailToCustomerController::class, SecurityHandler::INTERNAL), + action(\Controllers\Tickets\ResendTicketEmailToCustomerController::class, RequestMethod::ALL, SecurityHandler::INTERNAL), // Custom Navigation '/v1-internal/custom-navigation/all' => - action(\Controllers\Navigation\CustomNavElementController::class . '::getAll', SecurityHandler::INTERNAL), + action(\Controllers\Navigation\CustomNavElementController::class . '::getAll', RequestMethod::ALL, SecurityHandler::INTERNAL), '/v1-internal/custom-navigation' => - action(\Controllers\Navigation\CustomNavElementController::class, SecurityHandler::INTERNAL), + action(\Controllers\Navigation\CustomNavElementController::class, RequestMethod::ALL, SecurityHandler::INTERNAL), '/v1-internal/custom-navigation/{i}' => - action(\Controllers\Navigation\CustomNavElementController::class, SecurityHandler::INTERNAL), + action(\Controllers\Navigation\CustomNavElementController::class, RequestMethod::ALL, SecurityHandler::INTERNAL), '/v1-internal/custom-navigation/{i}/sort/{s}' => - action(\Controllers\Navigation\CustomNavElementController::class . '::sort', SecurityHandler::INTERNAL), + action(\Controllers\Navigation\CustomNavElementController::class . '::sort', RequestMethod::ALL, SecurityHandler::INTERNAL), '/v1-public/hesk-version' => - action(\Controllers\System\HeskVersionController::class . '::getHeskVersion', SecurityHandler::OPEN), + action(\Controllers\System\HeskVersionController::class . '::getHeskVersion', RequestMethod::ALL, SecurityHandler::OPEN), '/v1-public/mods-for-hesk-version' => - action(\Controllers\System\HeskVersionController::class . '::getModsForHeskVersion', SecurityHandler::OPEN), + action(\Controllers\System\HeskVersionController::class . '::getModsForHeskVersion', RequestMethod::ALL, SecurityHandler::OPEN), // Any URL that doesn't match goes to the 404 handler '404' => 'handle404'