Please set the Model to Create before choosing values
If several child actions return an action, only the last one will be executed. This may happen when having server actions executing code that returns an action, or server actions returning a client action.
Various fields may use Python code or Python expressions. The following variables can be used:
env
: Odoo Environment on which the action is triggeredmodel
: Odoo Model of the record on which the action is triggered; is a void recordsetrecord
: record on which the action is triggered; may be be voidrecords
: recordset of all records on which the action is triggered in multi mode; may be voidtime
, datetime
, dateutil
, timezone
: useful Python librarieslog(message, level='info')
: logging function to record debug information in ir.logging
tableUserError
: Warning Exception to use with raise
Command
: x2Many commands namespaceaction = {...}
Example of Python code
partner_name = record.name + '_code' \n
env['res.partner'].create({'name': partner_name})