diff options
| author | Raphael Collet <rco@openerp.com> | 2014-07-06 16:44:26 +0200 |
|---|---|---|
| committer | Antony Lesuisse <al@openerp.com> | 2014-07-06 17:05:41 +0200 |
| commit | cbe2dbb672a6c55d86f2e515f9d1cdfee426ef80 (patch) | |
| tree | d6ff62b719fce32392397783c961b734b1e4c50e /addons/subscription/subscription.py | |
| parent | d78192c489d3be66cd6487b39f5ce7ba4733a187 (diff) | |
[MERGE] new v8 api by rco
A squashed merge is required as the conversion of the apiculture branch from
bzr to git was not correctly done. The git history contains irrelevant blobs
and commits. This branch brings a lot of changes and fixes, too many to list
exhaustively.
- New orm api, objects are now used instead of ids
- Environements to encapsulates cr uid context while maintaining backward compatibility
- Field compute attribute is a new object oriented way to define function fields
- Shared browse record cache
- New onchange protocol
- Optional copy flag on fields
- Documentation update
- Dead code cleanup
- Lots of fixes
Diffstat (limited to 'addons/subscription/subscription.py')
| -rw-r--r-- | addons/subscription/subscription.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/subscription/subscription.py b/addons/subscription/subscription.py index 779619d011f..cc40c468cb0 100644 --- a/addons/subscription/subscription.py +++ b/addons/subscription/subscription.py @@ -33,7 +33,7 @@ class subscription_document(osv.osv): 'name': fields.char('Name', required=True), 'active': fields.boolean('Active', help="If the active field is set to False, it will allow you to hide the subscription document without removing it."), 'model': fields.many2one('ir.model', 'Object', required=True), - 'field_ids': fields.one2many('subscription.document.fields', 'document_id', 'Fields') + 'field_ids': fields.one2many('subscription.document.fields', 'document_id', 'Fields', copy=True) } _defaults = { 'active' : lambda *a: True, @@ -67,7 +67,7 @@ class subscription_subscription(osv.osv): 'interval_type': fields.selection([('days', 'Days'), ('weeks', 'Weeks'), ('months', 'Months')], 'Interval Unit'), 'exec_init': fields.integer('Number of documents'), 'date_init': fields.datetime('First Date'), - 'state': fields.selection([('draft','Draft'),('running','Running'),('done','Done')], 'Status'), + 'state': fields.selection([('draft','Draft'),('running','Running'),('done','Done')], 'Status', copy=False), 'doc_source': fields.reference('Source Document', required=True, selection=_get_document_types, size=128, help="User can choose the source document on which he wants to create documents"), 'doc_lines': fields.one2many('subscription.subscription.history', 'subscription_id', 'Documents created', readonly=True), 'cron_id': fields.many2one('ir.cron', 'Cron Job', help="Scheduler which runs on subscription", states={'running':[('readonly',True)], 'done':[('readonly',True)]}), |
