Use once-button for tempmon client restart

This commit is contained in:
Lance Edgar 2019-06-15 17:31:49 -05:00
parent f684c38958
commit 63807e71fd

View file

@ -3,6 +3,7 @@
<%def name="extra_javascript()">
${parent.extra_javascript()}
% if not use_buefy:
<script type="text/javascript">
$(function() {
$('#restart-client').click(function() {
@ -11,6 +12,7 @@
});
});
</script>
% endif
</%def>
<%def name="object_helpers()">
@ -18,7 +20,14 @@
<div class="object-helper">
<h3>Client Tools</h3>
<div class="object-helper-content">
% if use_buefy:
<once-button tag="a" href="${url('{}.restart'.format(route_prefix), uuid=instance.uuid)}"
type="is-primary"
text="Restart tempmon-client daemon">
</once-button>
% else:
<button type="button" id="restart-client">Restart tempmon-client daemon</button>
% endif
</div>
</div>
% endif