SearchPanes v2.0.0 viewCount displays 0 with Orthogonal data type == 'sp'

SearchPanes v2.0.0 viewCount displays 0 with Orthogonal data type == 'sp'

SDU RIO AnalyticsSDU RIO Analytics Posts: 8Questions: 4Answers: 0
edited March 21 in SearchPanes

Link to test case: None.
Debugger code (debug.datatables.net): No error reported.
Error messages shown: None in the JS console.
Description of problem: When upgrading SearchPanes from v.1.4.0 to v2.0.0 the searchPanes.viewCount does not display / compute the count for certain columns. It seems to happen on columns modified by Orthogonal data type == 'sp'.

DataTables.net SearchPanes v2.0.0 viewCount displays 0 with Orthogonal data type == 'sp'

Temporary workaround: Revert to SearchPanes v.1.4.0.

DataTables.net SearchPanes v1.4.0 viewCount working

Answers

  • colincolin Posts: 14,303Questions: 1Answers: 2,431

    We're happy to take a look, but as per the forum rules, please link to a test case - a test case that replicates the issue will ensure you'll get a quick and accurate response. Information on how to create a test case (if you aren't able to link to the page you are working on) is available here.

    Cheers,

    Colin

  • SDU RIO AnalyticsSDU RIO Analytics Posts: 8Questions: 4Answers: 0

    Here is a test case: https://codepen.io/jv-conseil/pen/NWXRQQb

    It fails to reproduce the unwanted behaviour.

    Even though in real life use, I finally managed to correct the issue by switching all type === "searchpanes" to type === "display" in render function.

    render: function (data, type) {
     return type === "searchpanes"
     ? data
     : '<a href="https://datatables.net/forums/discussion/72109/searchpanes-v2-0-0-viewcount-displays-0-with-orthogonal-data-type-sp">' +
     data +
     "</a>";
    }
    
Sign In or Register to comment.