jQuery PivotGridV2 remote flat data wont load

0 Answers 2 Views
PivotGridV2
Moh
Top achievements
Rank 1
Moh asked on 15 Sep 2025, 05:23 AM

Hi,
I’m moving from PivotGrid (v1) to PivotGridV2 on Kendo UI for jQuery 2025.3.825 with an ASP.NET MVC (.NET 8) backend.
In v1 my grid called the controller just fine. In V2, the grid renders, but no data is loaded from the controller and the console keeps showing:
TypeError: Cannot read properties of undefined (reading 'cube')

If I feed local flat data, V2 renders correctly — so my fields, cube, rows/columns/measures seem fine. The problem appears only when I switch to remote flat binding.

What I expect
- PivotGridV2 (client cube / flat binding) to call my MVC action via transport.read and render the returned rows.
- Built-in Excel export to work (it does, when data is present).

What I see
- requestStart fires, then I get a transport error, followed by the “reading 'cube'” error.
- With local data injected, the table renders fine (so the cube + axes look OK).


Code :

const pg = $("#pivotgrid").kendoPivotGridV2({
  height: 570,
  columnTotals: false,
  rowTotals: false,

  dataSource: new kendo.data.PivotDataSourceV2({
    transport: {
      read: {
        url: '@Url.Action("GetPivotData", "ControllerPivot")',
        type: "POST",
        dataType: "json"
        // (also tried contentType: "application/json" + JSON.stringify in parameterMap)
      },
      parameterMap: function () {
        return {
          year: $("#yearDDL").data("kendoDropDownList")?.value(),
          periode: $("#periodDDL").data("kendoDropDownList")?.value()
        };
      }
    },

    schema: {
      // if server returns { data:[...] } I can switch this on:
      // data: "data",
      model: {
        fields: {
          Version:   { type: "string" },
          Period:    { type: "string" },
          Parameter: { type: "string" },
          Value:     { type: "number" }
        }
      },
      cube: {
        dimensions: {
          Version:   { dataMember: "Version" },
          Period:    { dataMember: "Period" },
          Parameter: {
            caption: "Parameter",
            hierarchies: [{
              name: "By Parameter",
              levels: [{ name: "Parameter", field: "Parameter" }]
            }]
          }
        },
        measures: {
          Value: { field: "Value", aggregate: "sum", format: "{0:n2}" }
        }
      }
    },

    columns:  [{ name: "Version",   expand: true }],
    rows:     [{ name: "Parameter", expand: true }],
    measures: ["Value"],

    requestStart: e => console.log("[requestStart]", e),
    requestEnd:   e => console.log("[requestEnd]", e),
    error:        e => console.error("[transport error]", e)
  })
}).data("kendoPivotGridV2");

$("#configurator").kendoPivotConfiguratorV2({
  dataSource: pg.dataSource, updateOnApply: true, filterable: true, height: 570
});
Is there a minimal working example for jQuery PivotGridV2 remote flat binding on 2025.3.825 I can compare with?



Environment

  • Kendo UI for jQuery 2025.3.825

  • PivotGridV2 + PivotConfiguratorV2

  • ASP.NET MVC (.NET 8) backend



No answers yet. Maybe you can help?

Tags
PivotGridV2
Asked by
Moh
Top achievements
Rank 1
Share this question
or