blob: 98cc0c16d3de0a1cdfa5343dd79e52c913e60f9f [file] [log] [blame]
Scott Baker0088cb12014-10-27 23:02:48 -07001<script src="{{ STATIC_URL }}/js/vendor/underscore-min.js"></script>
2<script src="{{ STATIC_URL }}/js/vendor/backbone.js"></script>
3<script src="{{ STATIC_URL }}/js/vendor/backbone.syphon.js"></script>
4<script src="{{ STATIC_URL }}/js/vendor/backbone.wreqr.js"></script>
5<script src="{{ STATIC_URL }}/js/vendor/backbone.babysitter.js"></script>
6<script src="{{ STATIC_URL }}/js/vendor/backbone.marionette.js"></script>
7
8<link rel="stylesheet" type="text/css" href="{% static 'css/test.css' %}" media="all" >
9
10<script src="{{ STATIC_URL }}/js/xoslib/xos-backbone.js"></script>
11<script src="{{ STATIC_URL }}/js/test.js"></script>
12
13<p>This shows all of the things you can see using xosLib</p>
14
15<h3>Deployments</h3>
16<div id="deploymentList">
17</div>
18
19<h3>Images</h3>
20<div id="imageList">
21</div>
22
23<h3>Network Templates</h3>
24<div id="networkTemplateList">
25</div>
26
27<h3>Networks</h3>
28<div id="networkList">
29</div>
30
31<h3>Nodes</h3>
32<div id="nodeList">
33</div>
34
35<h3>Services</h3>
36<div id="serviceList">
37</div>
38
39<h3>Sites</h3>
40<div id="siteList">
41</div>
42
43<h3>Slices</h3>
44<div id="sliceList">
45</div>
46
47<h3>Slivers</h3>
48<div id="sliverList">
49</div>
50
Scott Baker29577222014-10-28 14:46:13 -070051<div id="rightSide">
52<div id="errorBox">
53</div>
54
Scott Baker9d8760e2014-10-28 12:44:13 -070055<div id="detailBox">
56<button id="close-detail-view">Close Detail View</button>
57<div id="detail"></div>
58<div id="linkedObjs1"></div>
59<div id="linkedObjs2"></div>
60</div>
Scott Baker29577222014-10-28 14:46:13 -070061</div>
62
63<script type="text/template" id="test-error-template">
64 <button id="close-error-box">Close Error Message</button>
65 <h3>An error has occurred.</h3>
66 <table class="test-error-table">
67 <tr><td>Code:</td><td><%= status %></td></tr>
68 <tr><td>Message:</td><td><%= statusText %></td></tr>
69 </table>
70</script>
Scott Baker9d8760e2014-10-28 12:44:13 -070071
Scott Baker0088cb12014-10-27 23:02:48 -070072<!-- Deployment -->
73
74<script type="text/template" id="test-deployment-list-template">
75 <table class="test-table">
76 <thead><tr>
77 <th>id</th>
78 <th>name</th>
79 <th>backend</th>
80 <th>admin_tenant</th>
81 <th># sites</th>
82 </tr></thead>
83 <tbody></tbody>
84 </table>
85</script>
86
87
88<script type="text/template" id="test-deployment-listitem-template">
89 <td><%= id %></td>
90 <td><%= name %></td>
91 <td><%= backend_type %></td>
92 <td><%= admin_tenant %></td>
93 <td><%= sites.length %></td>
94</script>
95
Scott Baker9d8760e2014-10-28 12:44:13 -070096<script type="text/template" id="test-deployment-detail-template">
97 <h3>Detail View: Deployment</h3>
98 <form>
99 <table>
100 <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>
101 <tr><td>Backend:</td><td><input type="text" name="backend_type" value="<%= backend_type %>"></td></tr>
102 <tr><td>Admin Tenant:</td><td><input type="text" name="admin_tenant" value="<%= admin_tenant %>"></td></tr>
103 <tr><td colspan=2><button class="btn js-submit">Save</button></td></tr>
104 </table>
105 </form>
106</script>
107
Scott Baker0088cb12014-10-27 23:02:48 -0700108<!-- Image -->
109
110<script type="text/template" id="test-image-list-template">
111 <table class="test-table">
112 <thead><tr>
113 <th>id</th>
114 <th>name</th>
115 <th>disk_format</th>
116 <th>container_format</th>
117 <th>path</th>
118 </tr></thead>
119 <tbody></tbody>
120 </table>
121</script>
122
Scott Baker0088cb12014-10-27 23:02:48 -0700123<script type="text/template" id="test-image-listitem-template">
124 <td><%= id %></td>
125 <td><%= name %></td>
126 <td><%= disk_format %></td>
127 <td><%= container_format %></td>
128 <td><%= path %></td>
129</script>
130
Scott Baker9d8760e2014-10-28 12:44:13 -0700131<script type="text/template" id="test-image-detail-template">
132 <h3>Detail View: Image</h3>
133 <form>
134 <table>
135 <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>
136 <tr><td>Disk Format:</td><td><input type="text" name="backend_type" value="<%= disk_format %>"></td></tr>
137 <tr><td>Container Format:</td><td><input type="text" name="admin_tenant" value="<%= container_format %>"></td></tr>
138 <tr><td colspan=2><button class="btn js-submit">Save</button></td></tr>
139 </table>
140 </form>
141</script>
142
Scott Baker0088cb12014-10-27 23:02:48 -0700143<!-- NetworkTemplate -->
144
145<script type="text/template" id="test-networkTemplate-list-template">
146 <table class="test-table">
147 <thead><tr>
148 <th>id</th>
149 <th>name</th>
150 <th>description</th>
151 <th>visibility</th>
152 <th>translation</th>
153 <th>sharedNetworkName</th>
154 <th>sharedNetworkId</th>
155 </tr></thead>
156 <tbody></tbody>
157 </table>
158</script>
159
160
161<script type="text/template" id="test-networkTemplate-listitem-template">
162 <td><%= id %></td>
163 <td><%= name %></td>
164 <td><%= description %></td>
165 <td><%= visibility %></td>
166 <td><%= translation %></td>
167 <td><%= sharedNetworkName %></td>
168 <td><%= sharedNetworkId %></td>
169</script>
170
Scott Baker9d8760e2014-10-28 12:44:13 -0700171<script type="text/template" id="test-networkTemplate-detail-template">
172 <h3>Detail View: NetworkTemplate</h3>
173 <form>
174 <table>
175 <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>
176 <tr><td>description:</td><td><input type="text" name="description" value="<%= description %>"></td></tr>
177 <tr><td>Visibility:</td><td><input type="text" name="visibility" value="<%= visibility %>"></td></tr>
178 <tr><td>Translation:</td><td><input type="text" name="translation" value="<%= translation %>"></td></tr>
179 <tr><td>Shared Network Name:</td><td><input type="text" name="sharedNetworkName" value="<%= sharedNetworkName %>"></td></tr>
180 <tr><td>Shared Network Id:</td><td><input type="text" name="sharedNetworkId" value="<%= sharedNetworkId %>"></td></tr>
181 <tr><td colspan=2><button class="btn js-submit">Save</button></td></tr>
182 </table>
183 </form>
184</script>
185
Scott Baker0088cb12014-10-27 23:02:48 -0700186<!-- Network -->
187
188<script type="text/template" id="test-network-list-template">
189 <table class="test-table">
190 <thead><tr>
191 <th>id</th>
192 <th>name</th>
193 <th>template</th>
194 <th>ports</th>
195 <th>labels</th>
196 <th>owner</th>
197 </tr></thead>
198 <tbody></tbody>
199 </table>
200</script>
201
202
203<script type="text/template" id="test-network-listitem-template">
204 <td><%= id %></td>
205 <td><%= name %></td>
206 <td><%= template %></td>
207 <td><%= ports %></td>
208 <td><%= labels %></td>
209 <td><%= owner %></td>
210</script>
211
Scott Baker9d8760e2014-10-28 12:44:13 -0700212<script type="text/template" id="test-network-detail-template">
213 <h3>Detail View: Network</h3>
214 <form>
215 <table>
216 <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>
217 <tr><td>Template:</td><td><input type="text" name="template" value="<%= template %>"></td></tr>
218 <tr><td>Ports:</td><td><input type="text" name="ports" value="<%= ports %>"></td></tr>
219 <tr><td>Labels:</td><td><input type="text" name="labels" value="<%= labels %>"></td></tr>
220 <tr><td>Owner:</td><td><input type="text" name="owner" value="<%= owner %>"></td></tr>
221 <tr><td colspan=2><button class="btn js-submit">Save</button></td></tr>
222 </table>
223 </form>
224</script>
225
Scott Baker0088cb12014-10-27 23:02:48 -0700226<!-- Node -->
227
228<script type="text/template" id="test-node-list-template">
229 <table class="test-table">
230 <thead><tr>
231 <th>id</th>
232 <th>name</th>
233 <th>site</th>
234 <th>deployment</th>
235 </tr></thead>
236 <tbody></tbody>
237 </table>
238</script>
239
240
241<script type="text/template" id="test-node-listitem-template">
242 <td><%= id %></td>
243 <td><%= name %></td>
244 <td><%= site %></td>
245 <td><%= deployment %></td>
246</script>
247
Scott Baker9d8760e2014-10-28 12:44:13 -0700248<script type="text/template" id="test-node-detail-template">
249 <h3>Detail View: Node</h3>
250 <form>
251 <table>
252 <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>
253 <tr><td>Site:</td><td><input type="text" name="site" value="<%= site %>"></td></tr>
254 <tr><td>Deployment:</td><td><input type="text" name="deployment" value="<%= deployment %>"></td></tr>
255 <tr><td colspan=2><button class="btn js-submit">Save</button></td></tr>
256 </table>
257 </form>
258</script>
259
Scott Baker0088cb12014-10-27 23:02:48 -0700260<!-- Service -->
261
262<script type="text/template" id="test-service-list-template">
263 <table class="test-table">
264 <thead><tr>
265 <th>id</th>
266 <th>name</th>
267 <th>description</th>
268 <th>enabled</th>
269 <th>versionNumber</th>
270 <th>published</th>
271 </tr></thead>
272 <tbody></tbody>
273 </table>
274</script>
275
276
277<script type="text/template" id="test-service-listitem-template">
278 <td><%= id %></td>
279 <td><%= name %></td>
280 <td><%= description %></td>
281 <td><%= enabled %></td>
282 <td><%= versionNumber %></td>
283 <td><%= published %></td>
284</script>
285
Scott Baker9d8760e2014-10-28 12:44:13 -0700286<script type="text/template" id="test-service-detail-template">
287 <h3>Detail View: Service</h3>
288 <form>
289 <table>
290 <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>
291 <tr><td>description:</td><td><input type="text" name="description" value="<%= description %>"></td></tr>
292 <tr><td>Version Number:</td><td><input type="text" name="versionNumber" value="<%= versionNumber %>"></td></tr>
293 <tr><td colspan=2><button class="btn js-submit">Save</button></td></tr>
294 </table>
295 </form>
296</script>
297
Scott Baker0088cb12014-10-27 23:02:48 -0700298<!-- Site -->
299
300<script type="text/template" id="test-site-list-template">
301 <table class="test-table">
302 <thead><tr>
303 <th>id</th>
304 <th>name</th>
305 <th>url</th>
306 <th>enabled</th>
307 <th>login_base</th>
308 <th>is_public</th>
309 <th>abbreviated_name</th>
310 </tr></thead>
311 <tbody></tbody>
312 </table>
313</script>
314
315
316<script type="text/template" id="test-site-listitem-template">
317 <td><%= id %></td>
318 <td><%= name %></td>
319 <td><%= site_url %></td>
320 <td><%= enabled %></td>
321 <td><%= login_base %></td>
322 <td><%= is_public %></td>
323 <td><%= abbreviated_name %></td>
324</script>
325
Scott Baker9d8760e2014-10-28 12:44:13 -0700326<script type="text/template" id="test-site-detail-template">
327 <h3>Detail View: Site</h3>
328 <form>
329 <table>
330 <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>
331 <tr><td>url:</td><td><input type="text" name="site_url" value="<%= site_url %>"></td></tr>
332 <tr><td>login_base:</td><td><input type="text" name="login_base" value="<%= login_base %>"></td></tr>
333 <tr><td colspan=2><button class="btn js-submit">Save</button></td></tr>
334 </table>
335 </form>
336</script>
337
Scott Baker0088cb12014-10-27 23:02:48 -0700338<!-- Slice -->
339
340<script type="text/template" id="test-slice-list-template">
341 <table class="test-table">
342 <thead><tr>
343 <th>id</th>
344 <th>name</th>
345 <th>enabled</th>
346 <th>omf_friendly</th>
347 <th>description</th>
348 <th>slice_url</th>
349 <th>site</th>
350 <th>max_slivers</th>
351 <th>service</th>
352 </tr></thead>
353 <tbody></tbody>
354 </table>
355</script>
356
Scott Baker0088cb12014-10-27 23:02:48 -0700357<script type="text/template" id="test-slice-listitem-template">
358 <td><%= id %></td>
359 <td><%= name %></td>
360 <td><%= enabled %></td>
361 <td><%= omf_friendly %></td>
362 <td><%= description %></td>
363 <td><%= slice_url %></td>
364 <td><%= site %></td>
365 <td><%= max_slivers %></td>
366 <td><%= service %></td>
367</script>
368
Scott Baker9d8760e2014-10-28 12:44:13 -0700369<script type="text/template" id="test-slice-detail-template">
370 <h3>Detail View: Slice</h3>
371 <form>
372 <table>
373 <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>
374 <tr><td>Enabled:</td><td><input type="checkbox" name="enabled" <% if (enabled) print("checked"); %>></td></tr>
375 <tr><td>Description:</td><td><input type="text" name="description" value="<%= description %>"></td></tr>
376 <tr><td>Url:</td><td><input type="text" name="slice_url" value="<%= slice_url %>"></td></tr>
377 <tr><td>Max Slivers:</td><td><input type="text" name="max_slivers" value="<%= max_slivers %>"></td></tr>
378 <tr><td colspan=2><button class="btn js-submit">Save</button></td></tr>
379 </table>
380 </form>
381</script>
382
Scott Baker0088cb12014-10-27 23:02:48 -0700383<!-- Sliver -->
384
385<script type="text/template" id="test-sliver-list-template">
386 <table class="test-table">
387 <thead><tr>
388 <th>id</th>
389 <th>name</th>
390 <th>instance_id</th>
391 <th>instance_name</th>
392 <th>image</th>
393 <th>creator</th>
394 <th>slice</th>
395 <th>node</th>
396 <th>deploymentNetwork</th>
397 <th>flavor</th>
398 <th>userData</th>
399 </tr></thead>
400 <tbody></tbody>
401 </table>
402</script>
403
404
405<script type="text/template" id="test-sliver-listitem-template">
406 <td><%= id %></td>
407 <td><%= name %></td>
408 <td><%= instance_id %></td>
409 <td><%= instance_name %></td>
410 <td><%= image %></td>
411 <td><%= creator %></td>
412 <td><%= slice %></td>
413 <td><%= node %></td>
414 <td><%= deploymentNetwork %></td>
415 <td><%= flavor %></td>
416 <td><%= userData %></td>
417</script>
418
Scott Baker9d8760e2014-10-28 12:44:13 -0700419<script type="text/template" id="test-sliver-detail-template">
420 <h3>Detail View: Sliver</h3>
421 <form>
422 <table>
423 <tr><td>Name:</td><td><input type="text" name="name" value="<%= name %>"></td></tr>
424 <tr><td>instance_id:</td><td><input type="text" name="instance_id" value="<%= instance_id %>"></td></tr>
425 <tr><td>instance_name:</td><td><input type="text" name="instance_name" value="<%= instance_name %>"></td></tr>
426 <tr><td>Image:</td><td><input type="text" name="image" value="<%= image %>"></td></tr>
427 <tr><td>Creator:</td><td><input type="text" name="creator" value="<%= creator %>"></td></tr>
428 <tr><td>Slice:</td><td><input type="text" name="slice" value="<%= slice %>"></td></tr>
429 <tr><td colspan=2><button class="btn js-submit">Save</button></td></tr>
430 </table>
431 </form>
432</script>
433
Scott Baker0088cb12014-10-27 23:02:48 -0700434</script>
435