diff options
Diffstat (limited to 'templates/web/default/front')
-rw-r--r-- | templates/web/default/front/news.html | 11 | ||||
-rw-r--r-- | templates/web/default/front/stats.html | 46 |
2 files changed, 57 insertions, 0 deletions
diff --git a/templates/web/default/front/news.html b/templates/web/default/front/news.html new file mode 100644 index 000000000..080034a28 --- /dev/null +++ b/templates/web/default/front/news.html @@ -0,0 +1,11 @@ +[%# + news = [ + { date = '2008-12-11', text = '<a href="' _ c.config.IPHONE_URL _ '">' _ loc('Get FixMyStreet on your iPhone') _ '</a>' }, + ] +%] +[% FOREACH item IN news %] + <p align="center" style="margin-bottom:0"> + <img width="23" height="12" alt="[% loc('New!') %]" src="/i/new.png" border="0">[% item.date %] [% item.text %]</p> + </p> +[% END %] + diff --git a/templates/web/default/front/stats.html b/templates/web/default/front/stats.html new file mode 100644 index 000000000..4b98ef31e --- /dev/null +++ b/templates/web/default/front/stats.html @@ -0,0 +1,46 @@ +[% + USE Comma; + # Note - if we want to i18n the commas we should try + # 'Template::Plugin::Number::Format' +%] + +<h2>[% loc('FixMyStreet updates') %]</h2> + +[% + stats = c.cobrand.front_stats_data(); + + new_text = + stats.recency == '1 week' + ? nget( + "<big>%s</big> report in past week", + "<big>%s</big> reports in past week", + stats.new + ) + : nget( + "<big>%s</big> report recently", + "<big>%s</big> reports recently", + stats.new + ); + + fixed_text = nget( + "<big>%s</big> fixed in past month", + "<big>%s</big> fixed in past month", + stats.fixed + ); + + updates_text = nget( + "<big>%s</big> update on reports", + "<big>%s</big> updates on reports", + stats.updates + ); + +%] + +<div id="front_stats"> + <div>[% tprintf( new_text, stats.new ) | comma %]</div> + [% IF c.cobrand.moniker != 'emptyhomes' %] + <div>[% tprintf( fixed_text, stats.fixed ) | comma %]</div> + [% END %] + <div>[% tprintf( updates_text, stats.updates ) | comma %]</div> +</div> + |