This is a migrated thread and some comments may be shown as answers.

Features not working

3 Answers 139 Views
PivotGrid
This is a migrated thread and some comments may be shown as answers.
Stavros Menegos
Top achievements
Rank 1
Stavros Menegos asked on 25 Sep 2017, 03:13 PM

Hi,

I am using the latest version of Kendo UI i.e. 2017.3.921. I am trying to include in my solution the kendo-pivot but it seems that some of the features are not working:

1. The configuration option sortable enables the "Sort Ascending / Descending" options in the pivot grid BUT when clicked they do nothing. I tried in local binding demo and added the sortable: true just below the filterable property, and it does not work. I tied the same in the documentation of the sortable configuration setting but the dojo example does nothing

2. I have a kendo-pivot bound to a datasource with remote data of json type. I perform a read operation, the kendo pivot as well as the kendo configurator is populated with data. The pivot has only one Row dimension and no column fields (one measure, only). Should I expand the Row dimension to all its values and force a requery i.e. datasource.read() again the read function of the transport definition is execute OK BUT the statement options.sucess fails with the exception "cannot read property value of undefined"

 

function preparePivotDS(espqParams, esOptions) {
                var qParams = angular.isFunction(espqParams) ? espqParams() : espqParams;
 
                var xParam = {
                    transport: {
                        requestEnd: function(e) {
                            var response = e.response;
                            var type = e.type;
                            console.log(type); // displays "read"
                            console.log(response.length); // displays "77"
                        },
 
                        read: function(options) {
 
                            var pqOptions = {};
 
                            var executeParams = qParams.Params;
                            if (executeParams instanceof esGlobals.ESParamValues) {
                                if (!executeParams.isValidState()) {
                                    var err = new Error($translate.instant("ESUI.PQ.PARAMS_MISSING"));
                                    options.error(err);
                                    throw err;
 
                                }
                                executeParams = executeParams.getExecuteVals();
                            }
 
                            esWebApiService.fetchPublicQuery(qParams.GroupID, qParams.FilterID, pqOptions, executeParams)
                                .then(function(pq) {
                                    pq = pq.data;
                                    options.success(pq.Rows || []);
                                })
                                .catch(function(err) {
                                    $log.error("Error in DataSource ", err);
                                    options.error(err);
                                });
                        },
 
                    }
                };
 
                if (esOptions) {
                    angular.extend(xParam, esOptions);
                }
 
                return new kendo.data.PivotDataSource(xParam);
            }

3 Answers, 1 is accepted

Sort by
0
Stavros Menegos
Top achievements
Rank 1
answered on 25 Sep 2017, 04:00 PM

For the sorting issue, I found a similar thread in this forum, stating that sorting is only available to Olap data. The documentation of the sortable configuration property does not clarify this. Furthermore, I agree with a fellow reader, that in that case the sort icons and menus should be visible / available to the user.

Apart from that, should Progress is willing to support kendo-pivot on non olap data, then sorting should be supported. At least present the data sorted by measures either ascending or descending and not in the random order that are now presented.

 

0
Konstantin Dikov
Telerik team
answered on 27 Sep 2017, 11:01 AM
Hello Stavros,

As documented in the following help topic, "The Kendo UI PivotDataSource has limited support for binding to flat data. Note that in this scenario not all of the features that are available when the widget is bound to an OLAP cube (such as sorting, hierarchies, and other) are supported."
As for introducing those features with the flat binding, you could vote in for the feature request in the public portal in order to increase their priority or log new ones:


Regards,
Konstantin Dikov
Progress Telerik
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Alex Hajigeorgieva
Telerik team
answered on 18 Nov 2020, 11:21 AM

Hello,

I am pleased to let you know that sorting by column and row headers with flat data is now implemented as of 2020 R3 release. You can take a look at the online demo:

https://demos.telerik.com/kendo-ui/pivotgrid/local-flat-data-binding

You can enable the sortable options in the field menu by adding sortable:true to the configuration options:

https://docs.telerik.com/kendo-ui/api/javascript/ui/pivotgrid/configuration/sortable

Regards,
Alex Hajigeorgieva
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
PivotGrid
Asked by
Stavros Menegos
Top achievements
Rank 1
Answers by
Stavros Menegos
Top achievements
Rank 1
Konstantin Dikov
Telerik team
Alex Hajigeorgieva
Telerik team
Share this question
or