Add progress for generating "results as XLSX" file to download
This commit is contained in:
parent
32b98ae818
commit
7d8c57170f
3 changed files with 126 additions and 25 deletions
tailbone/templates/master
|
@ -295,6 +295,13 @@
|
|||
${parent.modify_this_page_vars()}
|
||||
<script type="text/javascript">
|
||||
|
||||
## TODO: stop checking for buefy here once we only have the one session.pop()
|
||||
% if use_buefy and request.session.pop('{}.results_xlsx.generated'.format(route_prefix), False):
|
||||
ThisPage.mounted = function() {
|
||||
location.href = '${url('{}.results_xlsx_download'.format(route_prefix))}';
|
||||
}
|
||||
% endif
|
||||
|
||||
## delete single object
|
||||
% if master.deletable and master.has_perm('delete') and master.delete_confirm == 'simple':
|
||||
ThisPage.methods.deleteObject = function(url) {
|
||||
|
@ -453,4 +460,14 @@
|
|||
${h.csrf_token(request)}
|
||||
${h.end_form()}
|
||||
% endif
|
||||
|
||||
## TODO: can stop checking for buefy above once this legacy chunk is gone
|
||||
% if request.session.pop('{}.results_xlsx.generated'.format(route_prefix), False):
|
||||
<script type="text/javascript">
|
||||
$(function() {
|
||||
location.href = '${url('{}.results_xlsx_download'.format(route_prefix))}';
|
||||
});
|
||||
</script>
|
||||
% endif
|
||||
|
||||
% endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue