jQWidgets Forums

jQuery UI Widgets Forums Grid Grid Grouping problem

This topic contains 1 reply, has 1 voice, and was last updated by  dpdragnev 12 years, 3 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • Grid Grouping problem #18472

    dpdragnev
    Member

    Hi,

    I have a grid which I would like to group by 3 columns. Here is my code:

    var source =
    {
    datatype: ‘json’,
    datafields:
    [
    { name: ‘EmpId’, type: ‘number’ },
    { name: ‘EmployeeTitleId’, type: ‘number’ },
    { name: ‘Shift’, type: ‘number’ },
    { name: ‘StatusId’, type: ‘number’ },
    { name: ‘EmployeeGroup’, type: ‘string’ },
    { name: ‘ShiftName’, type: ‘string’ },
    { name: ‘StatusName’, type: ‘string’ },
    { name: ‘Name’, type: ‘string’ },
    { name: ‘Day1’, type: ‘string’ },
    { name: ‘Day2’, type: ‘string’ },
    { name: ‘Day3’, type: ‘string’ },
    { name: ‘Day4’, type: ‘string’ },
    { name: ‘Day5’, type: ‘string’ },
    { name: ‘Day6’, type: ‘string’ },
    { name: ‘Day7’, type: ‘string’ }
    ],
    id: ‘EmpId’,
    url: ‘/Home/GetSchedule/’ + $(“#ScheduleId”).val()
    }

    var dataAdapter = new $.jqx.dataAdapter(source);

    $(“#grd”).jqxGrid(
    {
    width: 960,
    source: dataAdapter,
    theme: theme,
    editable: false,
    columnsresize: true,
    groupable: true,
    groups: [‘EmployeeGroup’, ‘ShiftName’, ‘StatusName’],
    showgroupsheader:false,
    columns: [
    { text: ‘Name’, datafield: ‘Name’, width: 140 },
    { text: ‘MON’, datafield: ‘Day1’, width: 100 },
    { text: ‘TUE’, datafield: ‘Day2’, width: 100 },
    { text: ‘WED’, datafield: ‘Day3’, width: 100 },
    { text: ‘THU’, datafield: ‘Day4’, width: 100 },
    { text: ‘FRI’, datafield: ‘Day5’, width: 100 },
    { text: ‘SAT’, datafield: ‘Day6’, width: 100 },
    { text: ‘SUN’, datafield: ‘Day7’, width: 100 }
    ],
    id: ‘EmpId’
    });

    I have search all the documentation and everything seems to be in order with the code listed above. However, when I execute the script, I get a blank grid with the scroll bars indicating that there are rows there, but not visible. If I scroll down, the rows appear, however the grouping is all messed up, the expanding and contracting does not work and the group headers are not visible. When I check my JS error console I see the following error: Type Error: l is null.

    I am using jqWidgets 2.7,  jQuery 1.8.3 and jQuery UI 1.10.0.Any help is greatly appreciated.

    Thank you.

    Grid Grouping problem #18474

    dpdragnev
    Member

    I solved the problem by upgrading my jQuery and jQWidgets versions.

    Thanks.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.