# HG changeset patch # User Sylvain Thénault # Date 1274878745 -7200 # Node ID 41ad8ca3047eeebe923de83fe733d691aaf2ad98 # Parent 25bf54dab82b6896ed9a7dcfeb36ac7e7da27d71 [form] fix bw compat issue introduced by 5588:377c9adfe81e diff -r 25bf54dab82b -r 41ad8ca3047e web/views/autoform.py --- a/web/views/autoform.py Wed May 26 12:31:45 2010 +0200 +++ b/web/views/autoform.py Wed May 26 14:59:05 2010 +0200 @@ -125,6 +125,7 @@ from logilab.mtconverter import xml_escape from logilab.common.decorators import iclassmethod, cached +from logilab.common.deprecation import deprecated from cubicweb import typed_eid, neg_role, uilib from cubicweb.schema import display_name @@ -646,6 +647,18 @@ # action on the form tag _default_form_action_path = 'validateform' + # pre 3.8.3 compat + @property + def set_action(self, action): + self._action = action + @deprecated('[3.9] use form.form_action()') + def get_action(self): + try: + return self._action + except AttributeError: + return self._cw.build_url(self._default_form_action_path) + action = property(get_action, set_action) + @iclassmethod def field_by_name(cls_or_self, name, role=None, eschema=None): """return field with the given name and role. If field is not explicitly