summaryrefslogtreecommitdiff
path: root/ishtar_common/wizards.py
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2019-09-14 09:03:56 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2019-09-14 09:03:56 +0200
commit89e94b9e2e18ce0f4a9572258b85e401463eb0ea (patch)
treebf7480e89c9d0dea0932faf346762e3db7e5b7f9 /ishtar_common/wizards.py
parent8627e7dc6cdd0ca96c42fb88c593e75302188fc4 (diff)
downloadIshtar-89e94b9e2e18ce0f4a9572258b85e401463eb0ea.tar.bz2
Ishtar-89e94b9e2e18ce0f4a9572258b85e401463eb0ea.zip
Context records: multiple deletion - redirections after wizard changes
Diffstat (limited to 'ishtar_common/wizards.py')
-rw-r--r--ishtar_common/wizards.py11
1 files changed, 9 insertions, 2 deletions
diff --git a/ishtar_common/wizards.py b/ishtar_common/wizards.py
index 9c89fd04b..0c13139df 100644
--- a/ishtar_common/wizards.py
+++ b/ishtar_common/wizards.py
@@ -1527,7 +1527,7 @@ class DeletionWizard(Wizard):
(hasattr(self, 'model') and hasattr(self.model, 'TABLE_COLS')):
self.fields = self.model.TABLE_COLS
assert self.model
- return super(DeletionWizard, self).__init__(*args, **kwargs)
+ super(DeletionWizard, self).__init__(*args, **kwargs)
def get_formated_datas(self, forms):
datas = super(DeletionWizard, self).get_formated_datas(forms)
@@ -1604,7 +1604,14 @@ class MultipleDeletionWizard(MultipleItemWizard):
(hasattr(self, 'model') and hasattr(self.model, 'TABLE_COLS')):
self.fields = self.model.TABLE_COLS
assert self.model
- return super(MultipleDeletionWizard, self).__init__(*args, **kwargs)
+ super(MultipleDeletionWizard, self).__init__(*args, **kwargs)
+
+ def get_template_names(self):
+ current_step = self.steps.current
+ if current_step.startswith("final-") and \
+ current_step not in self.wizard_templates:
+ return ["ishtar/wizard/delete_wizard.html"]
+ return super(MultipleDeletionWizard, self).get_template_names()
def get_formated_datas(self, forms):
datas = super(MultipleDeletionWizard, self).get_formated_datas(forms)