Project

General

Profile

Actions

Bug #73871

closed

Problem with date Field

Added by Juraj Sulek about 8 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2016-03-02
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

We have discovered one bug with date field

sql:
birthday date DEFAULT '0000-00-00',

TCA:
'birthday' => array(
'exclude' => 1,
'label' => 'Birthday',
'config' => array(
'dbType' => 'date',
'type' => 'input',
'size' => 7,
'eval' => 'date',
'checkbox' => 0,
'default' => '0000-00-00'
),
),

if the date in the field is bigger then 1.1.1970 all works fine. But if the date ist lower for example 1.1.1969. This happens:
- FE shows 1.1.1969 - OK
- BE list-view shows 1.1.1969 - OK
but if the record is open for editing the field is filled with date -1 DAY - in this case the date 31.12.1968


Related issues 2 (0 open2 closed)

Related to TYPO3 Core - Bug #69290: Dates get reduced by a day if before 1970Closed2015-08-24

Actions
Related to TYPO3 Core - Bug #37244: TCA date evaluation for dates lower 01-01-1970 failsClosed2012-05-17

Actions
Actions #1

Updated by Daniel Maier about 8 years ago

  • Status changed from New to Accepted

Conversion from Date to Timestamp and back does not work correct in this case (first conversion (on php-side) is done with configured phpTimeZone, the second one (on js-side) with UTC).

Can be reproduced using input_36 of styleguide-extension. Select a date lower to 1970 here (e.g. 31-12-1969). Each time the form is saved, the date is reduced by one day (e.g. 30-12-1969, next 29-12-1969, next 28-12-1969, and so on).

If date is set to 01-01-1970, no value is shown in the FormEngine.

Actions #2

Updated by Gerrit Code Review about 8 years ago

  • Status changed from Accepted to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/47025

Actions #3

Updated by Christian Kuhn about 8 years ago

input_36 and input_37 were added to tx_styleguide_elements of ext:styleguide to better test this.

Actions #4

Updated by Gerrit Code Review about 8 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/47025

Actions #5

Updated by Gerrit Code Review about 8 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/47025

Actions #6

Updated by Gerrit Code Review about 8 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/47025

Actions #7

Updated by Gerrit Code Review about 8 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/47025

Actions #8

Updated by Gerrit Code Review about 8 years ago

Patch set 1 for branch TYPO3_7-6 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/47099

Actions #9

Updated by Daniel Maier about 8 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #10

Updated by Christian Kuhn about 8 years ago

  • Status changed from Resolved to New

patch was reverted - still working on it.

Actions #11

Updated by Gerrit Code Review about 8 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/47115

Actions #12

Updated by Daniel Maier about 8 years ago

  • Status changed from Under Review to Resolved
Actions #13

Updated by Gerrit Code Review about 8 years ago

  • Status changed from Resolved to Under Review

Patch set 1 for branch TYPO3_7-6 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/47117

Actions #14

Updated by Daniel Maier about 8 years ago

  • Status changed from Under Review to Resolved
Actions #15

Updated by Benni Mack over 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF