diff --git a/htdocs/comm/action/card.php b/htdocs/comm/action/card.php index e34dffd6223..fba2cf10cbc 100644 --- a/htdocs/comm/action/card.php +++ b/htdocs/comm/action/card.php @@ -730,8 +730,8 @@ if (empty($reshook) && GETPOST('actionmove', 'alpha') == 'mupdate') { $error = 0; - $shour = dol_print_date($object->datep, "%H"); - $smin = dol_print_date($object->datep, "%M"); + $shour = dol_print_date($object->datep, "%H", 'tzuserrel'); // We take the date visible by user $newdate is also date visible by user. + $smin = dol_print_date($object->datep, "%M", 'tzuserrel'); $newdate = GETPOST('newdate', 'alpha'); if (empty($newdate) || strpos($newdate, 'dayevent_') != 0) @@ -740,7 +740,9 @@ if (empty($reshook) && GETPOST('actionmove', 'alpha') == 'mupdate') exit; } - $datep = dol_mktime($shour, $smin, 0, substr($newdate, 13, 2), substr($newdate, 15, 2), substr($newdate, 9, 4)); + $datep = dol_mktime($shour, $smin, 0, substr($newdate, 13, 2), substr($newdate, 15, 2), substr($newdate, 9, 4), 'tzuserrel'); + //print dol_print_date($datep, 'dayhour');exit; + if ($datep != $object->datep) { if (!empty($object->datef)) diff --git a/htdocs/comm/action/index.php b/htdocs/comm/action/index.php index 50d10c9a4c9..fed38a248e0 100644 --- a/htdocs/comm/action/index.php +++ b/htdocs/comm/action/index.php @@ -1533,11 +1533,11 @@ function show_day_events($db, $day, $month, $year, $monthshown, $style, &$eventa } // Line with title of day - print '