cosmetic fixes
[myslice.git] / plugins / scheduler2 / templates / scheduler.html
1 <div id="plugin-{{ domid }}-loader" style="text-align:center;">\r
2     <img src="../../static/img/loading-7b6dc55620a355b55b835f6b4c300f9b.gif" alt="loading" style="width:100px;" />\r
3     <h3>Loading Data...</h3>\r
4 </div>\r
5 <div id="plugin-{{ domid }}-empty" style="text-align: center; display: none;">\r
6     <img src="../../static/img/no-data.png" alt="no data found" style="width:100px;" />\r
7     <h3>no data found...</h3>\r
8 </div>\r
9 <div id="plugin-{{ domid }}" class="">\r
10     <div class="row m-b">\r
11         <div class="col-md-4">\r
12                 <div class="row">\r
13                         <div class="col-md-1">\r
14                         <label for="inputEmail3" class="control-label">Date:</label>\r
15                         </div>\r
16                                 <div class="col-md-11">\r
17                                         <input id="DateToRes" type="text" placeholder="Reservation Date">\r
18                                         <span class="glyphicon glyphicon-calendar" style="position:absolute;margin-left:-20px;margin-top:4px;"></span>\r
19                                         <!-- <input id="DateToRes" type="text" class="form-control" placeholder="Reservation Date"> -->\r
20                                 </div>\r
21                         </div>\r
22                 </div>\r
23         <div class="col-md-8">\r
24                 <div class="row">\r
25                         <div class="col-md-2">\r
26                         <label for="inputEmail3" class="control-label">Time of day:</label>\r
27                         </div>\r
28                         <div class="col-md-10">\r
29                                         <div class="sliderContainer">\r
30                                                 <div id="tblSlider"></div>\r
31                                         </div>\r
32                                 </div>\r
33                         </div>\r
34                 </div>\r
35     </div>\r
36     <div id="SchedulerCtrl" ng-controller="SchedulerCtrl" class='query-editor-spacer'>\r
37         <div class="table-responsive">\r
38 \r
39             <table id="scheduler-reservation-table" class="table table-bordered table-condensed">\r
40                 <thead>\r
41                     <tr>\r
42                         <th>Resource name</th>\r
43                         <th ng-repeat="slot in slots | offset: from | limitTo: num_visible_cells ">\r
44                             {[{ slot.time }]}\r
45                         </th>\r
46                     </tr>\r
47                 </thead>\r
48                 <tbody>\r
49                     <tr ng-repeat="resource in resources | filter: filter_visible | offset: (current_page-1) * items_per_page | limitTo: items_per_page" \r
50                                                 ng-class-odd="''" \r
51                                                 ng-class-even="'even'">\r
52                         <th data-resourceid="{[{ resource.urn }]}" \r
53                                                         data-rowindex="{[{ $index }]}" \r
54                                                         data-resourceindex="{[{ resource.index }]}" \r
55                                                         style="word-wrap: break-word; word-break: break-all; ">\r
56                                                         {[{ resource.hostname }]}\r
57                                                 </th>\r
58                         <td ng-repeat="lease in resource.leases | offset: from / (resource.granularity / slot_length)  | limitTo: num_visible_cells / (resource.granularity / slot_length)"\r
59                                                         data-slotid="{[{ lease.id }]}" \r
60                                                         data-groupid="{[{ lease.groupid }]}" \r
61                                                         ng-class="{{ 'lease.status' }}"\r
62                                                         ng-class="{{ 'lease.success' }}"\r
63                                                         colspan="{[{resource.granularity / slot_length}]}"\r
64                                                         ng-click="select(from+$index, lease, $parent.resource)">\r
65                                                 </td>\r
66                     </tr>\r
67                 </tbody>\r
68             </table>\r
69 \r
70             <div class="row">\r
71                 <div class="col-xs-5">\r
72                     <div id="resources-list__table_length" class="dataTables_length">\r
73                         <label>Total pages : {[{page_count()}]}</label>\r
74                     </div>\r
75                 </div>\r
76                 <div class="col-xs-7">\r
77                     <div class="dataTables_paginate paging_bootstrap">\r
78                         <ul class="pagination">\r
79                                                         <li ng-class="prevPageDisabled()">\r
80                                                           <a href ng-click="prevPage()">« Prev</a>\r
81                                                         </li>\r
82                             <li ng-repeat="n in range()" \r
83                                                             ng-class="{active: n==current_page}" \r
84                                                                 ng-click="setPage(n)"><a href="#">{[{n}]}</a></li>\r
85                                                         <li ng-class="nextPageDisabled()">\r
86                                               <a href ng-click="nextPage()">Next »</a>\r
87                                             </li>\r
88                         </ul>\r
89                     </div>\r
90                 </div>\r
91             </div>\r
92             {% comment %}\r
93             <div id="reservation-table-scroll-container">\r
94                 <table id='{{domid}}-reservation-table' class='table table-bordered'>\r
95                     <thead>\r
96                         <tr>\r
97                             {% for ts in time_slots %}\r
98                             <th class='center info'>{{ ts|safe }}</th>\r
99                             {% endfor %}\r
100                         </tr>\r
101                     </thead>\r
102                     <tbody>\r
103 \r
104                         {% for itms in nodes %}\r
105                         {% for n in itms.1 %}\r
106                         <tr data-trindex="">\r
107                             {% for ts in time_slots %}\r
108                             {% if n == 'node020' %}\r
109                             <td class="maintenance closed" data-tdindex="{{forloop.counter}}"></td>\r
110                             {% elif n == 'node023' or n == 'node030' %}\r
111                             <td class="closed" data-tdindex="{{forloop.counter}}"></td>\r
112                             {% else %}\r
113                             <td class="" data-tdindex="{{forloop.counter}}"></td>\r
114                             {% endif %}\r
115                             {% endfor %}\r
116                         </tr>\r
117                         {% endfor %}\r
118                         {% endfor %}\r
119                     </tbody>\r
120                 </table>\r
121             </div>\r
122             {% endcomment  %}\r
123 \r
124             <div class="legend">\r
125                 <ol>\r
126                     <li class="free">Free</li>\r
127                     <li class="selected">Reserved</li>\r
128                     <li class="pendingin">Reservation pending</li>\r
129                     <li class="pendingout">Reservation cancellation pending</li>\r
130                     <li class="closed">Unavailable</li>\r
131                                         <li class="disabled">Forbidden</li>\r
132                     <li class="maintenance">Maintenance</li>\r
133                 </ol>\r
134             </div>\r
135         </div><!-- / scheduler plugin -->\r
136         <script type="text/javascript">\r
137             //alert("1");\r
138         </script>\r
139     </div>\r