My favorites | Sign in
Project Home Issues
New issue   Search
for
  Advanced search   Search tips   Subscriptions
Issue 1733: Support for Zend Framework 2 Json output
1 person starred this issue and may be notified of changes. Back to list
Status:  Duplicate
Merged:  issue 2166
Owner:  ----
Closed:  Aug 2013


Sign in to add a comment
 
Reported by Tomasz.K...@gmail.com, Mar 13, 2013
Hi Adam,

At first I would like to congratulate you so good work, as jQuery Calendar seems to be.

I am working on integration the calendar, that you made with Zend Framework 2, with which I am currently working on.

The problem is Zend will output JSON like following:
{
	"events" : [{
		"id" : 14,
		"title" : "New Year",
		"start" : "2013-01-01",
		"end" : "2013-01-01",
		"allDay" : true
	}, {
		"id" : 15,
		"title" : "Epiphany",
		"start" : "2013-01-06",
		"end" : "2013-01-06",
		"allDay" : true
	}, {
		"id" : 16,
		"title" : "Easter Sunday",
		"start" : "2013-03-31",
		"end" : "2013-03-31",
		"allDay" : true
	}, {
		"id" : 17,
		"title" : "Easter Monday",
		"start" : "2013-04-01",
		"end" : "2013-04-01",
		"allDay" : true
	}],
	"success" : true
}

So data is not in the root of the JSON data, but in some variable.
I fixed this problem by adding 'root' option to the config.

I can send you the modified code.
It is just a few lines.

I'm looking forward to hearing from you.

--
Very best,
Tomasz Kuter
evolic@interia.pl
Aug 23, 2013
Project Member #1 adamrs...@gmail.com
you'd want to massage the data using eventDataTransform:
http://arshaw.com/fullcalendar/docs/event_data/eventDataTransform/
Status: Done
Aug 24, 2013
#2 Tomasz.K...@gmail.com
Hi there,

Thanks for the reply.
I missed that option in the docs.
I will rewrite the code to use this ability of the fullcalendar.

I made a simple demo application in the Zend Framework 2
using Twitter Bootstrap and writing custom wrapper
for the FullCalendar class.

It is available at: (events has Polish names)
http://zf2fullcalendar.tomaszkuter.com/events/calendar.html

Code is stored in the GitHub:
https://github.com/evolic/zf2-tutorial/tree/calendar
https://github.com/evolic/zf2-tutorial/blob/calendar/public/js/evl-calendar/zCalendarWrapper.js
https://github.com/evolic/zf2-tutorial/blob/calendar/module/EvlCalendar/view/evl-calendar/events/calendar.phtml

In the close future I will try to extend my wrapper to support events attached to many calendars, like in Google Calendar app (each calendar uses different color).

Any suggestions or comments to my code will be appreciated.

--
Best regards,
Tomasz Kuter
Jun 5, 2014
Project Member #3 adamrs...@gmail.com
i understand my initial misunderstanding. i made  issue 2166  (merging) to address..
Status: Duplicate
Mergedinto: 2166
Sign in to add a comment

Powered by Google Project Hosting