orb icon indicating copy to clipboard operation
orb copied to clipboard

function n(e){return null!=e?e.toString():""} error when we shift 2 columns headers

Open gauravraheja opened this issue 8 years ago • 3 comments

when we change position of a column header from one position to another (as column only) it gives following error function n(e){return null!=e?e.toString():""}

orb pivot table javascript library

gauravraheja avatar Jul 12 '17 22:07 gauravraheja

To the Author, Can you at least provide us where the code is located, I have stepped through the functions getvlaue, movefield conputeValues, but I can't pinpoint where the part the values is displayed so I can insert an eval or an equivalent.

Yeng77 avatar Aug 18 '17 04:08 Yeng77

I am facing the same issue, All will try to look into it, So if anyone can point us where the issue is that will be very appreciate.

Thanks

mydaypower1 avatar Sep 11 '17 08:09 mydaypower1

@gauravraheja Replace below code, it will work.

function mergefieldconfigs() {

                var merged = {
                    configs: [],
                    sorts: [],
                    subtotals: [],
                    functions: [],
 
                };

                for (var i = 0; i < arguments.length; i++) {
                    var nnconfig = arguments[i] || {};
                    merged.configs.push(nnconfig);
                    merged.sorts.push(nnconfig.sort || {});
                    merged.hideGrandTotal.push(nnconfig || {});
                    merged.subtotals.push(nnconfig.subTotal || {});
                    merged.dataType.push(nnconfig || {});
 


                    merged.functions.push({
                        aggregateFuncName: nnconfig.aggregateFuncName,
                        aggregateFunc: (nnconfig.aggregateFunc ? nnconfig.aggregateFunc() : null),  
                        formatFunc: (nnconfig.formatFunc ? nnconfig.formatFunc() : null),
                    });
                }

                return merged;
            }

katherdx avatar Nov 16 '17 14:11 katherdx