diff options
Diffstat (limited to 'archaeological_operations/wizards.py')
| -rw-r--r-- | archaeological_operations/wizards.py | 13 | 
1 files changed, 9 insertions, 4 deletions
diff --git a/archaeological_operations/wizards.py b/archaeological_operations/wizards.py index 140a2a03a..d5230fa16 100644 --- a/archaeological_operations/wizards.py +++ b/archaeological_operations/wizards.py @@ -32,7 +32,7 @@ from .forms import GenerateDocForm  from ishtar_common.forms import reverse_lazy  from ishtar_common.models import get_current_profile  from ishtar_common.wizards import Wizard, ClosingWizard, DeletionWizard, \ -    SearchWizard +    SearchWizard, MultipleDeletionWizard  logger = logging.getLogger(__name__) @@ -52,6 +52,7 @@ class OperationWizard(Wizard):      multi_towns = False  # true if current town are multi valued      towns_formset = True  # true if towns are managed with formset      wizard_done_window = reverse_lazy('show-operation') +    redirect_url = "operation_modification"      def get_template_names(self):          templates = super(OperationWizard, self).get_template_names() @@ -297,10 +298,11 @@ class OperationClosingWizard(ClosingWizard):                'comment', 'towns', 'remains'] -class OperationDeletionWizard(DeletionWizard): +class OperationDeletionWizard(MultipleDeletionWizard):      model = models.Operation      fields = OperationClosingWizard.fields -    filter_owns = {'selec-operation_deletion': ['pk']} +    filter_owns = {'selec-operation_deletion': ['pks']} +    redirect_url = "operation_deletion"  class OperationAdministrativeActWizard(OperationWizard): @@ -308,6 +310,7 @@ class OperationAdministrativeActWizard(OperationWizard):      wizard_done_window = reverse_lazy('show-administrativeact')      current_obj_slug = 'administrativeactop'      ref_object_key = 'operation' +    redirect_url = "operation_administrativeactop_modification"      def get_reminder(self):          form_key = 'selec-' + self.url_name @@ -435,6 +438,7 @@ class SiteWizard(SiteLabel, Wizard):      SITE_KEY = 'new'      model = models.ArchaeologicalSite      wizard_done_window = reverse_lazy('show-site') +    redirect_url = "site_modification"  class SiteModificationWizard(SiteWizard): @@ -442,10 +446,11 @@ class SiteModificationWizard(SiteWizard):      modification = True -class SiteDeletionWizard(SiteLabel, DeletionWizard): +class SiteDeletionWizard(SiteLabel, MultipleDeletionWizard):      SITE_KEY = 'deletion'      model = models.ArchaeologicalSite      fields = models.ArchaeologicalSite.TABLE_COLS + ['operations'] +    redirect_url = "site_deletion"  class AdministrativeActDeletionWizard(ClosingWizard):  | 
