From 4d8c616b76edfe3bd8862b588e825d1e29d40950 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Sun, 2 Mar 2014 19:12:07 +0100 Subject: Specific form for research archaeology (refs #1682) --- archaeological_operations/wizards.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'archaeological_operations/wizards.py') diff --git a/archaeological_operations/wizards.py b/archaeological_operations/wizards.py index a14924301..cacc44da1 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-2013 Étienne Loks +# Copyright (C) 2012-2014 É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 @@ -372,6 +372,11 @@ def is_preventive(form_name, model, type_key='operation_type', key=''): return False return func +def is_not_preventive(form_name, model, type_key='operation_type', key=''): + def func(self): + return not is_preventive(form_name, model, type_key, key)(self) + return func + def has_associated_file(form_name, file_key='associated_file', negate=False): def func(self): request = self.request -- cgit v1.2.3