aboutsummaryrefslogtreecommitdiffstats
path: root/templates/web/fixmystreet.com/report/banner.html
blob: 35d7be1790677e5e99974849830c17f1c7bf1fe8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
[% USE date %]

[% BLOCK banner %]
    <div class="banner">
        <p id="[% id %]">[% text %]</p>
    </div>
[% END %]

[% IF problem.is_fixed %]
    [% INCLUDE banner, id = 'fixed', text = loc('Fixed') %]
[% END %]

[% IF problem.is_closed %]
    [% INCLUDE banner, id = 'closed', text = loc('Closed') %]
[% END %]

[% IF NOT problem.bodies_str == '2482' %]

    [% IF problem.is_open AND date.now - problem.lastupdate.epoch > 8 * 7 * 24 * 60 * 60 %]
        [% INCLUDE banner, id = 'unknown', text = loc('Unknown') %]
    [% END %]

    [% states = [ 'investigating', 'in progress', 'planned', 'action scheduled' ];
       IF states.grep(problem.state).size %]
        [% INCLUDE banner, id = 'progress', text = loc('In progress') %]
    [% END %]

[% END %]