header and footer templates for list views
authorScott Baker <smbaker@gmail.com>
Fri, 5 Dec 2014 01:23:27 +0000 (17:23 -0800)
committerScott Baker <smbaker@gmail.com>
Fri, 5 Dec 2014 01:23:27 +0000 (17:23 -0800)
planetstack/core/xoslib/templates/xosAdmin.html

index 854a852..3d5d1a6 100644 (file)
     </tr>
 </script>
 
-<script type="text/template" id="xos-inline-list-buttons-template">
-           <button class="btn js-submit btn-xos-list btn-xos-add">Add</button>
-           <button class="btn js-submit btn-xos-list btn-xos-refresh">Refresh</button>
-       </td>
-    </tr>
+<script type="text/template" id="xos-list-header-template">
+    <button class="btn js-submit btn-xos-list btn-xos-add">Add</button>
+    <button class="btn js-submit btn-xos-list btn-xos-refresh">Refresh</button>
+</script>
+
+<script type="text/template" id="xos-list-footer-template">
+    <a href="#addChildSliver/slice/slice/23">Add another...</a>
 </script>
 
 <script type="text/template" id="xos-delete-button-template">
 
 <script type="text/template" id="xosAdmin-deployment-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 
 
 <script type="text/template" id="xosAdmin-image-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 <script type="text/template" id="xosAdmin-image-listitem-template">
 
 <script type="text/template" id="xosAdmin-networkTemplate-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 
 
 <script type="text/template" id="xosAdmin-network-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 <script type="text/template" id="xosAdmin-network-listitem-template">
 
 <script type="text/template" id="xosAdmin-networkSliver-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 <script type="text/template" id="xosAdmin-networkSliver-listitem-template">
 
 <script type="text/template" id="xosAdmin-networkDeployment-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 <script type="text/template" id="xosAdmin-networkDeployment-listitem-template">
 
 <script type="text/template" id="xosAdmin-node-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 
 
 <script type="text/template" id="xosAdmin-sliceRole-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 
 
 <script type="text/template" id="xosAdmin-service-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 
 
 <script type="text/template" id="xosAdmin-site-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 <script type="text/template" id="xosAdmin-site-listitem-template">
 
 <script type="text/template" id="xosAdmin-slice-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 <script type="text/template" id="xosAdmin-slice-listitem-template">
 
 <script type="text/template" id="xosAdmin-sliceDeployment-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 <script type="text/template" id="xosAdmin-sliceDeployment-listitem-template">
 
 <script type="text/template" id="xosAdmin-slicePrivilege-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 <script type="text/template" id="xosAdmin-slicePrivilege-listitem-template">
 
 <script type="text/template" id="xosAdmin-sliver-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 
 
 <script type="text/template" id="xosAdmin-user-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 
 
 <script type="text/template" id="xosAdmin-userDeployment-list-template">
   <h3 class="xos-list-title"><%= title %></h3>
-  <%= xosInlineListButtonsTemplate() %>
+  <%= xosListHeaderTemplate() %>
   <table class="test-table">
   <thead><tr>
      <th>id</th>
   </tr></thead>
   <tbody></tbody>
   </table>
+  <%= xosListFooterTemplate() %>
 </script>
 
 <script type="text/template" id="xosAdmin-userDeployment-listitem-template">
 
 <script>
 xosInlineDetailButtonsTemplate = _.template($("#xos-inline-detail-buttons-template").html());
-xosInlineListButtonsTemplate = _.template($("#xos-inline-list-buttons-template").html());
+xosListHeaderTemplate = _.template($("#xos-list-header-template").html());
+xosListFooterTemplate = _.template($("#xos-list-footer-template").html());
 xosDeleteButtonTemplate = _.template($("#xos-delete-button-template").html());
 xosDetailLinkTemplate = _.template($("#xos-detail-link-template").html());
 </script>