Download & Extend

Date argument not recognized as date in calendar view

Project:Calendar
Version:6.x-2.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

Upgrading a 5.x to 6.x install.

Date 6.x-2.0-rc6. CCK 6.x-2.1. Views 6.x-2.2.

I have four node types with a CCK date field (the same field - field_event_date). I would like to use this as the date field for the calendar view (as I had in version 5.x). But - when I remove the post date and add this date field I get

<?php
The calendar_nav style requires a Date argument
.
?>

Views has recognised the field as a date to be chosen when adding the argument - but - on update from that - it gives this error.

Not sure what's wrong here - this is the third upgrade I've done and the other two have gone OK (with date CCK fields) - not exactly the same of course - but pretty close.

Comments

#1

I have the same problem. I have a date argument, but it is for the starting date of an event, not the last updated date. Weirdest thing is that I've done this exact same thing before on another site (although with slightly older Drupal (6.6) and maybe older modules) and didn't have problems. :-/

I have the same exact setup as above, but I'm not upgrading - starting a site from scratch with Drupal-6.8.

#2

I just uninstalled calendar and views, and reinstalled them and tried something else. When I was changing the date argument last time, I deleted the existing date argument and added a new one. The new one was exactly the same except it was for the starting time of the event, not the last updated time. But it broke.

This time, instead I edited the existing date argument. I scrolled down and unchecked last updated, and checked event_datetime or whatever it was called. It works for me now.

Not sure why! But you might want to try that. Don't forget to export the views you want to keep so you can just import them instead of making them over again. If you did what you're supposed to do, and worked off of a "cloned" calendar view instead of the original one, you probably don't have to do the uninstalling/reinstalling.

#3

Hmm - yes. Editing the existing date field rather than removing it and adding another worked fine.

I'd classify that as a workaround rather than a fix though ;)

#4

Alright, I ran into this same problem while trying to fix an issue with event_date value always displaying 12-31-2008 (but that is for another thread). I buggered that one up pretty good, so I uninstalled Calendar like the previous poster and recovered the calendar (like I said, buggered good).

When I created a new date argument, I got those great pink errors all over the place. Idea: since it was too late to edit the existing Date: date argument, I simply deleted all of the arguments and fields. More pink errors. Now when I very carefully this time, recreate the arguments THEN add the Fields, errors go away!

Ta da!

Now all I have to do is figure out this incorrect date (only for the start date, weird).

#5

I just thought I would let you know I am having the same problem. Let me know if you need more info. For now, I'll reinstall the module.

#6

#4 scottsawyer: THX! :-)

#7

Version:6.x-2.0-rc6» 6.x-2.x-dev

Would this issue be related to the error message:

Error: handler for node > date_argument doesn't exist!

section is arguments
display is defaults
view is calendar.

I have date 6.x-2.0-rc6 and views 6.x-2.3.

#8

I have the same problem.

In a view, when I use a CCK date field as argument, I have this error message : "The calendar_nav style requires a Date argument".

I can display the CCK date field, I can use it for sorting, but I can't use it as argument.

#9

Still don't have a resolution to my issue.

So, i simply uninstalled everything, i.e. calendar, views, date.

uninstall doesn't seem to do much. There are still references in the database and the module still sits in the /modules directory.

When reinstalling. I installed views 2 first, Tested it. Then installed date, set up the default dates, tested views. Created content type with Date field. Then installed calendar. The was no longer an error.

Before I actually went thru the uninstall, reinstall process, i set up a test website that only included CCK, Views2, Date and Calendar as additional modules. There was no error.

Tom

#10

i just wanted to mention that a reinstall was not actually necessary. i simply had to reset the view to the default and edit it according to #4.

#11

Status:active» fixed

Views stores a lot of information stored in caches and even in your SESSION so sometimes when you update code you still have old, invalid, values in your cache that create problems like this. Sometimes you can fix things by editing and re-saving each part that is creating the problem, sometimes you need to delete it and re-add it, and sometimes you need to competely revert the calendar and start over to clean things up.

Not a lot I can do to fix this, I can't control what is cached nor have I been able to find a reliable way to clear out your cached values without accidentally wiping out things that shouldn't get wiped out.

If things work correctly if you start over or on a new install, it's coming from this kind of situation.

#12

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

#13

Ver:
- calendar-6.x-2.2
- date-6.x-2.4
- views-6.x-2.8

I have the same problem. The "Content: Date (field_event_date) - From date
Datetime - Appears in: Calendar Event" and "Content: Date (field_event_date) - To date
Datetime - Appears in: Calendar Event" both disappeared from the arguments group content list.

These fields are available in Fields and Sort section.

Tried to clear the cache, reinstall calendar (from dev menu), uninstall the module, but no success. Any solution? Thanks.

#14

I have also noticed that those fields are disappeared from all the views arguments group list, but available in Fields and Sort Order section. Thanks.

#15

Solved. Started and configured from the beginning after resetting views. I should not have deleted the argument item. Thanks.

#16

Status:closed (fixed)» fixed

in Views, just rearrange your custom Fields(your custom argument) to be the first one in the list, That is it !

#17

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

#18