Bug: When mapping custom date field: A PHP Error was encountered (Undefined index: y)
Posted: 27 July 2010 06:11 PM   [ Ignore ]  
Newbie
Rank
Total Posts:  8
Joined  2010-07-26

When mapping a field to a custom field of type Date, the import succeeds, but when you edit the entry, following PHP error is displayed:

A PHP Error was encountered

Severity: Notice

Message: Undefined index: y

Filename: libraries/Localize.php

Line Number: 508

Steps to reproduce:
- Create a new channel Test
- Create a new custom field group: Test
- Add one field StartDate, with field type: Date
- Add this field group to the channel
- Create a csv-file, containing one line: “My first entry”,“2010-10-11”
- Use DataGrab to create a CSV import, for channel Test
- Map Title to Column 1
- Leave Date blank
- Map StartDate to Column 2
- Click “Do Import”
- Use Content -> Edit, and edit the newly created entry

Now the above error-message is displayed at the top.

Profile
 
 
Posted: 03 August 2010 05:29 PM   [ Ignore ]   [ # 1 ]  
Newbie
Rank
Total Posts:  3
Joined  2010-07-28

Any updates on this bug?  It seems a few posts were lost in the forums.

- Chris

Profile
 
 
Posted: 04 August 2010 02:53 PM   [ Ignore ]   [ # 2 ]  
Administrator
RankRankRankRank
Total Posts:  179
Joined  2006-04-12

This should now be fixed in the v1.0.1 release.

To download the new version go to your Purchases page.

Thanks,
Andrew

Profile
 
 
Posted: 05 August 2010 09:27 AM   [ Ignore ]   [ # 3 ]  
Newbie
Rank
Total Posts:  8
Joined  2010-07-26

A date field can now be imported.

But the same “Offset (in seconds)” as defined for the publish date field, should be applied for all date fields.

When I map the field “Date” and a custom field “First Release Date”, to the same field in a CSV file with value “2010-06-23”, I get 2 different dates when the entry is viewed in the CP:
Entry Date (standard EE field): 2010-06-23 02:00
First Release Date (custom field): 2010-06-22 22:00

As these fields are mapped to the same CSV field, they should have the same value.

Profile
 
 
Posted: 05 August 2010 07:28 PM   [ Ignore ]   [ # 4 ]  
Newbie
Rank
Total Posts:  8
Joined  2010-07-26

And when a custom date field is empty in the CSV file, the current date is now filled in when creating or updating the entry.

I don’t want this behaviour. The custom date field should be empty if no date value is present. If you have a field as. “Last modified” then you don’t want to have the current date in this field, if it’s empty.

Profile
 
 
Posted: 14 August 2010 03:27 PM   [ Ignore ]   [ # 5 ]  
Newbie
Rank
Total Posts:  8
Joined  2010-07-26

Should I create a new topic for the issues mentioned in the above 2 posts? Or don’t you consider this as an issue?

Profile
 
 
Posted: 16 August 2010 10:10 AM   [ Ignore ]   [ # 6 ]  
Administrator
RankRankRankRank
Total Posts:  179
Joined  2006-04-12

Hi luvd,

The date offset issue should be fixed in the last release. Let me know if you still see a problem.

Your empty date suggestion is sensible and I’ll add that to my list of changes.

Thanks for you input with the module - it is very much appreciated.

Andrew

Profile