added ordering by ID to tiix
This commit is contained in:
@@ -94,6 +94,7 @@ set tiix_post_repto ""
|
||||
set tiix_filter_num 0
|
||||
set tiix_filter_regex ""
|
||||
set tiix_filter_rev 0
|
||||
set tiix_order_byid 0
|
||||
set tiix_status Ready
|
||||
set tiix_entry 0
|
||||
|
||||
@@ -128,7 +129,7 @@ proc linkinsert {textw uri is_orig} {
|
||||
|
||||
proc tiix_viewecho {} {
|
||||
global localdb linkcount tiix_echoname
|
||||
global tiix_filter_num tiix_filter_regex tiix_filter_rev
|
||||
global tiix_filter_num tiix_filter_regex tiix_filter_rev tiix_order_byid
|
||||
if {$tiix_echoname eq ""} {
|
||||
errmsg "Please select an echo conference to read!"
|
||||
return
|
||||
@@ -139,7 +140,11 @@ proc tiix_viewecho {} {
|
||||
if {$tiix_filter_regex ne {}} {
|
||||
append query { AND (`body` LIKE $tiix_filter_regex OR `subj` LIKE $tiix_filter_regex) }
|
||||
}
|
||||
append query { ORDER BY `timestamp` }
|
||||
if {$tiix_order_byid eq 1} {
|
||||
append query { ORDER BY `is` }
|
||||
} else {
|
||||
append query { ORDER BY `timestamp` }
|
||||
}
|
||||
if {$tiix_filter_rev eq 1} {append query DESC} else {append query ASC}
|
||||
if {$tiix_filter_num > 0} {append query { LIMIT $tiix_filter_num}}
|
||||
append query ";"
|
||||
@@ -234,9 +239,11 @@ ttk::combobox .tabbar.r.addrframe.f.echo -width 25 -textvariable tiix_echoname -
|
||||
ttk::label .tabbar.r.addrframe.c.aml -text "# Messages:"
|
||||
ttk::entry .tabbar.r.addrframe.c.amt -textvariable tiix_filter_num -width 8
|
||||
ttk::checkbutton .tabbar.r.addrframe.c.rev -variable tiix_filter_rev -offvalue 0 -onvalue 1 -text "Reverse"
|
||||
ttk::checkbutton .tabbar.r.addrframe.c.byid -variable tiix_order_byid -offvalue 0 -onvalue 1 -text "By ID"
|
||||
grid .tabbar.r.addrframe.c.aml -row 0 -column 0 -sticky nse
|
||||
grid .tabbar.r.addrframe.c.amt -row 0 -column 1 -sticky w -padx 5
|
||||
grid .tabbar.r.addrframe.c.rev -row 1 -column 0 -sticky nswe
|
||||
grid .tabbar.r.addrframe.c.byid -row 1 -column 1 -sticky nswe
|
||||
grid rowconfigure .tabbar.r.addrframe.c 0 -weight 1
|
||||
grid rowconfigure .tabbar.r.addrframe.c 1 -weight 1
|
||||
ttk::label .tabbar.r.addrframe.f.rg -text "Search filter"
|
||||
|
||||
Reference in New Issue
Block a user