Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > Developers' Forum

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 24th February 2012, 22:28
xaver xaver is offline
Member
 
Join Date: May 2009
Posts: 77
Thanks: 10
Thanked 25 Times in 14 Posts
Default Sort and limit in ispconfig

Hi,

i tested a little bit with few lines jquery and some changes in client_list.htm and client_list.php and listfrom.inc.php.
Right now the implementation is only testing. The limit is for all lists and sort is always for this list with session like the other filters.

Because screenshots are useless, i made a small video.
(HTML5 ogv,webm)
http://www.xwissen.info/web_log/2012...onfigsort.html

regards
xaver
Reply With Quote
The Following User Says Thank You to xaver For This Useful Post:
till (27th February 2012)
Sponsored Links
  #2  
Old 24th February 2012, 22:35
edge edge is offline
Moderator
 
Join Date: Dec 2005
Location: The Netherlands
Posts: 2,037
Thanks: 268
Thanked 152 Times in 132 Posts
Default

For me the video does not load (only showing a small red x) in IE.
It does work in Firefox.
__________________
Never execute code written on a Friday or a Monday.
Reply With Quote
  #3  
Old 24th February 2012, 22:38
xaver xaver is offline
Member
 
Join Date: May 2009
Posts: 77
Thanks: 10
Thanked 25 Times in 14 Posts
Default

Like i said only webm and ogv. IE support only h264 patent troll format. I don't use it.

edit:
i was more asking for feedback, i hope i can create a better version.
for me it works fine. Change Cursor to pointer and maybe show a hover effect like move the background image in the th.

Last edited by xaver; 24th February 2012 at 22:45.
Reply With Quote
  #4  
Old 25th February 2012, 02:22
kwickcut kwickcut is offline
Senior Member
 
Join Date: Nov 2005
Location: nj usa
Posts: 223
Thanks: 14
Thanked 11 Times in 10 Posts
Default

loaded and worked fine using ff


kwick
__________________
Operating system Ubuntu Linux 10.04.4
ISPConfig Version: 3.0.4.3
Webmin version 1.580
Kernel and CPU Linux 2.6.32-40-server on x86_64
Processor information AMD Phenom(tm) II X4 945 Processor, 4 cores
Real memory 4.0 GB total
Reply With Quote
  #5  
Old 27th February 2012, 10:11
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 36,421
Thanks: 834
Thanked 5,501 Times in 4,330 Posts
Default

Looks nice, but how do you do the sorting and limiting in the list? I guess you load all elements at once and then limit and sort them with ajax? My concern with that is how it scales if you have many thousand lines in a list.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
The Following User Says Thank You to till For This Useful Post:
XRumerTest (17th May 2014)
  #6  
Old 27th February 2012, 15:50
conceptnet conceptnet is offline
HowtoForge Supporter
 
Join Date: Feb 2011
Posts: 4
Thanks: 0
Thanked 2 Times in 1 Post
Default

Hello,

NO!

Limit is getQuery... function in list class. If a Limit isset, it will be saved in the session and override the actual limit from the class. (Limit is global)

Sort is nearly the same way. You have a order parameter with get (i use the class names from columes) + str_prelace and regex check.
Ifset it will be added infront of other sort params. If session isset and you click again it is Desc.

From performance no difference.
Reply With Quote
  #7  
Old 29th February 2012, 15:49
conceptnet conceptnet is offline
HowtoForge Supporter
 
Join Date: Feb 2011
Posts: 4
Thanks: 0
Thanked 2 Times in 1 Post
Default

Hello,

first patch finished for testing.

Includes:
Sorting in all lists
Limit select box in clients -> the limit is global for all lists in a session
ASC and DESC -> column names jumps on other site for UI.

Missing:
Add limit select box to every page (only in client)
Works only in combobox template -> system -> Users -> admin default_combobox. (Reason, ~15 jquery and 2 lines css missing in other templates. In final commit, i will patch all templates.)

Problems:
Quota Webspace (used,soft,hard,files) is not in database, i need to implement a Manuel sort *LATER* Site and webs able to sort.
Some empty columns have also css class names or wrong once and sorting is not working or wrong column
-> If you see such a column, plz post it. know is Web Quota

Bug/Improvement:
Right know system remembers is you change a site, but if you switch a site and sort another the sold sort is still in another list like filters .. BUT the UI change from listing is missing. Reason is i use only jquery and no new info.
-> I think this way is OK

Please test it and give feedback (positive or negative), but i wouldn't use it on a productive system. It should work, but maybe a list cant be shown -> MySQL Query error (no known problems).
Hello,

first patch finished for testing.

Includes:
Sorting in all lists
Limit select box in clients -> the limit is global for all lists in a session
ASC and DESC -> column names jumps on other site for UI.

Missing:
Add limit select box to every page (only in client)
Works only in combobox template -> system -> Users -> admin default_combobox. (Reason, ~15 jquery and 2 lines css missing in other templates. In final commit, i will patch all templates.)

