Fossil SCM
Add the oldestfirst boolean query parameter to the /timeline page.
Commit
ee8d34f5aa9d948d1ac74113e8ceffc16e0d02908b862b9322b0bee57d3140bd
Parent
2925484c9550b72…
1 file changed
+6
-1
+6
-1
| --- src/timeline.c | ||
| +++ src/timeline.c | ||
| @@ -1619,10 +1619,11 @@ | ||
| 1619 | 1619 | ** to see all changes for the current year. |
| 1620 | 1620 | ** days=N Show events over the previous N days |
| 1621 | 1621 | ** datefmt=N Override the date format: 0=HH:MM, 1=HH:MM:SS, |
| 1622 | 1622 | ** 2=YYYY-MM-DD HH:MM:SS, 3=YYMMDD HH:MM, and 4 means "off". |
| 1623 | 1623 | ** bisect Show the check-ins that are in the current bisect |
| 1624 | +** oldestfirst Show events oldest first. | |
| 1624 | 1625 | ** showid Show RIDs |
| 1625 | 1626 | ** showsql Show the SQL text |
| 1626 | 1627 | ** |
| 1627 | 1628 | ** p= and d= can appear individually or together. If either p= or d= |
| 1628 | 1629 | ** appear, then u=, y=, a=, and b= are ignored. |
| @@ -2766,11 +2767,15 @@ | ||
| 2766 | 2767 | if( useDividers && zMark && zMark[0] ){ |
| 2767 | 2768 | double r = symbolic_name_to_mtime(zMark, 0); |
| 2768 | 2769 | if( r>0.0 && !selectedRid ) selectedRid = timeline_add_divider(r); |
| 2769 | 2770 | } |
| 2770 | 2771 | blob_zero(&sql); |
| 2771 | - db_prepare(&q, "SELECT * FROM timeline ORDER BY sortby DESC /*scan*/"); | |
| 2772 | + if( PB("oldestfirst") ){ | |
| 2773 | + db_prepare(&q, "SELECT * FROM timeline ORDER BY sortby ASC /*scan*/"); | |
| 2774 | + }else{ | |
| 2775 | + db_prepare(&q, "SELECT * FROM timeline ORDER BY sortby DESC /*scan*/"); | |
| 2776 | + } | |
| 2772 | 2777 | if( fossil_islower(desc.aData[0]) ){ |
| 2773 | 2778 | desc.aData[0] = fossil_toupper(desc.aData[0]); |
| 2774 | 2779 | } |
| 2775 | 2780 | if( zBrName ){ |
| 2776 | 2781 | if( !PB("nowiki") |
| 2777 | 2782 |
| --- src/timeline.c | |
| +++ src/timeline.c | |
| @@ -1619,10 +1619,11 @@ | |
| 1619 | ** to see all changes for the current year. |
| 1620 | ** days=N Show events over the previous N days |
| 1621 | ** datefmt=N Override the date format: 0=HH:MM, 1=HH:MM:SS, |
| 1622 | ** 2=YYYY-MM-DD HH:MM:SS, 3=YYMMDD HH:MM, and 4 means "off". |
| 1623 | ** bisect Show the check-ins that are in the current bisect |
| 1624 | ** showid Show RIDs |
| 1625 | ** showsql Show the SQL text |
| 1626 | ** |
| 1627 | ** p= and d= can appear individually or together. If either p= or d= |
| 1628 | ** appear, then u=, y=, a=, and b= are ignored. |
| @@ -2766,11 +2767,15 @@ | |
| 2766 | if( useDividers && zMark && zMark[0] ){ |
| 2767 | double r = symbolic_name_to_mtime(zMark, 0); |
| 2768 | if( r>0.0 && !selectedRid ) selectedRid = timeline_add_divider(r); |
| 2769 | } |
| 2770 | blob_zero(&sql); |
| 2771 | db_prepare(&q, "SELECT * FROM timeline ORDER BY sortby DESC /*scan*/"); |
| 2772 | if( fossil_islower(desc.aData[0]) ){ |
| 2773 | desc.aData[0] = fossil_toupper(desc.aData[0]); |
| 2774 | } |
| 2775 | if( zBrName ){ |
| 2776 | if( !PB("nowiki") |
| 2777 |
| --- src/timeline.c | |
| +++ src/timeline.c | |
| @@ -1619,10 +1619,11 @@ | |
| 1619 | ** to see all changes for the current year. |
| 1620 | ** days=N Show events over the previous N days |
| 1621 | ** datefmt=N Override the date format: 0=HH:MM, 1=HH:MM:SS, |
| 1622 | ** 2=YYYY-MM-DD HH:MM:SS, 3=YYMMDD HH:MM, and 4 means "off". |
| 1623 | ** bisect Show the check-ins that are in the current bisect |
| 1624 | ** oldestfirst Show events oldest first. |
| 1625 | ** showid Show RIDs |
| 1626 | ** showsql Show the SQL text |
| 1627 | ** |
| 1628 | ** p= and d= can appear individually or together. If either p= or d= |
| 1629 | ** appear, then u=, y=, a=, and b= are ignored. |
| @@ -2766,11 +2767,15 @@ | |
| 2767 | if( useDividers && zMark && zMark[0] ){ |
| 2768 | double r = symbolic_name_to_mtime(zMark, 0); |
| 2769 | if( r>0.0 && !selectedRid ) selectedRid = timeline_add_divider(r); |
| 2770 | } |
| 2771 | blob_zero(&sql); |
| 2772 | if( PB("oldestfirst") ){ |
| 2773 | db_prepare(&q, "SELECT * FROM timeline ORDER BY sortby ASC /*scan*/"); |
| 2774 | }else{ |
| 2775 | db_prepare(&q, "SELECT * FROM timeline ORDER BY sortby DESC /*scan*/"); |
| 2776 | } |
| 2777 | if( fossil_islower(desc.aData[0]) ){ |
| 2778 | desc.aData[0] = fossil_toupper(desc.aData[0]); |
| 2779 | } |
| 2780 | if( zBrName ){ |
| 2781 | if( !PB("nowiki") |
| 2782 |