Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

DataObjectManager Module /

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, Ed, biapar, Willr, Ingo, swaiba

DatePickerField not popping up calendar


Go to End


30 Posts   9613 Views

Avatar
Shawn Parr

Community Member, 60 Posts

9 September 2009 at 6:32am

I'm running SS 2.3.3 and the SVN checkout of the DataObjectManager and associated modules from around 11AM today (9.8.09). I was using a previous SVN checkout.

Using DatePickerField in a CMS popup doesn't work. The field appears, but you can't enter data, and the calendar view never appears either by clicking on or tabbing into the field.

I'm trying to figure it out, but am going slowly and have had no luck thus far.

It seems like the JS is just not working for some reason. I'm gonna take a look at it, but I'm pretty weak at JS.

Any ideas?

Avatar
UncleCheese

Forum Moderator, 4102 Posts

9 September 2009 at 6:45am

The demo site http://eventcalendar.bluehousegroup.com always has the latest DOM and EventCalendar modules installed. Let me know if you can replicate the error there. I cannot.

Avatar
Shawn Parr

Community Member, 60 Posts

9 September 2009 at 7:04am

Okay, now this is really driving me crazy. It works on your Event Calendar and DOM (http://dataobjectmanager.carlinowebdesign.com) sites, although I swear this morning when I tried it on that second test site it also didn't work there.

My site still isn't working, and I've updated from your SVN at least twice today. I've ran a DIFF of the files your SVN says you have changed and they all seem to appear in my files also. I'm pretty sure I haven't made any changes that would affect things loading in the admin side (only custom template files for the front end).

I've ?flush=all and went into /tmp/ to remove all the temp files SS uses in case of weird caching issues. I've also cleared out my browser caches, and it doesn't work in my system on either Safari or Firefox, but seems to work in both on your sites.

I'm gonna continue to dig into it, has to be some css/js thing. It appears all the requirements are loading, etc. It's driving me insane though, as it worked totally find in 2.3.1 with a snapshot of your modules from a couple months back.

I'm testing both in the vanilla Event Calendar, and in a module I created for our site. Same effect in both locations.

If anyone has any ideas, please share!

Avatar
UncleCheese

Forum Moderator, 4102 Posts

9 September 2009 at 7:28am

Running 2.3.3? Any Javascript errors? If you're running Firebug, it helps to kick out the popup to its own tab by right clicking on the frame. That way you can get a good look at any JS errors.

If it's something like "(this).datepicker() is not a function" it is a bug I resolved earlier this morning (and didn't push up to the demo until this afternoon, which explains your differing results).

Avatar
Shawn Parr

Community Member, 60 Posts

9 September 2009 at 9:28am

I hadn't thought to pop it out to its own frame and watch the firebug console. I'm getting four errors, definitely the problem:

jQuery is not defined

So obviously jQuery is not being properly loaded on our system for some reason. I'll dig into that.

Avatar
UncleCheese

Forum Moderator, 4102 Posts

9 September 2009 at 12:17pm

It should be pulling in jsparty/jquery/jquery.js.

Avatar
Shawn Parr

Community Member, 60 Posts

9 September 2009 at 12:23pm

Yeah, 'should be' being the key phrase there. :)

I'm away from work right now, so I don't remember which file I saw it in, but there is a Require::Javascript(THIRDPARTY_DIR . '/jquery/jquery.js') and several more. Maybe in LeftandMain.php? When I check in Firefox it really doesn't seem to be loading though. Which is quite weird as I would expect much more of the system to be borked than just the DateFieldPicker, but the rest of the system seems to be working, I can create, reorder, and save/publish pages, the whole 9 yards.

It is probably something simple, but if anything it has to do with our switch from 2.3.1 to 2.3.3. Maybe a core file didn't get the memo or something. When I get it working again I'll drop a note on what did it, just in case someone else out there has as bad of luck as I did this time around.

Avatar
UncleCheese

Forum Moderator, 4102 Posts

9 September 2009 at 1:23pm

Just remember that the popup controller is not part of LeftAndMain. It has its own set of requirements.

Go to Top