ahecho wrote:Thanks a lot. But unfortunatelly the filtring itself seems to be a little bugy. It wont remember filter setting trought pagination as well.
I have looked into this problem, and I have found a fix, as it was easy enough. The reason this problem occurred is because, when you go to the next paginated page, there was no way for the system to know which filter settings you had, as this information was not passed along on to the next page.
Solving this is easy. Setting the form to get method instead of post will fix the first problem. This makes it so that the browser passes the form data using the url.
For some reason this was not implemented for filtering in the project time tracker, but it was implemented for the reports found in the user's profile.
Now that is one small part, the other is to use something, javascript or php, to get the data and to construct pagination links. This part was already done and is part of the collabtive code. This is why fixing this was easy.
The fix for this involves, in managetimetracker.php, under $action == "showproject", setting all the post methods to get, as post can not be used as now get is being used to submit the form data. Next thing, in filtertracker.tpl, setting the form method to get instead of post. This is all that is needed to fix this bug.
On top of this I have also added support for filtering to my "grand total hours" modifications.
On another note, while testing my modifications, I noticed that there seems to be some problems with the report filtering, found in user's profile. It seems if you filter with more then one task selected it seems that it ends up missing some tasks, so the total will be wrong. But on the other hand my "Grand total hours" modification actually does show the correct grand totals for those multiple tasks. Not sure what is going on there but I do not have time to investigate and provide a fix, this is going to be left for someone else to do.
You will find the modifications to add filtering support to my "grand total hours" modifications, in the attached zip file below. And on top of that I am also providing the fix for the above mentioned bug, where the filtering settings are lost after going to a paginated page.