Merge branch '2-6-3' into 'master'

2.6.3



See merge request !24
merge-requests/26/head 2.6.3
Mike Koch 8 years ago
commit 2b0e8002fc

@ -187,7 +187,7 @@ require_once(HESK_PATH . 'inc/show_admin_nav.inc.php');
<?php echo $hesklang['category']; ?> <?php echo $hesklang['category']; ?>
<i class="fa fa-question-circle settingsquestionmark" <i class="fa fa-question-circle settingsquestionmark"
data-toggle="tooltip" data-toggle="tooltip"
title="<?php echo htmlspecialchars($hesklang['event_category_toolip']); ?>"></i> title="<?php echo htmlspecialchars($hesklang['event_category_tooltip']); ?>"></i>
</label> </label>
<div class="col-sm-9"> <div class="col-sm-9">
<select name="category" class="form-control" <select name="category" class="form-control"
@ -357,7 +357,7 @@ require_once(HESK_PATH . 'inc/show_admin_nav.inc.php');
<?php echo $hesklang['category']; ?> <?php echo $hesklang['category']; ?>
<i class="fa fa-question-circle settingsquestionmark" <i class="fa fa-question-circle settingsquestionmark"
data-toggle="tooltip" data-toggle="tooltip"
title="<?php echo htmlspecialchars($hesklang['event_category_toolip']); ?>"></i> title="<?php echo htmlspecialchars($hesklang['event_category_tooltip']); ?>"></i>
</label> </label>
<div class="col-sm-9"> <div class="col-sm-9">
<select name="category" class="form-control" <select name="category" class="form-control"

@ -906,8 +906,8 @@ function toggle_active()
// Revoke any manager rights // Revoke any manager rights
hesk_dbQuery("UPDATE `" . hesk_dbEscape($hesk_settings['db_pfix']) . "categories` SET `manager` = 0 WHERE `manager` = " . intval($myuser)); hesk_dbQuery("UPDATE `" . hesk_dbEscape($hesk_settings['db_pfix']) . "categories` SET `manager` = 0 WHERE `manager` = " . intval($myuser));
$notificationSql = ", `autoassign` = 0, `notify_new_unassigned` = 0, `notify_new_my` = 0, `notify_reply_unassigned` = 0, $notificationSql = ", `autoassign` = '0', `notify_new_unassigned` = '0', `notify_new_my` = '0', `notify_reply_unassigned` = '0',
`notify_reply_my` = 0, `notify_assigned` = 0, `notify_pm` = 0, `notify_note` = 0, `notify_note_unassigned` = 0, `notify_overdue_unassigned` = 0"; `notify_reply_my` = '0', `notify_assigned` = '0', `notify_pm` = '0', `notify_note` = '0', `notify_note_unassigned` = '0', `notify_overdue_unassigned` = '0'";
} }
hesk_dbQuery("UPDATE `" . hesk_dbEscape($hesk_settings['db_pfix']) . "users` SET `active` = '" . $active . "'" . $notificationSql . " WHERE `id` = '" . intval($myuser) . "'"); hesk_dbQuery("UPDATE `" . hesk_dbEscape($hesk_settings['db_pfix']) . "users` SET `active` = '" . $active . "'" . $notificationSql . " WHERE `id` = '" . intval($myuser) . "'");

@ -15,7 +15,8 @@
/** /**
* @apiDefine noTokenProvided 400 Bad Request * @apiDefine noTokenProvided 400 Bad Request
* No `X-Auth-Token` was provided. * No `X-Auth-Token` was provided.
* */
/**
* @apiDefine canManUsers Protected (Can Manage Users) * @apiDefine canManUsers Protected (Can Manage Users)
* A protected API can only be utilized by users with a valid `X-Auth-Token` and have the 'can_man_users' permission (or is an admin) * A protected API can only be utilized by users with a valid `X-Auth-Token` and have the 'can_man_users' permission (or is an admin)
*/ */

