diff options
| -rw-r--r-- | archaeological_operations/views.py | 8 | ||||
| -rw-r--r-- | archaeological_operations/wizards.py | 4 | 
2 files changed, 6 insertions, 6 deletions
| diff --git a/archaeological_operations/views.py b/archaeological_operations/views.py index 0ed9cb9c7..5d5038758 100644 --- a/archaeological_operations/views.py +++ b/archaeological_operations/views.py @@ -192,13 +192,13 @@ operation_creation_wizard = OperationWizard.as_view([              is_preventive('general-operation_creation', models.OperationType,              'operation_type', 'arch_diagnostic'),          'townsgeneral-operation_creation':has_associated_file( -            'general-operation_creation', negate=True), +            'filechoice-operation_creation', negate=True),          'towns-operation_creation':has_associated_file( -            'general-operation_creation'), +            'filechoice-operation_creation'),          'parcelsgeneral-operation_creation':has_associated_file( -            'general-operation_creation', negate=True), +            'filechoice-operation_creation', negate=True),          'parcels-operation_creation':has_associated_file( -            'general-operation_creation'), +            'filechoice-operation_creation'),      },      url_name='operation_creation',) diff --git a/archaeological_operations/wizards.py b/archaeological_operations/wizards.py index 821d5eedc..eb6788ac4 100644 --- a/archaeological_operations/wizards.py +++ b/archaeological_operations/wizards.py @@ -74,7 +74,7 @@ class OperationWizard(Wizard):          context = super(OperationWizard, self).get_context_data(form,                                                                  **kwargs)          step = self.steps.current -        if step.startswith('towns-'): +        if step.startswith('towns'):              context['TOWNS'] = self.get_towns()          elif step.startswith('parcels-') and self.get_current_file():              # if a file is acciated to the operation add the button "Add all" @@ -135,7 +135,7 @@ class OperationWizard(Wizard):          if self.url_name == 'operation_creation':              file_form_key = 'filechoice-' + self.url_name          # manage the dynamic choice of towns -        if step.startswith('towns-') and hasattr(form, 'management_form'): +        if step.startswith('towns') and hasattr(form, 'management_form'):              data['TOWNS'] = self.get_towns()          elif step.startswith('parcels') and hasattr(form, 'management_form'):              file_id = self.session_get_value(file_form_key, "associated_file") | 
