Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | Add a link to the /uvlist screen from the /setup menu. Add the byage=1 query parameter to /uvlist. |
|---|---|
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA1: |
ab4c1e2961a69e5104be3734ffcee7f0 |
| User & Date: | drh 2016-08-23 11:58:41.689 |
Context
|
2016-08-23
| ||
| 12:13 | eliminate some end-of-line spaces check-in: d32155d064 user: jan.nijtmans tags: trunk | |
| 11:58 | Add a link to the /uvlist screen from the /setup menu. Add the byage=1 query parameter to /uvlist. check-in: ab4c1e2961 user: drh tags: trunk | |
| 10:13 | Fix a harmless but redundant space in the admin_log schema definition. check-in: 1852455158 user: drh tags: trunk | |
Changes
Changes to src/setup.c.
| ︙ | ︙ | |||
125 126 127 128 129 130 131 132 133 134 135 136 137 138 |
"Show artifacts that are shunned by this repository");
setup_menu_entry("Artifact Receipts Log", "rcvfromlist",
"A record of received artifacts and their sources");
setup_menu_entry("User Log", "access_log",
"A record of login attempts");
setup_menu_entry("Administrative Log", "admin_log",
"View the admin_log entries");
setup_menu_entry("Stats", "stat",
"Repository Status Reports");
setup_menu_entry("Sitemap", "sitemap",
"Links to miscellaneous pages");
setup_menu_entry("SQL", "admin_sql",
"Enter raw SQL commands");
setup_menu_entry("TH1", "admin_th1",
| > > | 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 |
"Show artifacts that are shunned by this repository");
setup_menu_entry("Artifact Receipts Log", "rcvfromlist",
"A record of received artifacts and their sources");
setup_menu_entry("User Log", "access_log",
"A record of login attempts");
setup_menu_entry("Administrative Log", "admin_log",
"View the admin_log entries");
setup_menu_entry("Unversioned Files", "uvlist?byage=1",
"Show all unversioned files held");
setup_menu_entry("Stats", "stat",
"Repository Status Reports");
setup_menu_entry("Sitemap", "sitemap",
"Links to miscellaneous pages");
setup_menu_entry("SQL", "admin_sql",
"Enter raw SQL commands");
setup_menu_entry("TH1", "admin_th1",
|
| ︙ | ︙ |
Changes to src/unversioned.c.
| ︙ | ︙ | |||
350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 |
}
}
/*
** WEBPAGE: uvlist
**
** Display a list of all unversioned files in the repository.
*/
void uvstat_page(void){
Stmt q;
sqlite3_int64 iNow;
sqlite3_int64 iTotalSz = 0;
int cnt = 0;
int n = 0;
char zSzName[100];
login_check_credentials();
if( !g.perm.Read ){ login_needed(g.anon.Read); return; }
style_header("Unversioned Files");
if( !db_table_exists("repository","unversioned") ){
@ No unversioned files on this server
style_footer();
return;
}
db_prepare(&q,
"SELECT"
" name,"
" mtime,"
" hash,"
" sz,"
" (SELECT login FROM rcvfrom, user"
" WHERE user.uid=rcvfrom.uid AND rcvfrom.rcvid=unversioned.rcvid),"
" rcvid"
| > > > > > | > | 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 |
}
}
/*
** WEBPAGE: uvlist
**
** Display a list of all unversioned files in the repository.
** Query parameters:
**
** byage=1 Order the initial display be decreasing age
*/
void uvstat_page(void){
Stmt q;
sqlite3_int64 iNow;
sqlite3_int64 iTotalSz = 0;
int cnt = 0;
int n = 0;
const char *zOrderBy = "name";
char zSzName[100];
login_check_credentials();
if( !g.perm.Read ){ login_needed(g.anon.Read); return; }
style_header("Unversioned Files");
if( !db_table_exists("repository","unversioned") ){
@ No unversioned files on this server
style_footer();
return;
}
if( PB("byage") ) zOrderBy = "mtime DESC";
db_prepare(&q,
"SELECT"
" name,"
" mtime,"
" hash,"
" sz,"
" (SELECT login FROM rcvfrom, user"
" WHERE user.uid=rcvfrom.uid AND rcvfrom.rcvid=unversioned.rcvid),"
" rcvid"
" FROM unversioned ORDER BY %s",
zOrderBy/*safe-for-%s*/
);
iNow = db_int64(0, "SELECT strftime('%%s','now');");
while( db_step(&q)==SQLITE_ROW ){
const char *zName = db_column_text(&q, 0);
sqlite3_int64 mtime = db_column_int(&q, 1);
const char *zHash = db_column_text(&q, 2);
int isDeleted = zHash==0;
|
| ︙ | ︙ |