@ -16,7 +16,7 @@ hesk_dbConnect();
$request_method = $_SERVER['REQUEST_METHOD']; $request_method = $_SERVER['REQUEST_METHOD'];
/** /**
* @api {get} /ticket Retrieve a ticket (staff-side) * @api {get} /ticket Retrieve a ticket (customer-side)
* @apiVersion 0.0.0 * @apiVersion 0.0.0
* @apiName GetTicket * @apiName GetTicket
* @apiGroup Ticket * @apiGroup Ticket

@ -1,4 +1,4 @@
<?php <?php
// Define the current build // Define the current build
define('MODS_FOR_HESK_BUILD', 28); define('MODS_FOR_HESK_BUILD', 30);

@ -78,7 +78,11 @@ if (hesk_dbNumRows($rs) > 0 && !$skip_events) {
$successful_emails = 0; $successful_emails = 0;
$failed_emails = 0; $failed_emails = 0;
while ($row = hesk_dbFetchAssoc($rs) && !$skip_events) { while ($row = hesk_dbFetchAssoc($rs)) {
if ($skip_events) {
return true;
}
if (mfh_sendCalendarReminder($row, $modsForHesk_settings)) { if (mfh_sendCalendarReminder($row, $modsForHesk_settings)) {
$reminders_to_flag[] = $row['reminder_id']; $reminders_to_flag[] = $row['reminder_id'];
$successful_emails++; $successful_emails++;

@ -101,7 +101,11 @@ button.dropdown-submit {
} }
.ticketMessageBottom > .message { .ticketMessageBottom > .message {
margin-bottom: 0px; margin-bottom: 0;
}
.ticketMessageBottom > blockquote {
margin-bottom: 0;
} }
.message > * { .message > * {

@ -37,7 +37,7 @@ if (!defined('IN_SCRIPT')) {die('Invalid attempt');}
// We will be installing this HESK version: // We will be installing this HESK version:
define('HESK_NEW_VERSION','2.6.7'); define('HESK_NEW_VERSION','2.6.7');
define('MODS_FOR_HESK_NEW_VERSION','2.6.2'); define('MODS_FOR_HESK_NEW_VERSION','2.6.3');
define('REQUIRE_PHP_VERSION','5.0.0'); define('REQUIRE_PHP_VERSION','5.0.0');
define('REQUIRE_MYSQL_VERSION','5.0.7'); define('REQUIRE_MYSQL_VERSION','5.0.7');

@ -64,6 +64,8 @@ if ($version == 2) {
execute261Scripts(); execute261Scripts();
} elseif ($version == 29) { } elseif ($version == 29) {
execute262Scripts(); execute262Scripts();
} elseif ($version == 30) {
execute263Scripts();
} else { } else {
$response = 'The version "' . $version . '" was not recognized. Check the value submitted and try again.'; $response = 'The version "' . $version . '" was not recognized. Check the value submitted and try again.';
print $response; print $response;

@ -38,6 +38,7 @@ $buildToVersionMap = array(
27 => '2.6.0', 27 => '2.6.0',
28 => '2.6.1', 28 => '2.6.1',
29 => '2.6.2', 29 => '2.6.2',
30 => '2.6.3',
); );
function echoInitialVersionRows($version, $build_to_version_map) function echoInitialVersionRows($version, $build_to_version_map)

@ -83,6 +83,9 @@ function processUpdates(startingVersion) {
} else if (startingVersion < 29) { } else if (startingVersion < 29) {
startVersionUpgrade('262'); startVersionUpgrade('262');
executeUpdate(29, '262', '2.6.2'); executeUpdate(29, '262', '2.6.2');
} else if (startingVersion < 30) {
startVersionUpgrade('263');
executeUpdate(30, '263', '2.6.3');
} else { } else {
installationFinished(); installationFinished();
} }

@ -117,6 +117,7 @@ hesk_dbConnect();
<div class="col-md-8"> <div class="col-md-8">
<select name="current-version" class="form-control"> <select name="current-version" class="form-control">
<optgroup label="Mods for HESK 2"> <optgroup label="Mods for HESK 2">
<option value="29">2.6.2</option>
<option value="28">2.6.1</option> <option value="28">2.6.1</option>
<option value="27">2.6.0</option> <option value="27">2.6.0</option>
<option value="26">2.5.5</option> <option value="26">2.5.5</option>

@ -806,6 +806,14 @@ function execute262Scripts() {
updateVersion('2.6.2'); updateVersion('2.6.2');
} }
// Version 2.6.3
function execute263Scripts() {
global $hesk_settings;
hesk_dbConnect();
updateVersion('2.6.3');
}
function execute270Scripts() { function execute270Scripts() {
global $hesk_settings; global $hesk_settings;
hesk_dbConnect(); hesk_dbConnect();

@ -3,6 +3,9 @@
function get_events($start, $end, $hesk_settings, $staff = true) { function get_events($start, $end, $hesk_settings, $staff = true) {
global $hesk_settings, $hesklang; global $hesk_settings, $hesklang;
$start_time_sql = "CONVERT_TZ(FROM_UNIXTIME(" . hesk_dbEscape($start) . " / 1000), @@session.time_zone, '+00:00')";
$end_time_sql = "CONVERT_TZ(FROM_UNIXTIME(" . hesk_dbEscape($end) . " / 1000), @@session.time_zone, '+00:00')";
$sql = "SELECT `events`.*, `categories`.`name` AS `category_name`, `categories`.`color` AS `category_color` "; $sql = "SELECT `events`.*, `categories`.`name` AS `category_name`, `categories`.`color` AS `category_color` ";
if ($staff) { if ($staff) {
@ -17,8 +20,7 @@ function get_events($start, $end, $hesk_settings, $staff = true) {
$sql .= "LEFT JOIN `" . hesk_dbEscape($hesk_settings['db_pfix']) . "calendar_event_reminder` AS `reminders` ON $sql .= "LEFT JOIN `" . hesk_dbEscape($hesk_settings['db_pfix']) . "calendar_event_reminder` AS `reminders` ON
`reminders`.`user_id` = " . intval($_SESSION['id']) . " AND `reminders`.`event_id` = `events`.`id`"; `reminders`.`user_id` = " . intval($_SESSION['id']) . " AND `reminders`.`event_id` = `events`.`id`";
} }
$sql .= "WHERE `start` >= CONVERT_TZ(FROM_UNIXTIME(" . hesk_dbEscape($start) $sql .= "WHERE NOT (`end` < {$start_time_sql} AND `start` > {$end_time_sql}) AND `categories`.`usage` <> 1";
. " / 1000), @@session.time_zone, '+00:00') AND `end` <= CONVERT_TZ(FROM_UNIXTIME(" . hesk_dbEscape($end) . " / 1000), @@session.time_zone, '+00:00') AND `categories`.`usage` <> 1";
if (!$staff) { if (!$staff) {
$sql .= " AND `categories`.`type` = '0'"; $sql .= " AND `categories`.`type` = '0'";

Loading…
Cancel
Save