[REM] core: remove @api.multi
kw_multi is the default API, so the decorator is no longer necessary and hasn't been for a long time
This commit is contained in:
+1
-19
@@ -34,7 +34,7 @@
|
||||
__all__ = [
|
||||
'Environment',
|
||||
'Meta',
|
||||
'model', 'multi',
|
||||
'model',
|
||||
'constrains', 'depends', 'onchange', 'returns',
|
||||
'call_kw',
|
||||
]
|
||||
@@ -289,24 +289,6 @@ def model(method):
|
||||
return method
|
||||
|
||||
|
||||
def multi(method):
|
||||
""" Decorate a record-style method where ``self`` is a recordset. The method
|
||||
typically defines an operation on records. Such a method::
|
||||
|
||||
def method(self, args):
|
||||
...
|
||||
|
||||
may be called in both record and traditional styles, like::
|
||||
|
||||
# recs = model.browse(cr, uid, ids, context)
|
||||
recs.method(args)
|
||||
|
||||
model.method(cr, uid, ids, args, context=context)
|
||||
"""
|
||||
method._api = 'multi'
|
||||
return method
|
||||
|
||||
|
||||
_create_logger = logging.getLogger(__name__ + '.create')
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user