Problems:
Quota Webspace (used,soft,hard,files) is not in database, i need to implement a Manuel sort *LATER* Site and webs able to sort.
Some empty columns have also css class names or wrong once and sorting is not working or wrong column
-> If you see such a column, plz post it. know is Web Quota

Bug/Improvement:
Right know system remembers is you change a site, but if you switch a site and sort another the sold sort is still in another list like filters .. BUT the UI change from listing is missing. Reason is i use only jquery and no new info.
-> I think this way is OK

Please test it and give feedback (positive or negative), but i wouldn't use it on a productive system. It should work, but maybe a list cant be shown -> MySQL Query error (no known problems).

(txt is allowed in upload -> normal .patch or nothing)

regards
xaver

Edit:
- If no sorting set, list is empty -> press a column head (i fix it...)
-> fixed in 29022012_1603 (always ordered, even empty value)
Attached Files
File Type: txt sorting_patch_29022012_1534.txt (6.1 KB, 50 views)
File Type: txt sorting_patch_29022012_1603.txt (6.2 KB, 38 views)

Last edited by conceptnet; 29th February 2012 at 16:05.
Reply With Quote
The Following 2 Users Say Thank You to conceptnet For This Useful Post:
till (29th February 2012), zbuzanic (4th March 2012)
  #8  
Old 1st March 2012, 02:24
xaver xaver is offline
Member
 
Join Date: May 2009
Posts: 77
Thanks: 10
Thanked 25 Times in 14 Posts
Default

Hello again,

problems: first sort (i fixed that local)

List of all listpages and status (i go form page to page / every site get the limit option / sometimes local state)

RED = Broken like in tab in zones or non existing column(s)
Purple = Works but mostly one or more columns uses IDs and not the join OR no Filter = no sort
Green = all orders should work and limit function

Italic -> fixed / solved / changed situation

admin
- cpusers
-- edit user -> username works / problem forename,name,city -> looks like a join
- system
-- server services
-- server config
-- server ip -> client_id,server_id sort -> join again
- firewall -> server_id sort -> join again
-Apps & addons
-- repo
-- Apps & Addon packages -> No Filter = no URL, no sort
-- Software updates -> No Filter = no URL, no sort
- Language Editor
-- Languages -> No Filter = no URL, no sort
- Remote Users
-- edit users -> username -> join again -> fixed

client
- clients
-- Edit Client
-- Client-Templates ADDED template_id
- reseller
-- Edit Reseller

dns
- dns wizard
-- templates
- dns
-- zones -> server_id -> join
- - - Records
- Secondary Zone
-- Secondary Zones -> server_id -> join

domain
- domains
-- domains -> user_txt missing -> sys_groupid missing

help
- Support
-- View Messages -> no idear, always empty, never used i cant see my send messanges.. but if i switch user, it works
- FAQ
-- Manage Section -> No Filter = no sort -> strange order of columns
-- Manage Section -> No Filter = no sort -> strange order of columns

email
- email accounts
-- domain -> server_id, parent_domain_id -> join
-- domain alias
-- email mailbox
-- email alias
-- email forward
-- email catchall
-- email routing -> server_id
- Mailing List
-- Mailing List
- Spam filter
-- Whitelist -> server_id,rid -> join
-- Blacklist -> server_id,rid -> join
-- User / Domain -> server_id,policy -> join
-- policy
- fetchmail
-- fetchmail -> server_id -> join
-Statisitics
-- Mailbox Quota -> SQL Error like other stats
-- Mailbox traffic -> SQL Error like other stats
- Global Filters
-- postfix whitelist -> server_id -> join (recipient_txt output)
-- postfix blacklist -> server_id -> join
-- Content filter -> server_id -> join
-- fetchmail -> server_id -> join

monitor
- system state (overview was green, but some updates available and under updates are blue...)
- show System-Log -> server_id -> join
- show Jobqueue -> server_id -> join

sites
- websites
-- website -> sys_groupid,server_id -> join again !!! Test normal user also, different list
- - -Existing backups no Filter
-- Subdomain -> server_id, parent_domain_id -> join
- ftp
-- ftp-user -> server_id, parent_domain_id -> join
- shell
-- shell-user -> server_id, parent_domain_id -> join
- database
-- database -> server_id, parent_domain_id -> join
- web-dav
-- web-dav -> server_id, parent_domain_id -> join
- folder protection
-- folder -> server_id, parent_domain_id -> join
-- folder user -> web_folder_id -> join
- Cron
-- Cron jobs -> server_id, parent_domain_id -> join
- Statistic
-- Web Traffic -> SQL error by month and year
-- Website quota -> i wrote already about this problem

vserver
- OpenVZ
-- Virtual Servers -> veid,server_id,ostemplate_id,ttemplate_id -> join
-- OS Templates -> server_id -> join
-- VM Templates
-- IP Addresses -> server_id -> join (+ title of vm_id is missing)

-> DONT FORGET PATCH IS ONLY default_combobox TEMPLATE

File update:
sorting_patch_03032012_0004.txt - Support DNS Zone Records sort

