Add show all vs. show diffs for upgrade packages
plus some related tweaks
This commit is contained in:
parent
24d89db025
commit
4b5e415147
4 changed files with 44 additions and 6 deletions
|
@ -72,7 +72,7 @@ ${h.csrf_token(request)}
|
|||
## % if form.creating and form.allow_successive_creates:
|
||||
## ${h.submit('create_and_continue', form.successive_create_label)}
|
||||
## % endif
|
||||
${h.link_to("Cancel", form.cancel_url, class_='button')}
|
||||
${h.link_to("Cancel", form.cancel_url, class_='button autodisable')}
|
||||
</div>
|
||||
% endif
|
||||
|
||||
|
|
|
@ -1,6 +1,41 @@
|
|||
## -*- coding: utf-8; -*-
|
||||
<%inherit file="/master/view.mako" />
|
||||
|
||||
<%def name="extra_javascript()">
|
||||
${parent.extra_javascript()}
|
||||
<script type="text/javascript">
|
||||
|
||||
function show_packages(type) {
|
||||
if (type == 'all') {
|
||||
$('.showing .diffs').css('font-weight', 'normal');
|
||||
$('table.diff tbody tr').show();
|
||||
$('.showing .all').css('font-weight', 'bold');
|
||||
} else if (type == 'diffs') {
|
||||
$('.showing .all').css('font-weight', 'normal');
|
||||
$('table.diff tbody tr:not(.diff)').hide();
|
||||
$('.showing .diffs').css('font-weight', 'bold');
|
||||
}
|
||||
}
|
||||
|
||||
$(function() {
|
||||
|
||||
show_packages('diffs');
|
||||
|
||||
$('.showing .all').click(function() {
|
||||
show_packages('all');
|
||||
return false;
|
||||
});
|
||||
|
||||
$('.showing .diffs').click(function() {
|
||||
show_packages('diffs')
|
||||
return false;
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
</script>
|
||||
</%def>
|
||||
|
||||
${parent.body()}
|
||||
|
||||
% if not instance.executed and request.has_perm('{}.execute'.format(permission_prefix)):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue