refresh button working, spinning circle, navigate function, tolerate sites==undefined...
[plstackapi.git] / planetstack / core / xoslib / templates / xosAdmin.html
1 <!-- Error and Success templates -->
2
3 <script type="text/template" id="xos-error-template">
4   <button id="close-error-box">Close Error Message</button>
5   <h3>An error has occurred.</h3>
6   <table class="test-error-table">
7   <tr><td>Code:</td><td><%= status %></td></tr>
8   <tr><td>Message:</td><td><%= statusText %></td></tr>
9   </table>
10 </script>
11
12 <script type="text/template" id="xos-success-template">
13   <button id="close-success-box">Close Success Message</button>
14   <h3>Success!</h3>
15   <table class="test-success-table">
16   <tr><td>Code:</td><td><%= status %></td></tr>
17   <tr><td>Message:</td><td><%= statusText %></td></tr>
18   </table>
19 </script>
20
21 <script type="text/template" id="xos-navbutton-old">
22   <button class="btn btn-default btn-xosnav" onclick="<%= router %>.navigate('<%= routeUrl %>', {trigger: true})"><%= name %></button><br>
23 </script>
24
25 <script type="text/template" id="xos-status-template">
26   <div class="xos-status xos-<%= statusclass %>"><%= what %>: <%= statusText %> (<%= status %>)</div>
27 </script>
28
29 <script type="text/template" id="xos-tabs-template">
30   <ul class="xos-nav-list">
31   <% _.each(tabs, function(tab) { %>
32       <li class="xos-nav-item" id="xos-nav-<%= tab["region"] %>"><%= tab["name"] %></li>
33   <% }); %>
34   </ul>
35 </script>
36
37 <script type="text/template" id="xos-title-list">
38   <h3><img src="/static/img/brokencircle.gif" height=16 width=16 id="xos-list-title-spinner"> <%= title %></h3>
39 </script>
40
41 <script type="text/template" id="xos-title-detail">
42   <h3><%= title %></h3>
43 </script>
44
45 <script type="text/template" id="xos-navbutton">
46   <li>
47       <a href="<%= routeUrl %>">
48           <i class="<%= iconClass %>"></i>
49           <%= name %>
50       </a>
51   </li>
52 </script>
53
54 <script type="text/template" id="xos-inline-detail-buttons-template">
55     <tr>
56        <td colspan=2><button class="btn js-submit btn-xos-detail btn-xos-save-leave">Save</button>
57            <button class="btn js-submit btn-xos-detail btn-xos-save-continue">Save and Continue Editing</button>
58            <button class="btn js-submit btn-xos-detail btn-xos-save-another">Save and Add Another</button>
59            <button class="btn js-submit btn-xos-detail btn-xos-delete">Delete</button>
60        </td>
61     </tr>
62 </script>
63
64 <script type="text/template" id="xos-inline-list-buttons-template">
65            <button class="btn js-submit btn-xos-list btn-xos-add">Add</button>
66            <button class="btn js-submit btn-xos-list btn-xos-refresh">Refresh</button>
67        </td>
68     </tr>
69 </script>
70
71 <!-- Deployment -->
72
73 <script type="text/template" id="xosAdmin-deployment-list-template">
74   <h3 class="xos-list-title"><%= title %></h3>
75   <%= xosInlineListButtonsTemplate() %>
76   <table class="test-table">
77   <thead><tr>
78      <th>id</th>
79      <th>name</th>
80      <th>backend</th>
81      <th>admin_tenant</th>
82      <th># sites</th>
83   </tr></thead>
84   <tbody></tbody>
85   </table>
86 </script>
87
88
89 <script type="text/template" id="xosAdmin-deployment-listitem-template">
90   <td class="objectLink"><%= id %></td>
91   <td class="objectLink"><%= name %></td>
92   <td><%= backend_type %></td>
93   <td><%= admin_tenant %></td>
94   <td><%= typeof sites != 'undefined' && sites.length || 0 %></td>
95 </script>
96
97 <script type="text/template" id="xosAdmin-deployment-detail-template">
98   <h3 class="xos-detail-title">Detail View: Deployment</h3>
99   <form>
100   <table>\r
101   <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>\r
102   <tr><td>Backend:</td><td><input type="text" name="backend_type" value="<%= backend_type %>"></td></tr>\r
103   <tr><td>Admin Tenant:</td><td><input type="text" name="admin_tenant" value="<%= admin_tenant %>"></td></tr>\r
104   <%= xosInlineDetailButtonsTemplate() %>\r
105   </table>\r
106   </form>\r
107 </script>\r
108
109 <!-- Image -->
110
111 <script type="text/template" id="xosAdmin-image-list-template">
112   <h3 class="xos-list-title"><%= title %></h3>
113   <%= xosInlineListButtonsTemplate() %>
114   <table class="test-table">
115   <thead><tr>
116      <th>id</th>
117      <th>name</th>
118      <th>disk_format</th>
119      <th>container_format</th>
120      <th>path</th>
121   </tr></thead>
122   <tbody></tbody>
123   </table>
124 </script>
125
126 <script type="text/template" id="xosAdmin-image-listitem-template">
127   <td class="objectLink"><%= id %></td>
128   <td class="objectLink"><%= name %></td>
129   <td><%= disk_format %></td>
130   <td><%= container_format %></td>
131   <td><%= path %></td>
132 </script>
133
134 <script type="text/template" id="xosAdmin-image-detail-template">
135   <h3 class="xos-detail-title">Detail View: Image</h3>
136   <form>\r
137   <table>\r
138   <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>\r
139   <tr><td>Disk Format:</td><td><input type="text" name="backend_type" value="<%= disk_format %>"></td></tr>\r
140   <tr><td>Container Format:</td><td><input type="text" name="admin_tenant" value="<%= container_format %>"></td></tr>\r
141   <%= xosInlineDetailButtonsTemplate() %>\r
142   </table>\r
143   </form>\r
144 </script>
145
146 <!-- NetworkTemplate -->
147
148 <script type="text/template" id="xosAdmin-networkTemplate-list-template">
149   <h3 class="xos-list-title"><%= title %></h3>
150   <%= xosInlineListButtonsTemplate() %>
151   <table class="test-table">
152   <thead><tr>
153      <th>id</th>
154      <th>name</th>
155      <th>description</th>
156      <th>visibility</th>
157      <th>translation</th>
158      <th>sharedNetworkName</th>
159      <th>sharedNetworkId</th>
160   </tr></thead>
161   <tbody></tbody>
162   </table>
163 </script>
164
165
166 <script type="text/template" id="xosAdmin-networkTemplate-listitem-template">
167   <td class="objectLink"><%= id %></td>
168   <td class="objectLink"><%= name %></td>
169   <td><%= description %></td>
170   <td><%= visibility %></td>
171   <td><%= translation %></td>
172   <td><%= sharedNetworkName %></td>
173   <td><%= sharedNetworkId %></td>
174 </script>
175
176 <script type="text/template" id="xosAdmin-networkTemplate-detail-template">
177   <h3 class="xos-detail-title">Detail View: NetworkTemplate</h3>
178   <form>\r
179   <table>\r
180   <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>\r
181   <tr><td>description:</td><td><input type="text" name="description" value="<%= description %>"></td></tr>\r
182   <tr><td>Visibility:</td><td><input type="text" name="visibility" value="<%= visibility %>"></td></tr>\r
183   <tr><td>Translation:</td><td><input type="text" name="translation" value="<%= translation %>"></td></tr>\r
184   <tr><td>Shared Network Name:</td><td><input type="text" name="sharedNetworkName" value="<%= sharedNetworkName %>"></td></tr>\r
185   <tr><td>Shared Network Id:</td><td><input type="text" name="sharedNetworkId" value="<%= sharedNetworkId %>"></td></tr>\r
186   <%= xosInlineDetailButtonsTemplate() %>\r
187   </table>\r
188   </form>\r
189 </script>
190
191 <!-- Network -->
192
193 <script type="text/template" id="xosAdmin-network-list-template">
194   <h3 class="xos-list-title"><%= title %></h3>
195   <%= xosInlineListButtonsTemplate() %>
196   <table class="test-table">
197   <thead><tr>
198      <th>id</th>
199      <th>name</th>
200      <th>template</th>
201      <th>ports</th>
202      <th>labels</th>
203      <th>owner</th>
204   </tr></thead>
205   <tbody></tbody>
206   </table>
207 </script>
208
209 <script type="text/template" id="xosAdmin-network-listitem-template">
210   <td class="objectLink"><%= id %></td>
211   <td class="objectLink"><%= name %></td>
212   <td><%= idToName(template,"networkTemplates","name") %></td>
213   <td><%= ports %></td>
214   <td><%= labels %></td>
215   <td><%= idToName(owner,"slices","name") %></td>
216 </script>
217
218 <script type="text/template" id="xosAdmin-network-detail-template">
219   <h3 class="xos-detail-title">Detail View: Network</h3>
220   <form>\r
221   <table>\r
222   <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>\r
223   <tr><td>Template:</td><td><%= idToSelect("template",template,"networkTemplates","name") %></td></tr>\r
224   <tr><td>Ports:</td><td><input type="text" name="ports" value="<%= ports %>"></td></tr>\r
225   <tr><td>Labels:</td><td><input type="text" name="labels" value="<%= labels %>"></td></tr>\r
226   <tr><td>Owner:</td><td><%= idToSelect("owner",owner,"slices","name") %></td></tr>\r
227   <%= xosInlineDetailButtonsTemplate() %>\r
228   </table>\r
229   </form>\r
230 </script>
231
232 <!-- NetworkSliver -->
233
234 <script type="text/template" id="xosAdmin-networkSliver-list-template">
235   <h3 class="xos-list-title"><%= title %></h3>
236   <%= xosInlineListButtonsTemplate() %>
237   <table class="test-table">
238   <thead><tr>
239      <th>id</th>
240      <th>network</th>
241      <th>sliver</th>
242      <th>ip</th>
243      <th>port_id</th>
244   </tr></thead>
245   <tbody></tbody>
246   </table>
247 </script>
248
249 <script type="text/template" id="xosAdmin-networkSliver-listitem-template">
250   <td class="objectLink"><%= id %></td>
251   <td><%= idToName(network,"networks","name") %></td>
252   <td><%= idToName(sliver,"slivers","name") %></td>
253   <td><%= ip %></td>
254   <td><%= port_id %></td>
255 </script>
256
257 <script type="text/template" id="xosAdmin-networkSliver-detail-template">
258   <h3 class="xos-detail-title">Detail View: Network</h3>
259   <form>\r
260   <table>\r
261   <tr><td>Network:</td><td><input type="text" name="network" value="<%= network %>"></td></tr>\r
262   <tr><td>Sliver:</td><td><input type="text" name="sliver" value="<%= sliver %>"></td></tr>\r
263   <tr><td>Ip:</td><td><input type="text" name="ip" value="<%= ip %>"></td></tr>\r
264   <tr><td>Port_id:</td><td><input type="text" name="port_id" value="<%= port_id %>"></td></tr>\r
265   <%= xosInlineDetailButtonsTemplate() %>\r
266   </table>\r
267   </form>\r
268 </script>
269
270 <!-- NetworkDeployment -->
271
272 <script type="text/template" id="xosAdmin-networkDeployment-list-template">
273   <h3 class="xos-list-title"><%= title %></h3>
274   <%= xosInlineListButtonsTemplate() %>
275   <table class="test-table">
276   <thead><tr>
277      <th>id</th>
278      <th>network</th>
279      <th>deployment</th>
280      <th>net_id</th>
281   </tr></thead>
282   <tbody></tbody>
283   </table>
284 </script>
285
286 <script type="text/template" id="xosAdmin-networkDeployment-listitem-template">
287   <td class="objectLink"><%= id %></td>
288   <td><%= idToName(network,"networks","name") %></td>
289   <td><%= idToName(deployment,"deployments","name") %></td>
290   <td><%= net_id %></td>
291 </script>
292
293 <script type="text/template" id="xosAdmin-networkDeployment-detail-template">
294   <h3 class="xos-detail-title">Detail View: Network</h3>
295   <form>\r
296   <table>\r
297   <tr><td>Network:</td><td><input type="text" name="network" value="<%= network %>"></td></tr>\r
298   <tr><td>Sliver:</td><td><input type="text" name="deployment" value="<%= deployment %>"></td></tr>\r
299   <tr><td>Ip:</td><td><input type="text" name="net_id" value="<%= net_id %>"></td></tr>\r
300   <%= xosInlineDetailButtonsTemplate() %>\r
301   </table>\r
302   </form>\r
303 </script>
304
305 <!-- Node -->
306
307 <script type="text/template" id="xosAdmin-node-list-template">
308   <h3 class="xos-list-title"><%= title %></h3>
309   <%= xosInlineListButtonsTemplate() %>
310   <table class="test-table">
311   <thead><tr>
312      <th>id</th>
313      <th>name</th>
314      <th>site</th>
315      <th>deployment</th>
316   </tr></thead>
317   <tbody></tbody>
318   </table>
319 </script>
320
321
322 <script type="text/template" id="xosAdmin-node-listitem-template">
323   <td class="objectLink"><%= id %></td>
324   <td class="objectLink"><%= name %></td>
325   <td><%= idToName(site,"sites","name") %></td>
326   <td><%= idToName(deployment,"deployments","name") %></td>
327 </script>
328
329 <script type="text/template" id="xosAdmin-node-detail-template">
330   <h3 class="xos-detail-title">Detail View: Node</h3>
331   <form>\r
332   <table>\r
333   <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>\r
334   <tr><td>Site:</td><td><%= idToSelect("site",site,"sites","name") %></td></tr>\r
335   <tr><td>Deployment:</td><td><%= idToSelect("deployment",deployment,"deployments","name") %></td></tr>\r
336   <%= xosInlineDetailButtonsTemplate() %>\r
337   </table>\r
338   </form>\r
339 </script>
340
341 <!-- SliceRole -->
342
343 <script type="text/template" id="xosAdmin-sliceRole-list-template">
344   <h3 class="xos-list-title"><%= title %></h3>
345   <%= xosInlineListButtonsTemplate() %>
346   <table class="test-table">
347   <thead><tr>
348      <th>id</th>
349      <th>role</th>
350   </tr></thead>
351   <tbody></tbody>
352   </table>
353 </script>
354
355
356 <script type="text/template" id="xosAdmin-sliceRole-listitem-template">
357   <td class="objectLink"><%= id %></td>
358   <td><%= role %></td>
359 </script>
360
361 <script type="text/template" id="xosAdmin-sliceRole-detail-template">
362   <h3 class="xos-detail-title">Detail View: Service</h3>
363   <form>\r
364   <table>\r
365   <tr><td>Role:</td><td><input type="text" name="role" value="<%= role %>"></td></tr>\r
366   <%= xosInlineDetailButtonsTemplate() %>\r
367   </table>\r
368   </form>\r
369 </script>
370
371 <!-- Service -->
372
373 <script type="text/template" id="xosAdmin-service-list-template">
374   <h3 class="xos-list-title"><%= title %></h3>
375   <%= xosInlineListButtonsTemplate() %>
376   <table class="test-table">
377   <thead><tr>
378      <th>id</th>
379      <th>name</th>
380      <th>description</th>
381      <th>enabled</th>
382      <th>versionNumber</th>
383      <th>published</th>
384   </tr></thead>
385   <tbody></tbody>
386   </table>
387 </script>
388
389
390 <script type="text/template" id="xosAdmin-service-listitem-template">
391   <td class="objectLink"><%= id %></td>
392   <td class="objectLink"><%= name %></td>
393   <td><%= description %></td>
394   <td><%= enabled %></td>
395   <td><%= versionNumber %></td>
396   <td><%= published %></td>
397 </script>
398
399 <script type="text/template" id="xosAdmin-service-detail-template">
400   <h3 class="xos-detail-title">Detail View: Service</h3>
401   <form>\r
402   <table>\r
403   <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>\r
404   <tr><td>description:</td><td><input type="text" name="description" value="<%= description %>"></td></tr>\r
405   <tr><td>Version Number:</td><td><input type="text" name="versionNumber" value="<%= versionNumber %>"></td></tr>\r
406   <%= xosInlineDetailButtonsTemplate() %>\r
407   </table>\r
408   </form>\r
409 </script>
410
411 <!-- Site -->
412
413 <script type="text/template" id="xosAdmin-site-list-template">
414   <h3 class="xos-list-title"><%= title %></h3>
415   <%= xosInlineListButtonsTemplate() %>
416   <table class="test-table">
417   <thead><tr>
418      <th>id</th>
419      <th>name</th>
420      <th>url</th>
421      <th>enabled</th>
422      <th>login_base</th>
423      <th>is_public</th>
424      <th>abbreviated_name</th>
425   </tr></thead>
426   <tbody></tbody>
427   </table>
428 </script>
429
430 <script type="text/template" id="xosAdmin-site-listitem-template">
431   <td class="objectLink"><%= id %></td>
432   <td class="objectLink"><%= name %></td>
433   <td><%= site_url %></td>
434   <td><%= enabled %></td>
435   <td><%= login_base %></td>
436   <td><%= is_public %></td>
437   <td><%= abbreviated_name %></td>
438 </script>
439
440 <script type="text/template" id="xosAdmin-site-detail-template">
441   <h3 class="xos-detail-title">Detail View: Site</h3>
442   <form>\r
443   <table>\r
444   <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>\r
445   <tr><td>abbreviated_name:</td><td><input type="text" name="abbreviated_name" value="<%= abbreviated_name %>"></td></tr>\r
446   <tr><td>url:</td><td><input type="text" name="site_url" value="<%= site_url %>"></td></tr>\r
447   <tr><td>Enabled:</td><td><input type="checkbox" name="enabled" <% if (enabled) print("checked"); %>></td></tr>\r
448   <tr><td>Is Public:</td><td><input type="checkbox" name="is_public" <% if (is_public) print("checked"); %>></td></tr>\r
449   <tr><td>login_base:</td><td><input type="text" name="login_base" value="<%= login_base %>"></td></tr>\r
450   <%= xosInlineDetailButtonsTemplate() %>\r
451   </table>\r
452   </form>\r
453 </script>
454
455 <!-- Slice -->
456
457 <script type="text/template" id="xosAdmin-slice-list-template">
458   <h3 class="xos-list-title"><%= title %></h3>
459   <%= xosInlineListButtonsTemplate() %>
460   <table class="test-table">
461   <thead><tr>
462      <th>id</th>
463      <th>name</th>
464      <th>enabled</th>
465      <th>omf_friendly</th>
466      <th>description</th>
467      <th>slice_url</th>
468      <th>site</th>
469      <th>max_slivers</th>
470      <th>service</th>
471   </tr></thead>
472   <tbody></tbody>
473   </table>
474 </script>
475
476 <script type="text/template" id="xosAdmin-slice-listitem-template">
477   <td class="objectLink"><%= id %></td>
478   <td class="objectLink"><%= name %></td>
479   <td><%= enabled %></td>
480   <td><%= omf_friendly %></td>
481   <td><%= description %></td>
482   <td><%= slice_url %></td>
483   <td><%= idToName(site,"sites","name") %></td>
484   <td><%= max_slivers %></td>
485   <td><%= idToName(service,"services","name") %></td>
486 </script>
487
488 <script type="text/template" id="xosAdmin-slice-detail-template">
489   <h3 class="xos-detail-title">Detail View: Slice</h3>
490   <form>\r
491   <table>\r
492   <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>\r
493   <tr><td>Site:</td><td><%= idToSelect("site",site,"sites","name") %></td></tr>\r
494   <tr><td>Enabled:</td><td><input type="checkbox" name="enabled" <% if (enabled) print("checked"); %>></td></tr>\r
495   <tr><td>Description:</td><td><input type="text" name="description" value="<%= description %>"></td></tr>\r
496   <tr><td>Url:</td><td><input type="text" name="slice_url" value="<%= slice_url %>"></td></tr>\r
497   <tr><td>Max Slivers:</td><td><input type="text" name="max_slivers" value="<%= max_slivers %>"></td></tr>\r
498   <%= xosInlineDetailButtonsTemplate() %>\r
499   </table>\r
500   </form>\r
501 </script>
502
503 <!-- SliceDeployment -->
504
505 <script type="text/template" id="xosAdmin-sliceDeployment-list-template">
506   <h3 class="xos-list-title"><%= title %></h3>
507   <%= xosInlineListButtonsTemplate() %>
508   <table class="test-table">
509   <thead><tr>
510      <th>id</th>
511      <th>slice</th>
512      <th>deployment</th>
513      <th>tenant_id</th>
514   </tr></thead>
515   <tbody></tbody>
516   </table>
517 </script>
518
519 <script type="text/template" id="xosAdmin-sliceDeployment-listitem-template">
520   <td class="objectLink"><%= id %></td>
521   <td><%= idToName(slice,"slices","name") %></td>
522   <td><%= idToName(deployment,"deployments","name") %></td>
523   <td><%= tenant_id %></td>
524 </script>
525
526 <script type="text/template" id="xosAdmin-sliceDeployment-detail-template">
527   <h3 class="xos-detail-title">Detail View: Slice Deployment</h3>
528   <form>\r
529   <table>\r
530   <tr><td>Slice:</td><td><input type="text" name="slice" value="<%= slice %>"></td></tr>\r
531   <tr><td>Deployment:</td><td><input type="text" name="deployment" value="<%= deployment %>"></td></tr>\r
532   <tr><td>Tenant Id:</td><td><input type="text" name="tenant_id" value="<%= tenant_id %>"></td></tr>\r
533   <%= xosInlineDetailButtonsTemplate() %>\r
534   </table>\r
535   </form>\r
536 </script>
537
538 <!-- SlicePrivilege -->
539
540 <script type="text/template" id="xosAdmin-slicePrivilege-list-template">
541   <h3 class="xos-list-title"><%= title %></h3>
542   <%= xosInlineListButtonsTemplate() %>
543   <table class="test-table">
544   <thead><tr>
545      <th>id</th>
546      <th>user</th>
547      <th>slice</th>
548      <th>role</th>
549   </tr></thead>
550   <tbody></tbody>
551   </table>
552 </script>
553
554 <script type="text/template" id="xosAdmin-slicePrivilege-listitem-template">
555   <td class="objectLink"><%= id %></td>
556   <td><%= idToName(user,"users","username") %></td>
557   <td><%= idToName(slice,"slices","name") %></td>
558   <td><%= idToName(role,"sliceRoles","role") %></td>
559 </script>
560
561 <script type="text/template" id="xosAdmin-slicePrivilege-detail-template">
562   <h3 class="xos-detail-title">Detail View: Slice Privilege</h3>
563   <form>\r
564   <table>\r
565   <tr><td>User:</td><td><input type="text" name="user" value="<%= user %>"></td></tr>\r
566   <tr><td>Slice:</td><td><input type="text" name="slice" value="<%= slice %>"></td></tr>\r
567   <tr><td>Role:</td><td><input type="text" name="role" value="<%= role %>"></td></tr>\r
568   <%= xosInlineDetailButtonsTemplate() %>\r
569   </table>\r
570   </form>\r
571 </script>
572
573 <!-- Sliver -->
574
575 <script type="text/template" id="xosAdmin-sliver-list-template">
576   <h3 class="xos-list-title"><%= title %></h3>
577   <%= xosInlineListButtonsTemplate() %>
578   <table class="test-table">
579   <thead><tr>
580      <th>id</th>
581      <th>name</th>
582      <th>instance_id</th>
583      <th>instance_name</th>
584      <th>image</th>
585      <th>creator</th>
586      <th>slice</th>
587      <th>node</th>
588      <th>deploymentNetwork</th>
589      <th>flavor</th>
590      <th>userData</th>
591   </tr></thead>
592   <tbody></tbody>
593   </table>
594 </script>
595
596
597 <script type="text/template" id="xosAdmin-sliver-listitem-template">
598   <td class="objectLink"><%= id %></td>
599   <td class="objectLink"><%= name %></td>
600   <td><%= instance_id %></td>
601   <td><%= instance_name %></td>
602   <td><%= idToName(image,"images","name") %></td>
603   <td><%= idToName(creator,"users","name") %></td>
604   <td><%= idToName(slice,"slices","name") %></td>
605   <td><%= idToName(node,"nodes","name") %></td>
606   <td><%= idToName(deploymentNetwork,"deployments","name") %></td>
607   <td><%= flavor %></td>
608   <td><%= userData %></td>
609 </script>
610
611 <script type="text/template" id="xosAdmin-sliver-detail-template">
612   <h3 class="xos-detail-title">Detail View: Sliver</h3>
613   <form>\r
614   <table>\r
615   <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>\r
616   <tr><td>instance_id:</td><td><input type="text" name="instance_id" value="<%= instance_id %>"></td></tr>\r
617   <tr><td>instance_name:</td><td><input type="text" name="instance_name" value="<%= instance_name %>"></td></tr>\r
618   <tr><td>Image:</td><td><%= idToSelect("image",image,"images","name") %></td></tr>\r
619   <tr><td>Creator:</td><td><%= idToSelect("creator",creator,"users","username") %></td></tr>\r
620   <tr><td>Slice:</td><td><%= idToSelect("slice",slice,"slices","name") %></td></tr>\r
621   <tr><td>Deployment:</td><td><%= idToSelect("deploymentNetwork",deploymentNetwork,"deployments","name") %></td></tr>\r
622   <%= xosInlineDetailButtonsTemplate() %>\r
623   </table>\r
624   </form>\r
625 </script>
626
627 <!-- User -->
628
629 <script type="text/template" id="xosAdmin-user-list-template">
630   <h3 class="xos-list-title"><%= title %></h3>
631   <%= xosInlineListButtonsTemplate() %>
632   <table class="test-table">
633   <thead><tr>
634      <th>id</th>
635      <th>username</th>
636      <th>firstname</th>
637      <th>lastname</th>
638      <th>phone</th>
639      <th>user_url</th>
640      <th>site</th>
641   </tr></thead>
642   <tbody></tbody>
643   </table>
644 </script>
645
646
647 <script type="text/template" id="xosAdmin-user-listitem-template">
648   <td class="objectLink"><%= id %></td>
649   <td class="objectLink"><%= username %></td>
650   <td><%= firstname %></td>
651   <td><%= lastname %></td>
652   <td><%= phone %></td>
653   <td><%= user_url %></td>
654   <td><%= idToName(site,"sites","name") %></td>
655 </script>
656
657 <script type="text/template" id="xosAdmin-user-detail-template">
658   <h3 class="xos-detail-title">Detail View: User</h3>
659   <form>\r
660   <table>\r
661   <tr><td>User Name:</td><td><input type="text" name="username" value="<%= username %>"></td></tr>\r
662   <tr><td>First Name:</td><td><input type="text" name="firstname" value="<%= firstname %>"></td></tr>\r
663   <tr><td>Last Name:</td><td><input type="text" name="lastname" value="<%= lastname %>"></td></tr>\r
664   <tr><td>Phone:</td><td><input type="text" name="phone" value="<%= phone %>"></td></tr>\r
665   <tr><td>Url:</td><td><input type="text" name="user_url" value="<%= user_url %>"></td></tr>\r
666   <tr><td>Site:</td><td><%= idToSelect("site",site,"sites","name") %></td></tr>\r
667   <%= xosInlineDetailButtonsTemplate() %>\r
668   </table>\r
669   </form>\r
670 </script>
671
672 <!-- UserDeployments -->
673
674 <script type="text/template" id="xosAdmin-userDeployment-list-template">
675   <h3 class="xos-list-title"><%= title %></h3>
676   <%= xosInlineListButtonsTemplate() %>
677   <table class="test-table">
678   <thead><tr>
679      <th>id</th>
680      <th>user</th>
681      <th>deployment</th>
682      <th>kuser_id</th>
683   </tr></thead>
684   <tbody></tbody>
685   </table>
686 </script>
687
688 <script type="text/template" id="xosAdmin-userDeployment-listitem-template">
689   <td class="objectLink"><%= id %></td>
690   <td><%= idToName(user,"users","username") %></td>
691   <td><%= idToName(deployment,"deployments","name") %></td>
692   <td><%= kuser_id %></td>
693 </script>
694
695 <script type="text/template" id="xosAdmin-userDeployment-detail-template">
696   <h3 class="xos-detail-title">Detail View: UserDeployment</h3>
697   <form>\r
698   <table>\r
699   <tr><td>User:</td><td><input type="text" name="user" value="<%= user %>"></td></tr>\r
700   <tr><td>Deployment:</td><td><input type="text" name="deployment" value="<%= deployment %>"></td></tr>\r
701   <tr><td>kuser_id:</td><td><input type="text" name="kuser_id" value="<%= kuser_id %>"></td></tr>\r
702   <%= xosInlineDetailButtonsTemplate() %>\r
703   </table>\r
704   </form>\r
705 </script>
706
707 <script>
708 xosInlineDetailButtonsTemplate = _.template($("#xos-inline-detail-buttons-template").html());
709 xosInlineListButtonsTemplate = _.template($("#xos-inline-list-buttons-template").html());
710 </script>