Sch.panel.SchedulerGrid Print Error in Calendar Mode

Community plugins and extensions
Post Reply
User avatar
wekesageorge
Posts: 1
Joined: Tue May 23, 2017 6:20 pm

Sch.panel.SchedulerGrid Print Error in Calendar Mode

Post by wekesageorge »

Error
Error
Screen Shot 2017-05-23 at 7.06.07 PM.png (264.32 KiB) Viewed 4042 times
Hey,

Am having trouble using the Scheduler print / Export plugins. Am getting the error ‘Cannot read property 'isGroupHeader' of undefined’ , when I set the “Mode” config of my ‘Sch.panel.SchedulerGrid’ panel to “calendar” ,but yet when i Create it In any other mode with defined columns like in the basic example in the documentation, It works just Fine.

Below is sample code to replicate the Error

Code: Select all

/*
Copied from Bryntum Docs
*/
Ext.onReady(function() {

    // Store holding all the resources
    var resourceStore = new Sch.data.ResourceStore({
        model   : 'Sch.model.Resource'
    });

    resourceStore.loadData([
        {
            Id      : 'a',
            Name    : 'Rob'
        },
        {
            Id      : 'b',
            Name    : 'Mike'
        }
    ]);

    // Store holding all the events
    var eventStore = new Sch.data.EventStore({
        model   : 'Sch.model.Event',

        data    :  [   
            {
                ResourceId      : 'a',
                Name            : 'Some task', 
                StartDate       : '2010-05-22 10:00',
                EndDate         : '2010-05-22 12:00'
            },
            {
                ResourceId      : 'b',
                Name            : 'Some other task', 
                StartDate       : '2010-05-22 13:00',
                EndDate         : '2010-05-22 16:00'
            }
        ]
    });

    var startDate = new Date(2010, 4, 22, 6);

    var  scheduler = new Sch.panel.SchedulerGrid({
        width       : 600,
        height      : 200,

        // Setup view configuration
        startDate   : startDate,
        startTime: 6,
	    endTime: 23,
        mode:'calendar',
calendarTimeAxisCfg : {
		height : 30
	},
        showTodayLine : true,

plugins         : [

           Ext.create('Sch.plugin.Export', {
               printServer : 'server.php'
           })

    ],
		highlightCurrentTime : true,
        viewPreset  : 'weekAndDay',
        resourceStore   : resourceStore,
        eventStore      : eventStore
    });

   scheduler.render(Ext.getBody());
});
For the code above, if you call the showExportDialog( ) method, and then go ahead to click the Export button, It will throw an Error : ‘Cannot read property 'isGroupHeader'.

Any help will Be appreciated, Thanx

User avatar
mats
Core Developer
Core Developer
Posts: 16460
Joined: Sat Dec 19, 2009 11:41 pm
Location: Sweden
Contact:

Re: Sch.panel.SchedulerGrid Print Error in Calendar Mode

Post by mats »

Opened a ticket for review, thanks for the report!

https://app.assembla.com/spaces/bryntum ... rk/details#
Tired of debugging javascript errors in web applications? Try our new error logging service RootCause, or read more on the Sencha blog

@bryntum
Facebook
API documentation

Post Reply