Fatal JS error when filtering when enableVirtualization = true

Example link - http://www.tgmt-systems.com/syncFusion/index.jsp

Reproduce Steps Video - http://www.tgmt-systems.com/syncFusion/pivotError.mp4


If the pivot table has the property enableVirtualization = true, in certain scenarios, a fatal JavaScript error occurs. Please see video for reproduce steps.


  1. Filter for the number 1 - Click OK
  2. Filter For Number 2 - Click OK
  3. In Filter popup Select ALL
  4. Filter for Number 2 - Click OK
  5. Error occurs.

ej2.min.js:10 Uncaught TypeError: Cannot read properties of undefined (reading 'name')

    at e.getIndexedHeaders (ej2.min.js:10:13860788)

    at e.performFilterCommonUpdate (ej2.min.js:10:13848834)

    at e.onFilter (ej2.min.js:10:13844192)

    at e.<anonymous> (ej2.min.js:10:14356325)

    at e.notify (ej2.min.js:10:737590)

    at t.e.trigger (ej2.min.js:10:766841)

    at t.updateDataSource (ej2.min.js:10:14355355)

    at e.updateDataSource (ej2.min.js:10:14519014)

    at e.<anonymous> (ej2.min.js:10:14531911)

    at e.notify (ej2.min.js:10:737590)


8 Replies

SP Sastha Prathap Selvamoorthy Syncfusion Team May 12, 2022 12:27 PM UTC

Hi Thierry,


We can be able to reproduce the problem and we are validating it at our end. We will update further details by tomorrow (May 13, 2022).


Regards,

Sastha Prathap S



TT Thierry Tremblay May 12, 2022 02:03 PM UTC

Great Thank you - Looking forward to the fix



AP AngelinFaithSheeba PaulvannanRajadurai Syncfusion Team May 13, 2022 12:30 PM UTC

Hi Thierry,


We are unable to reproduce the reported issue with the latest package at our end. So please update the package to the latest version (V20.1.55). Meanwhile, we have prepared a sample for your reference.


Sample: F9ozb1 (forked) - StackBlitz


If the problem persists, please reproduce it in the provided sample and revert to us (or) send your sample that replicates the problem. This would allow us to investigate the reported problem at our end and provide a solution as soon as possible. 


Regards,

Angelin Faith Sheeba



TT Thierry Tremblay May 13, 2022 12:43 PM UTC

Hi,


I am sorry but it is very reproducible with version 20.1.55. See the live example at http://www.tgmt-systems.com/syncFusion/index.jsp


This page uses version 20.1.55.


If you repeat those exact steps ( http://www.tgmt-systems.com/syncFusion/pivotError.mp4  ):


  1. Filter for the number 1 - Click OK
  2. Filter For Number 2 - Click OK
  3. In Filter popup Select ALL
  4. Filter for Number 2 - Click OK
  5. Error occurs.

You get the following FATAL JS error:

ej2.min.js:10 Uncaught TypeError: Cannot read properties of undefined (reading 'name')

    at e.getIndexedHeaders (ej2.min.js:10:14009322)

    at e.performFilterCommonUpdate (ej2.min.js:10:13997898)

    at e.onFilter (ej2.min.js:10:13993256)

    at e.<anonymous> (ej2.min.js:10:14510024)

    at e.notify (ej2.min.js:10:755901)

    at t.e.trigger (ej2.min.js:10:785109)

    at t.updateDataSource (ej2.min.js:10:14509054)

    at e.updateDataSource (ej2.min.js:10:14672281)

    at e.<anonymous> (ej2.min.js:10:14685166)

    at e.notify (ej2.min.js:10:755901)


Could you please provide a fix, since we have users affected by this bug.


Regards.



TT Thierry Tremblay May 13, 2022 12:44 PM UTC

this only happens IF the pivot table has the property enableVirtualization = true



TT Thierry Tremblay May 13, 2022 12:48 PM UTC

In the example provide if you use the following it it also reproducible with those steps:


dataSourceSettings: {
    enableSorting: true,
    columns: [],
    valueSortSettings: { headerDelimiter: ' - ' },
    values: [{ name: 'Amount' }],
    dataSource: getPivotData(),
    rows: [
      { name: 'Sold'caption: 'Units Sold' }
    ],
    formatSettings: [{ name: 'Amount'format: 'C0' }],
    expandAll: false,
    filters: [],
  },


AP AngelinFaithSheeba PaulvannanRajadurai Syncfusion Team May 13, 2022 01:35 PM UTC

Hi Thierry,


We have considered this as a bug Script error throws while filtering with virtualization. And this fix will be available in our upcoming weekly release which is estimated to be rolled out in the mid of June 2022. You can track the same by using below link.


https://www.syncfusion.com/feedback/34907/script-error-throws-while-filtering-with-virtualization


Please let us know if you have any concerns.


Regards,

Angelin Faith Sheeba.




AP AngelinFaithSheeba PaulvannanRajadurai Syncfusion Team May 31, 2022 10:52 AM UTC

Hi Thierry,


We are glad to announce that our Essential Studio weekly release V20.1.57 is rolled out and fix for the issue “Script error throws while filtering with virtualization” has been included in this release. Please refer to the following sample.


Sample: https://stackblitz.com/edit/mqhmp5-vjafos?file=index.js


Release Notes: https://ej2.syncfusion.com/javascript/documentation/release-notes/20.1.57/?type=all#pivot-table


We thank you for your support and appreciate your patience in waiting for this release. Please contact us if you require any further assistance.


Regards,

Angelin Faith Sheeba.


Loader.
Up arrow icon