diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2018-03-08 13:59:18 +0100 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2018-03-08 13:59:18 +0100 |
commit | d2e6cbefcf35aba6020cc6e8a6d187de4d19bfb5 (patch) | |
tree | 47e1e5cfd6d8ab998c81185b49bd8f0ac1d787ac /ishtar_common/views.py | |
parent | 89c07c34691b71f5cf572134244fd7e272631013 (diff) | |
download | Ishtar-d2e6cbefcf35aba6020cc6e8a6d187de4d19bfb5.tar.bz2 Ishtar-d2e6cbefcf35aba6020cc6e8a6d187de4d19bfb5.zip |
Autorefresh button not available when background task is not available (refs #3951)
Diffstat (limited to 'ishtar_common/views.py')
-rw-r--r-- | ishtar_common/views.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ishtar_common/views.py b/ishtar_common/views.py index c2b292ed4..8b0d51601 100644 --- a/ishtar_common/views.py +++ b/ishtar_common/views.py @@ -1823,6 +1823,11 @@ class ImportListView(IshtarMixin, LoginRequiredMixin, ListView): imprt.archive() return HttpResponseRedirect(reverse(self.current_url)) + def get_context_data(self, **kwargs): + dct = super(ImportListView, self).get_context_data(**kwargs) + dct['autorefresh_available'] = settings.USE_BACKGROUND_TASK + return dct + class ImportListTableView(ImportListView): template_name = 'ishtar/import_table.html' |