CodeIgniter Forums
table sort in environment "development" - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28)
+--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30)
+--- Thread: table sort in environment "development" (/showthread.php?tid=83599)



table sort in environment "development" - Tom_LP - 10-09-2022

Dear all,
i have identified a little problem: If i have the environment "development" active, my tables are sortable. First i suggest it have to do with my used Framework (Fomantic).
Today i recognised when i´am switch to "production", the table´s are working as expected (without sorting !) and my own sorting functions are working correct.
It´s not a major issue, but looks strange for me Smile
Has anyone a glue where i can disable the behaviour of tables sorting, so that my tables are working as expected in Development-Mode too? I try to find the events behind, but has no luck...

kr Tom_LP
PS: used CI 4.2.6


RE: table sort in environment "development" - MMLTech - 11-01-2022

(10-09-2022, 03:15 PM)Tom_LP Wrote: Dear all,
i have identified a little problem: If i have the environment "development" active, my tables are sortable. First i suggest it have to do with my used Framework (Fomantic).
Today i recognised when i´am switch to "production", the table´s are working as expected (without sorting !) and my own sorting functions are working correct.
It´s not a major issue, but looks strange for me Smile
Has anyone a glue where i can disable the behaviour of tables sorting, so that my tables are working as expected in Development-Mode too? I try to find the events behind, but has no luck...

kr Tom_LP
PS: used CI 4.2.6


https://github.com/codeigniter4/CodeIgniter4/issues/6808


Created a hackfix that is not causing any errors.

1. Go to system\ThirdParty\Kint\resources\compiled\rich.js and beautify this js file
2. In line 183 comment the following

Code:
else
    e.ctrlKey || l.sortTable(t.parentNode.parentNode.parentNode, t.cellIndex)

Use this instead

Code:
else if($(t.closest('#debug-bar')).length)
                l.sortTable(t.parentNode.parentNode.parentNode, t.cellIndex)
            else
                e.ctrlKey

This will check if parent element is our debug bar.