yamrajsingh / iredmail

Automatically exported from code.google.com/p/iredmail
0 stars 0 forks source link

iRedAdmin pro table headers only sort within current page #68

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
- Which OS and version are you running?
- Which version of iRedMail and/or iRedAdmin-Pro are you running?

What steps will reproduce the problem?
1. View an iRedAdmin section with a sortable table and multiple pages
2. Click on table header to sort

What is the expected output? What do you see instead?
Should return sorted list of results within entire result set. Instead just 
sorts current page. JQuery table sorter needs placing with a proper server side 
sorting throughout, or ALL results need to be outputted by python and use 
JQuery tablesort pagination instead where possible. Sorting is more or less 
useless currently and may as well be removed.

What version of the product are you using? On what operating system?
Ubuntu 10.04 - latest iRedMail and iRedAdmin-Pro

Please provide any additional information below.

Original issue reported on code.google.com by msjwoz...@gmail.com on 19 Aug 2011 at 12:51

GoogleCodeExporter commented 8 years ago
Can you capture a screenshot and mail me <zhb@ iredmail.org> to help me 
understand this issue?

Original comment by michaelb...@gmail.com on 19 Aug 2011 at 1:34

GoogleCodeExporter commented 8 years ago
Thanks very much for your feedback, detailed description and screenshots, it 
helps a lot.

Short answer, it works as designed.

It returns 50 entries in one page, e.g. Page 1, when viewing page 2, it queries 
SQL database to get another 50 entries with SQL command like below:

SELECT * FROM table_name WHERE xxx LIMIT 50 OFFSET 51

The key is 'OFFSET 51'.

jQuery just sorts returned entries, not re-query SQL to get 50 entries with 
command 'ORDER BY spam_level', so it cannot work as you expect with current 
design. Sorry.

Original comment by michaelb...@gmail.com on 19 Aug 2011 at 2:38