From 5bf95742ca71634f035969bdee552e2525837d00 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Tue, 3 Sep 2013 01:26:53 +0200 Subject: Add a widget to do free input parcel additions (refs #809) --- archaeological_operations/wizards.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'archaeological_operations/wizards.py') diff --git a/archaeological_operations/wizards.py b/archaeological_operations/wizards.py index d24b380dd..91f4be3d4 100644 --- a/archaeological_operations/wizards.py +++ b/archaeological_operations/wizards.py @@ -1,6 +1,6 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- -# Copyright (C) 2012 Étienne Loks +# Copyright (C) 2012-2013 Étienne Loks # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as @@ -138,6 +138,8 @@ class OperationWizard(Wizard): def get_form_initial(self, step, data=None): initial = super(OperationWizard, self).get_form_initial(step) + return initial + ''' self.form_initialized = False if not step.startswith(self.parcel_step_key): return initial @@ -147,7 +149,7 @@ class OperationWizard(Wizard): default.pop('parcel_number') initial.append(default) # necessary to get the appropriate form number - self.form_initialized = True + #self.form_initialized = True elif data: numbers, keys = set(), set() for k in data: @@ -160,8 +162,8 @@ class OperationWizard(Wizard): if numbers and max(numbers) - 1 > 0: initial = [dict([(k, data[step+'-'+unicode(max(numbers)-1)+'-'+k]) for k in keys if k != 'parcel_number'])] - self.form_initialized = True - return initial + #self.form_initialized = True + return initial''' class OperationModificationWizard(OperationWizard): modification = True -- cgit v1.2.3