diff options
Diffstat (limited to 'templates')
-rw-r--r-- | templates/web/fixmystreet/my/_problem-list.html | 27 | ||||
-rw-r--r-- | templates/web/fixmystreet/my/my.html | 22 |
2 files changed, 28 insertions, 21 deletions
diff --git a/templates/web/fixmystreet/my/_problem-list.html b/templates/web/fixmystreet/my/_problem-list.html new file mode 100644 index 000000000..1a891de80 --- /dev/null +++ b/templates/web/fixmystreet/my/_problem-list.html @@ -0,0 +1,27 @@ +[% FOREACH p = problems.confirmed %] + [% IF loop.first %]<h2>[% loc('Open reports') %]</h2>[% END %] + [% INCLUDE problem %] +[% END %] + +[% FOREACH p = problems.fixed %] + [% IF loop.first %]<h2>[% loc('Fixed reports') %]</h2>[% END %] + [% INCLUDE problem %] +[% END %] + +[% FOREACH p = problems.closed %] + [% IF loop.first %]<h2>[% loc('Closed reports') %]</h2>[% END %] + [% INCLUDE problem %] +[% END %] + +[%# FOREACH p = problems.unconfirmed; + IF loop.first; + '<h2>' _ loc('Unconfirmed reports') _ '</h2>'; + END; + INCLUDE problem; +END %] + +[% BLOCK problem %] + [% "<ul class='issue-list-a full-width'>" IF loop.first %] + [% INCLUDE 'report/_item.html', problem = p, no_fixed =1 %] + [% "</ul>" IF loop.last %] +[% END %] diff --git a/templates/web/fixmystreet/my/my.html b/templates/web/fixmystreet/my/my.html index eaf521494..9c857aab9 100644 --- a/templates/web/fixmystreet/my/my.html +++ b/templates/web/fixmystreet/my/my.html @@ -34,27 +34,7 @@ param = 'p' %] -[% FOREACH p = problems.confirmed %] - [% IF loop.first %]<h2>[% loc('Open reports') %]</h2>[% END %] - [% INCLUDE problem %] -[% END %] - -[% FOREACH p = problems.fixed %] - [% IF loop.first %]<h2>[% loc('Fixed reports') %]</h2>[% END %] - [% INCLUDE problem %] -[% END %] - -[% FOREACH p = problems.closed %] - [% IF loop.first %]<h2>[% loc('Closed reports') %]</h2>[% END %] - [% INCLUDE problem %] -[% END %] - -[%# FOREACH p = problems.unconfirmed; - IF loop.first; - '<h2>' _ loc('Unconfirmed reports') _ '</h2>'; - END; - INCLUDE problem; -END %] +[% INCLUDE 'my/_problem-list.html' %] [% FOREACH u IN updates %] [% IF loop.first %] |