Vo Minh Thu (OpenERP) has proposed merging
lp:~openerp-dev/openobject-server/trunk-deprecate-wizard-vmt into
lp:openobject-server.
Requested reviews:
OpenERP Core Team (openerp)
For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-server/trunk-deprecate-wizard-vmt/+merge/84093
--
https://code.launchpad.net/~openerp-dev/openobject-server/trunk-deprecate-wizard-vmt/+merge/84093
Your team OpenERP R&D Team is subscribed to branch
lp:~openerp-dev/openobject-server/trunk-deprecate-wizard-vmt.
=== modified file 'openerp/wizard/__init__.py'
--- openerp/wizard/__init__.py 2011-07-29 09:41:22 +0000
+++ openerp/wizard/__init__.py 2011-12-01 12:34:26 +0000
@@ -31,6 +31,7 @@
from openerp.osv.orm import except_orm
from openerp.netsvc import Logger, LOG_ERROR
import sys
+import warnings
class except_wizard(Exception):
def __init__(self, name, value):
@@ -39,10 +40,18 @@
self.args = (name, value)
class interface(netsvc.Service):
+ """
+ This is the base class used to implement Wizards. This class is deprecated
+ and `openerp.osv.TransientModel` must be used instead.
+ """
states = {}
def __init__(self, name):
assert not self.exists('wizard.'+name), 'The wizard "%s" already exists!' % (name,)
+ warnings.warn(
+ "The wizard %s uses the deprecated openerp.wizard.interface class.\n"
+ "It must use the openerp.osv.TransientModel class instead." % \
+ name, DeprecationWarning, stacklevel=3)
super(interface, self).__init__('wizard.'+name)
self.wiz_name = name
_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help : https://help.launchpad.net/ListHelp