summaryrefslogtreecommitdiffstats
path: root/extensions/ProductDashboard/template/en/default/pages/productdashboard/recents.html.tmpl
blob: 66320e174fbc5a53e0199d56c39342fcb37c94d7 (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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
[%# This Source Code Form is subject to the terms of the Mozilla Public
  # License, v. 2.0. If a copy of the MPL was not distributed with this
  # file, You can obtain one at http://mozilla.org/MPL/2.0/.
  #
  # This Source Code Form is "Incompatible With Secondary Licenses", as
  # defined by the Mozilla Public License, v. 2.0.
  #%]

<script type="text/javascript">
  PD.recents = {};
  
  // Recently opened
  PD.recents.opened = [
    [% FOREACH bug = recently_opened %]
      {
        id: '[% bug.id FILTER js %]',
        status: '[% bug.status FILTER js %]',
        version: '[% bug.version FILTER js %]',
        component: '[% bug.component FILTER js %]',
        severity: '[% bug.severity FILTER js %]',
        summary: '[% bug.summary FILTER js %]'
      },
    [% END %]
  ];

  // Recently closed 
  PD.recents.closed = [
    [% FOREACH bug = recently_closed %]
      {
        id: '[% bug.id FILTER js %]',
        status: '[% bug.status FILTER js %]',
        version: '[% bug.version FILTER js %]',
        component: '[% bug.component FILTER js %]',
        severity: '[% bug.severity FILTER js %]',
        summary: '[% bug.summary FILTER js %]'
      },
    [% END %]
  ];
</script>

<h3>Most recently opened and closed [% terms.bugs %]</h3>

<p>
  Activity within the last <input type="text" size="4" name="recent_days" 
                                  value="[% recent_days FILTER html %]">
  days (between 1 and 100) or from 
  <input name="date_from" size="10" id="date_from"
         value="[% date_from FILTER html %]"
         onchange="updateCalendarFromField(this)">
  <button type="button" class="calendar_button"
          id="button_calendar_date_from"
          onclick="showCalendar('date_from')">
  <span>Calendar</span>
  </button>
  <span id="con_calendar_date_from"></span>
  to 
  <input name="date_to" size="10" id="date_to"
         value="[% date_to FILTER html %]"
         onchange="updateCalendarFromField(this)">
  <button type="button" class="calendar_button"
          id="button_calendar_date_to"
          onclick="showCalendar('date_to')">
  <span>Calendar</span>
  </button>
  <span id="con_calendar_date_to"></span>
  <script type="text/javascript">
    createCalendar('date_from')
    createCalendar('date_to')
  </script>
  <input type="submit" name="change" value="Change">
</p>
<p>
  <a href="#recently_opened">Recently Opened</a>
  <span class="separator"> | </span>
  <a href="#recently_closed">Recently Closed</a>
</p>
  
<div class="yui-skin-sam">
  <a name="recently_opened"></a>
  <b>[% recently_opened.size FILTER html %] Recently Opened [% terms.Bugs %]</b>
  <div id="recently_opened"></div>
  <br>
  <a name="recently_closed"></a>
  <b>[% recently_closed.size FILTER html %] Recently Closed [% terms.Bugs %]</b>
  (<a href="#top">back to top</a>)
  <div id="recently_closed"></div>
</div>