Bug #20260
closedstarttime eval date produces time-differences on same values!?
0%
Description
I recognized that if I enter dates the starttime ist not a real date on 0:00 o'clock. It has some time differences. I had some elements with starttime 1-4-2009 and now I see this in the backend:
01-04-09 (8 Std)
01-04-09 (14 Std)
01-04-09 (-4 Std)
01-04-09 (4 Std)
01-04-09 (6 Min)
01-04-09 (-2 Std)
I understand what it mean. The elements will go online in 8 hours, 14, hours, are only since 4 hours, goes online in 4 hours, and so on.
But the field is eval date and I cannot enter hour und minutes here.
Bug?
(issue imported from #M10821)
Updated by Sven Weiss over 15 years ago
I tried to edit it and tested it. I enter 31-3-2009 and the result is:
1238450400
31.03.2009 00:00:00
Very hard to reproduce, perhaps it is a workspace problem because I am working with workspaces and publishing.
Updated by Sven Weiss over 15 years ago
Now I know where the error occurs.
If an user edits a record and don't have access to the starttime, then the starttime gets "value - 1 hour" (I think because of the timezone GMT+1). You can then see it in the workspace overview where the differences of the records will be shown.
This function is the problem here:
typo3_src/t3lib/class.t3lib_tcemain.php
class t3lib_TCEmain {
function checkValue_input_Eval($value,$evalArray,$is_in) {
...
case 'date':
case 'datetime':
$value = intval($value);
if ($value>0 && !$this->dontProcessTransformations) {
$value -= date('Z', $value);
}
break;
...
If I deactivate it then all is fine, but then I have problems with date/datetime in Live-Workspace.
Updated by Sven Weiss over 15 years ago
I forgot:
The user who edits the record is in a workspace, not on Live-Workspace and not on Draft-Workspace.
Updated by Christian Kuhn over 15 years ago
Resolved as duplicate of #19928
Thanks Sven for the hint.