changed: in 'showtickets' winix function
now tickets are sorted by the sort_index and then by date changed: html in 'sort' winix function (added items' subjects to the item lists) git-svn-id: svn://ttmath.org/publicrep/winix/trunk@931 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
parent
26715bdd4c
commit
b7f3f84080
|
@ -36,7 +36,7 @@
|
||||||
[# is it correct? may give this 'if' only to /-/thumb param? ]
|
[# is it correct? may give this 'if' only to /-/thumb param? ]
|
||||||
[if item_tab_has_thumb]<img src="[item_tab_link]/-/thumb" alt="[item_tab_subject]">[end]
|
[if item_tab_has_thumb]<img src="[item_tab_link]/-/thumb" alt="[item_tab_subject]">[end]
|
||||||
|
|
||||||
[item_tab_url]
|
[item_tab_url] [is-no item_tab_subject str ""]<span class="winix_sort_item_title">({sort_item_subject}: [item_tab_subject])</span>[end]
|
||||||
</li>
|
</li>
|
||||||
[end]
|
[end]
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
@ -427,7 +427,7 @@ slog_turn_over = Session's log turned over due to size greater than
|
||||||
sort_header = Sort
|
sort_header = Sort
|
||||||
sort_current_sortindex = Current sort index
|
sort_current_sortindex = Current sort index
|
||||||
sort_info_multi = Set an order of items by using the mouse.
|
sort_info_multi = Set an order of items by using the mouse.
|
||||||
|
sort_item_subject = Subject:
|
||||||
|
|
||||||
stat_header = Stat
|
stat_header = Stat
|
||||||
stat_item_type = type
|
stat_item_type = type
|
||||||
|
|
|
@ -448,6 +448,7 @@ slog_turn_over = Log sesji wyczyszczony w związku z przekroczeniem wielkości
|
||||||
sort_header = Sortuj
|
sort_header = Sortuj
|
||||||
sort_current_sortindex = Bieżący indeks sortowania
|
sort_current_sortindex = Bieżący indeks sortowania
|
||||||
sort_info_multi = Ustaw kolejność elementów przeciągając je przy pomocy myszki.
|
sort_info_multi = Ustaw kolejność elementów przeciągając je przy pomocy myszki.
|
||||||
|
sort_item_subject = Tytuł:
|
||||||
|
|
||||||
stat_header = Stat
|
stat_header = Stat
|
||||||
stat_item_type = typ
|
stat_item_type = typ
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* This file is a part of Winix
|
* This file is a part of Winix
|
||||||
* and is not publicly distributed
|
* and is not publicly distributed
|
||||||
*
|
*
|
||||||
* Copyright (c) 2010-2012, Tomasz Sowa
|
* Copyright (c) 2010-2013, Tomasz Sowa
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
@ -55,7 +55,11 @@ bool ShowTickets::Sort::operator()(const Item * item1, const Item * item2)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// sorting by date
|
// sorting by sort_index and if equal then by date
|
||||||
|
|
||||||
|
if( item1->sort_index != item2->sort_index )
|
||||||
|
return item1->sort_index < item2->sort_index;
|
||||||
|
|
||||||
return item1->date_creation > item2->date_creation;
|
return item1->date_creation > item2->date_creation;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -77,6 +81,7 @@ void ShowTickets::ReadFiles(long dir_id)
|
||||||
iq.sel_privileges = true;
|
iq.sel_privileges = true;
|
||||||
iq.sel_date = true;
|
iq.sel_date = true;
|
||||||
iq.sel_meta = true;
|
iq.sel_meta = true;
|
||||||
|
iq.sel_sort_index = true;
|
||||||
iq.WhereParentId(dir_id);
|
iq.WhereParentId(dir_id);
|
||||||
iq.WhereType(Item::file);
|
iq.WhereType(Item::file);
|
||||||
iq.WhereFileType(WINIX_ITEM_FILETYPE_NONE);
|
iq.WhereFileType(WINIX_ITEM_FILETYPE_NONE);
|
||||||
|
|
Loading…
Reference in New Issue