regards
xaver

Last edited by xaver; 4th March 2012 at 04:30.
Reply With Quote
  #9  
Old 3rd March 2012, 23:16
xaver xaver is offline
Member
 
Join Date: May 2009
Posts: 77
Thanks: 10
Thanked 25 Times in 14 Posts
 
Default

Sry, but i can't edit my old post:

--------COPY of the post before and update-----

Hello again,

problems: first sort (i fixed that local)

List of all listpages and status (i go form page to page / every site get the limit option / sometimes local state)

RED = Broken like in tab in zones or non existing column(s)
Purple = Works but mostly one or more columns uses IDs and not the join OR no Filter = no sort
Green = all orders should work and limit function

Italic -> fixed / solved / changed situation

admin
- cpusers
-- edit user -> username works / missing in database ??? forename,name,city
- system
-- server services
--
server config
-- server ip -> client_id,server_id sort -> join again
- firewall -> server_id sort -> join again

-Apps & addons
-- repo
--
Apps & Addon packages -> No Filter = no URL, no sort
--
Software updates -> No Filter = no URL, no sort
- Language Editor
-- Languages -> No Filter = no URL, no sort
- Remote Users
-- edit users -> username -> join again -> fixed

client
- clients
-- Edit Client
-- Client-Templates ADDED template_id
- reseller
-- Edit Reseller

dns
- dns wizard
-- templates
- dns
-- zones -> server_id -> join
- - - Records
- Secondary Zone
-- Secondary Zones -> server_id -> join

domain
- domains
-- domains -> -> sys_groupid missing user_txt missing

help
- Support
-- View Messages -> no idear, always empty, never used i cant see my send messanges.. but if i switch user, it works
- FAQ
-- Manage Section -> No Filter = no sort -> strange order of columns
--
Manage Section -> No Filter = no sort -> strange order of columns

email
- email accounts
-- domain -> server_id, client_id-> join
-- domain alias
-- email mailbox
- - - Email Box Rules missing -> forgot it... -> Change tab was missing -> Added
-- email alias
-- email forward
-- email catchall
-- email routing -> server_id
- Mailing List
-- Mailing List
- Spam filter
-- Whitelist -> server_id,rid -> join
--
Blacklist -> server_id,rid -> join
--
User / Domain -> server_id,policy -> join

-- policy
- fetchmail
-- fetchmail -> server_id -> join
-Statisitics
-- Mailbox Quota -> SQL Error like other stats -> dropped sorting for traffic and quota -> info in monitor_data as array serialized or something like that
-- Mailbox traffic -> SQL Error like other stats
- Global Filters
-- postfix whitelist -> server_id -> join (recipient_txt output)
--
postfix blacklist -> server_id -> join
--
Content filter -> server_id -> join

-- fetchmail -> server_id -> join

monitor
- system state (overview was green, but some updates available and under updates are blue...)
- show System-Log -> server_id -> join
-
show Jobqueue -> server_id -> join

sites
- websites
-- website -> sys_groupid,server_id -> join again !!! Test normal user also, different list
- - -Existing backups no Filter
-- Subdomain -> server_id, parent_domain_id -> join
- ftp
-- ftp-user -> server_id, parent_domain_id -> join
- shell
-- shell-user -> server_id, parent_domain_id -> join
- database
-- database -> server_id, parent_domain_id -> join
- web-dav
-- web-dav -> server_id, parent_domain_id -> join
- folder protection
-- folder -> server_id, parent_domain_id -> join
-- folder user -> web_folder_id -> join
- Cron
-- Cron jobs -> server_id, parent_domain_id -> join
- Statistic
-- Web Traffic -> SQL error by month and year -> dropped sorting for traffic and quota -> info in monitor_data as array serialized or something like that
-- Website quota -> i wrote already about this problem

vserver
- OpenVZ
-- Virtual Servers -> ostemplate_id,template_id -> join
-- OS Templates -> server_id -> join
-- VM Templates
--
IP Addresses -> server_id -> join (+ title of vm_id is missing)


-> DONT FORGET PATCH IS ONLY default_combobox TEMPLATE

I wrote a "hack" for server_id and client_id as join in query for sort. It is working.

File update:
sorting_patch_03032012_0004.txt - Support DNS Zone Records sort

sorting_patch_04032012_0235.txt - Join Support for right Order alhpa numeric and don't only ids - fixed GENERAL bug in mailrules filter - dropped sort support for quota and traffic (quota not possible in a join..) - admin -> users -> 3 columns don't exist

sorting_patch_04032012_0245.txt - added join to help (should be last one)

REMOVED FILES - Commited in trunk
-> commit #2984 + fixes in 2985
I tested SVN version, tried every table.

regards
xaver

Last edited by xaver; 4th March 2012 at 04:31.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
ISPconfig 3 - Postfix spammer killer bl4ckb1rd Tips/Tricks/Mods 15 10th February 2011 19:43


All times are GMT +2. The time now is 01:57.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.