diff options
author | Étienne Loks <etienne.loks@peacefrogs.net> | 2011-01-14 15:29:11 +0100 |
---|---|---|
committer | Étienne Loks <etienne.loks@peacefrogs.net> | 2011-01-14 15:29:11 +0100 |
commit | d9b82554ab1f42691c992c2eac932b47e93e3ab7 (patch) | |
tree | cbd56374b4d7e2d77fc40f5796a0579154c16325 /ishtar/furnitures/forms.py | |
parent | 851e8b81898279079c14c4c0c3580699f9bb9998 (diff) | |
download | Ishtar-d9b82554ab1f42691c992c2eac932b47e93e3ab7.tar.bz2 Ishtar-d9b82554ab1f42691c992c2eac932b47e93e3ab7.zip |
Modification of operations (refs #16)
Diffstat (limited to 'ishtar/furnitures/forms.py')
-rw-r--r-- | ishtar/furnitures/forms.py | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/ishtar/furnitures/forms.py b/ishtar/furnitures/forms.py index 5bb1af6a9..c393bb3df 100644 --- a/ishtar/furnitures/forms.py +++ b/ishtar/furnitures/forms.py @@ -683,6 +683,14 @@ class OperationWizard(Wizard): data, files) return form +class OperationFormSelection(forms.Form): + form_label = _("Operation") + associated_models = {'pk':models.Operation} + currents = {'pk':models.Operation} + pk = forms.IntegerField(label=_("Operation"), + widget=widgets.JQueryAutoComplete(reverse_lazy('autocomplete-operation'), + associated_model=models.Operation), + validators=[models.valid_id(models.Operation)]) class OperationFormGeneral(forms.Form): @@ -797,5 +805,14 @@ operation_creation_wizard = OperationWizard([ ('refs-operation_creation', OperationFormReference), ('towns-operation_creation', SelectedTownFormSet), ('remains-operation_creation', RemainFormSet), - ('final-file_creation', FinalForm)], + ('final-operation_creation', FinalForm)], url_name='operation_creation',) + +operation_modification_wizard = OperationWizard([ + ('selec-operation_modification', OperationFormSelection), + ('general-operation_modification', OperationFormGeneral), + ('refs-operation_modification', OperationFormReference), + ('towns-operation_modification', SelectedTownFormSet), + ('remains-operation_modification', RemainFormSet), + ('final-operation_modification', FinalForm)], + url_name='operation_modification',) |