diff options
author | plegall <plg@piwigo.org> | 2007-01-16 23:39:39 +0000 |
---|---|---|
committer | plegall <plg@piwigo.org> | 2007-01-16 23:39:39 +0000 |
commit | 5d9a865fe1931869d3d9edb19f64d66783a0f4f4 (patch) | |
tree | 35805541591d81cbb9a7758ddb3e2da538a2237d /template | |
parent | 62149d74a9724bba01c5ae5b8b99fa00e0a60fe7 (diff) |
Modification: new data model for history, more compact, more efficient. A
summary table is used as cache for history stats display.
New: a Perl script fill_history.pl was added to simulate a high load on
history table (making the efficiency of the new data model obvious).
Modification: function prepend_append_array_items moved from
include/functions_search.inc.php to include/functions_search.inc.php since
this function is used in new file admin/history.php
Modification: admin/images/*_stats.img.php replaced by a simpler and more
generic admin/images/stats.img.php unique file.
New: a history detail search page was added. Currently, only start and end
dates can be modified, it's just a beginning.
git-svn-id: http://piwigo.org/svn/trunk@1727 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'template')
-rw-r--r-- | template/yoga/admin.tpl | 10 | ||||
-rw-r--r-- | template/yoga/admin/element_set_global.tpl | 2 | ||||
-rw-r--r-- | template/yoga/admin/history.tpl | 93 | ||||
-rw-r--r-- | template/yoga/admin/stats.tpl | 40 |
4 files changed, 108 insertions, 37 deletions
diff --git a/template/yoga/admin.tpl b/template/yoga/admin.tpl index bfff0af32..b108ab493 100644 --- a/template/yoga/admin.tpl +++ b/template/yoga/admin.tpl @@ -15,7 +15,15 @@ <ul> <li><a href="{U_FAQ}">{lang:instructions}</a></li> <li><a href="{U_SITE_MANAGER}">{lang:Site manager}</a></li> - <li><a href="{U_HISTORY}">{lang:history}</a></li> + + <li> + {lang:history} + <ul> + <li><a href="{U_HISTORY_STAT}">{lang:Statistics}</a></li> + <li><a href="{U_HISTORY_SEARCH}">{lang:Search}</a></li> + </ul> + </li> + <li><a href="{U_CAT_UPDATE}">{lang:update}</a></li> </ul> </dd> diff --git a/template/yoga/admin/element_set_global.tpl b/template/yoga/admin/element_set_global.tpl index 88acd3a50..6b1bab8ca 100644 --- a/template/yoga/admin/element_set_global.tpl +++ b/template/yoga/admin/element_set_global.tpl @@ -159,6 +159,8 @@ <!-- BEGIN not_in_caddie --> <li><label><input type="radio" name="caddie_action" value="add_selected" /> {lang:Add selected elements to caddie}</label></li> <!-- END not_in_caddie --> + + <li><label><input type="radio" name="caddie_action" value="export" /> {lang:Export data}</label></li> </ul> diff --git a/template/yoga/admin/history.tpl b/template/yoga/admin/history.tpl new file mode 100644 index 000000000..91f5fb4c6 --- /dev/null +++ b/template/yoga/admin/history.tpl @@ -0,0 +1,93 @@ +<div class="titrePage"> + <ul class="categoryActions"> + <li> + <a + href="{U_HELP}" + onclick="popuphelp(this.href); return false;" + title="{lang:Help}" + > + <img src="{themeconf:icon_dir}/help.png" class="button" alt="(?)"> + </a> + </li> + </ul> + <h2>{lang:History}</h2> +</div> + +<form class="filter" method="post" name="filter" action="{F_ACTION}"> +<fieldset> + <legend>{lang:Filter}</legend> + <ul> + <li><label>{lang:search_date_from}</label></li> + <li> + <select name="start_day"> + <!-- BEGIN start_day --> + <option {start_day.SELECTED} value="{start_day.VALUE}">{start_day.OPTION}</option> + <!-- END start_day --> + </select> + <select name="start_month"> + <!-- BEGIN start_month --> + <option {start_month.SELECTED} value="{start_month.VALUE}">{start_month.OPTION}</option> + <!-- END start_month --> + </select> + <input name="start_year" value="{START_YEAR}" type="text" size="4" maxlength="4" > + </li> + </ul> + <ul> + <li><label>{lang:search_date_to}</label></li> + <li> + <select name="end_day"> + <!-- BEGIN end_day --> + <option {end_day.SELECTED} value="{end_day.VALUE}">{end_day.OPTION}</option> + <!-- END end_day --> + </select> + <select name="end_month"> + <!-- BEGIN end_month --> + <option {end_month.SELECTED} value="{end_month.VALUE}">{end_month.OPTION}</option> + <!-- END end_month --> + </select> + <input name="end_year" value="{END_YEAR}" type="text" size="4" maxlength="4" > + </li> + </ul> + + <input type="submit" name="submit" value="{lang:submit}" {TAG_INPUT_ENABLED}/> +</fieldset> +</form> + +<h3>{L_DATE_TITLE}</h3> + +<!-- BEGIN navigation --> +<div class="admin"> +{navigation.NAVBAR} +</div> +<!-- END navigation --> + +<table class="table2" id="detailedStats"> + <tr class="throw"> + <th>{lang:date}</th> + <th>{lang:time}</th> + <th>{lang:user}</th> + <th>{lang:IP}</th> + <th>{lang:image}</th> + <th>{lang:section}</th> + <th>{lang:category}</th> + <th>{lang:tags}</th> + </tr> +<!-- BEGIN detail --> + <tr class="{detail.T_CLASS}"> + <td class="hour">{detail.DATE}</td> + <td class="hour">{detail.TIME}</td> + <td>{detail.USER}</td> + <td>{detail.IP}</td> + <td>{detail.IMAGE}</td> + <td>{detail.SECTION}</td> + <td>{detail.CATEGORY}</td> + <td>{detail.TAGS}</td> + </tr> +<!-- END detail --> +</table> + +<!-- BEGIN navigation --> +<div class="admin"> +{navigation.NAVBAR} +</div> +<!-- END navigation --> diff --git a/template/yoga/admin/stats.tpl b/template/yoga/admin/stats.tpl index 75de81f79..edf7d9a3c 100644 --- a/template/yoga/admin/stats.tpl +++ b/template/yoga/admin/stats.tpl @@ -2,50 +2,18 @@ <h2>{lang:title_history}</h2> <h3>{L_STAT_TITLE}</h3> -<img class="image" src="{IMG_REPORT}" alt="{L_STAT_MONTHLY_ALT}" /> -<h3>{L_STAT_DETAIL_TITLE}</h3> +<img class="image" src="{SRC_REPORT}" alt="{lang:history chart}" /> + <table class="table2" id="dailyStats"> <tr class="throw"> - <th>{L_VALUE}</th> - <th>{L_PAGES_SEEN}</th> - <th>{L_VISITORS}</th> - <th>{L_PICTURES}</th> + <th>{PERIOD_LABEL}</th> + <th>{lang:Pages seen}</th> </tr> <!-- BEGIN statrow --> <tr class="{statrow.T_CLASS}"> <td>{statrow.VALUE}</td> <td class="number">{statrow.PAGES}</td> - <td class="number">{statrow.VISITORS}</td> - <td class="number">{statrow.IMAGES}</td> </tr> <!-- END statrow --> </table> - -<h3>{L_DATE_TITLE}</h3> -<table class="table2" id="detailedStats"> - <tr class="throw"> - <th>{L_STAT_HOUR}</th> - <th>{L_STAT_LOGIN}</th> - <th>{L_STAT_ADDR}</th> - <th>{L_STAT_CATEGORY}</th> - <th>{L_STAT_FILE}</th> - <th>{L_STAT_PICTURE}</th> - </tr> -<!-- BEGIN detail --> - <tr class="{detail.T_CLASS}"> - <td class="hour">{detail.HOUR}</td> - <td>{detail.LOGIN}</td> - <td>{detail.IP}</td> - <td>{detail.CATEGORY}</td> - <td>{detail.FILE}</td> - <td>{detail.PICTURE}</td> - </tr> -<!-- END detail --> -</table> - -<!-- BEGIN navigation --> -<div class="admin"> -{navigation.NAV_BAR} -</div> -<!-- END navigation --> |