Fossil SCM

The table in the new /whistory page is not sortable.

drh 2018-12-12 20:03 trunk
Commit 869841cb04a207d98906b60ef81a189b0287c60ae09c7bd233f32e2abf81635f
1 file changed +5 -4
+5 -4
--- src/wiki.c
+++ src/wiki.c
@@ -888,11 +888,11 @@
888888
" ORDER BY event.mtime DESC",
889889
zPageName
890890
);
891891
@ <h2>History of <a href="%R/wiki?name=%T(zPageName)">%h(zPageName)</a></h2>
892892
@ <div class="brlist">
893
- @ <table class='xsortable' data-column-types='Kttn' data-init-sort='1'>
893
+ @ <table>
894894
@ <thead><tr>
895895
@ <th>Age</th>
896896
@ <th>Hash</th>
897897
@ <th>User</th>
898898
if( showRid ){
@@ -904,14 +904,15 @@
904904
while( db_step(&q)==SQLITE_ROW ){
905905
double rMtime = db_column_double(&q, 0);
906906
const char *zUuid = db_column_text(&q, 1);
907907
const char *zUser = db_column_text(&q, 2);
908908
int wrid = db_column_int(&q, 3);
909
- sqlite3_int64 iMtime = (sqlite3_int64)(rMtime*86400.0);
909
+ /* sqlite3_int64 iMtime = (sqlite3_int64)(rMtime*86400.0); */
910910
char *zAge = human_readable_age(rNow - rMtime);
911911
@ <tr>
912
- @ <td data-sortkey="%016llx(iMtime)">%s(zAge)</td>
912
+ /* @ <td data-sortkey="%016llx(iMtime)">%s(zAge)</td> */
913
+ @ <td>%s(zAge)</td>
913914
fossil_free(zAge);
914915
@ <td>%z(href("%R/info/%s",zUuid))%S(zUuid)</a></td>
915916
@ <td>%h(zUser)</td>
916917
if( showRid ){
917918
@ <td>%z(href("%R/artifact/%S",zUuid))%d(wrid)</a></td>
@@ -919,11 +920,11 @@
919920
@ <td>%z(href("%R/wdiff?id=%S",zUuid))diff</a></td>
920921
@ </tr>
921922
}
922923
@ </tbody></table></div>
923924
db_finalize(&q);
924
- style_table_sorter();
925
+ /* style_table_sorter(); */
925926
style_footer();
926927
}
927928
928929
/*
929930
** WEBPAGE: wdiff
930931
--- src/wiki.c
+++ src/wiki.c
@@ -888,11 +888,11 @@
888 " ORDER BY event.mtime DESC",
889 zPageName
890 );
891 @ <h2>History of <a href="%R/wiki?name=%T(zPageName)">%h(zPageName)</a></h2>
892 @ <div class="brlist">
893 @ <table class='xsortable' data-column-types='Kttn' data-init-sort='1'>
894 @ <thead><tr>
895 @ <th>Age</th>
896 @ <th>Hash</th>
897 @ <th>User</th>
898 if( showRid ){
@@ -904,14 +904,15 @@
904 while( db_step(&q)==SQLITE_ROW ){
905 double rMtime = db_column_double(&q, 0);
906 const char *zUuid = db_column_text(&q, 1);
907 const char *zUser = db_column_text(&q, 2);
908 int wrid = db_column_int(&q, 3);
909 sqlite3_int64 iMtime = (sqlite3_int64)(rMtime*86400.0);
910 char *zAge = human_readable_age(rNow - rMtime);
911 @ <tr>
912 @ <td data-sortkey="%016llx(iMtime)">%s(zAge)</td>
 
913 fossil_free(zAge);
914 @ <td>%z(href("%R/info/%s",zUuid))%S(zUuid)</a></td>
915 @ <td>%h(zUser)</td>
916 if( showRid ){
917 @ <td>%z(href("%R/artifact/%S",zUuid))%d(wrid)</a></td>
@@ -919,11 +920,11 @@
919 @ <td>%z(href("%R/wdiff?id=%S",zUuid))diff</a></td>
920 @ </tr>
921 }
922 @ </tbody></table></div>
923 db_finalize(&q);
924 style_table_sorter();
925 style_footer();
926 }
927
928 /*
929 ** WEBPAGE: wdiff
930
--- src/wiki.c
+++ src/wiki.c
@@ -888,11 +888,11 @@
888 " ORDER BY event.mtime DESC",
889 zPageName
890 );
891 @ <h2>History of <a href="%R/wiki?name=%T(zPageName)">%h(zPageName)</a></h2>
892 @ <div class="brlist">
893 @ <table>
894 @ <thead><tr>
895 @ <th>Age</th>
896 @ <th>Hash</th>
897 @ <th>User</th>
898 if( showRid ){
@@ -904,14 +904,15 @@
904 while( db_step(&q)==SQLITE_ROW ){
905 double rMtime = db_column_double(&q, 0);
906 const char *zUuid = db_column_text(&q, 1);
907 const char *zUser = db_column_text(&q, 2);
908 int wrid = db_column_int(&q, 3);
909 /* sqlite3_int64 iMtime = (sqlite3_int64)(rMtime*86400.0); */
910 char *zAge = human_readable_age(rNow - rMtime);
911 @ <tr>
912 /* @ <td data-sortkey="%016llx(iMtime)">%s(zAge)</td> */
913 @ <td>%s(zAge)</td>
914 fossil_free(zAge);
915 @ <td>%z(href("%R/info/%s",zUuid))%S(zUuid)</a></td>
916 @ <td>%h(zUser)</td>
917 if( showRid ){
918 @ <td>%z(href("%R/artifact/%S",zUuid))%d(wrid)</a></td>
@@ -919,11 +920,11 @@
920 @ <td>%z(href("%R/wdiff?id=%S",zUuid))diff</a></td>
921 @ </tr>
922 }
923 @ </tbody></table></div>
924 db_finalize(&q);
925 /* style_table_sorter(); */
926 style_footer();
927 }
928
929 /*
930 ** WEBPAGE: wdiff
931

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button