Add "grid tools" to "complete" grid template.

We'll see about this...
This commit is contained in:
Lance Edgar 2016-01-08 10:50:14 -06:00
parent 640bb736b2
commit 654c69772e
2 changed files with 15 additions and 1 deletions

View file

@ -17,6 +17,13 @@
$('.newgrid-wrapper').gridwrapper(); $('.newgrid-wrapper').gridwrapper();
}); });
</script> </script>
<style type="text/css">
.grid-tools {
float: right;
position: relative;
top: -36px;
}
</style>
</%def> </%def>
<%def name="context_menu_items()"> <%def name="context_menu_items()">
@ -25,8 +32,10 @@
% endif % endif
</%def> </%def>
<%def name="grid_tools()"></%def>
<ul id="context-menu"> <ul id="context-menu">
${self.context_menu_items()} ${self.context_menu_items()}
</ul> </ul>
${grid.render_complete()|n} ${grid.render_complete(tools=capture(self.grid_tools))|n}

View file

@ -3,5 +3,10 @@
% if grid.filterable: % if grid.filterable:
${grid.render_filters()|n} ${grid.render_filters()|n}
% endif % endif
% if tools:
<div class="grid-tools">
${tools|n}
</div>
% endif
${grid.render_grid()|n} ${grid.render_grid()|n}
</div><!-- newgrid-wrapper --> </div><!-- newgrid-wrapper -->