diff options
| author | Sbh (Openerp) <sbh@tinyerp.com> | 2012-06-18 15:42:05 +0530 |
|---|---|---|
| committer | Sbh (Openerp) <sbh@tinyerp.com> | 2012-06-18 15:42:05 +0530 |
| commit | e9c9f91b3c8e4e030b1d1b2cb34473b414698dc4 (patch) | |
| tree | 6719b2cd440e792893f921216f5203ce4dfc564a /addons/document | |
| parent | cc703765804a9dbed9c27397740e25356d2488a6 (diff) | |
| parent | ceb22841d6b79db8be8d29597f2d624de5759abf (diff) | |
[MERGE] Merge document changes
bzr revid: sbh@tinyerp.com-20120618101205-twulesbgj19vnpan
Diffstat (limited to 'addons/document')
| -rw-r--r-- | addons/document/document.py | 3 | ||||
| -rw-r--r-- | addons/document/document_data.xml | 6 |
2 files changed, 6 insertions, 3 deletions
diff --git a/addons/document/document.py b/addons/document/document.py index 92ece063a47..6cd47569f0f 100644 --- a/addons/document/document.py +++ b/addons/document/document.py @@ -140,8 +140,7 @@ class document_file(osv.osv): _defaults = { 'user_id': lambda self, cr, uid, ctx:uid, - 'file_size': lambda self, cr, uid, ctx:0, - 'parent_id': __get_def_directory + 'file_size': lambda self, cr, uid, ctx:0 } _sql_constraints = [ # filename_uniq is not possible in pure SQL diff --git a/addons/document/document_data.xml b/addons/document/document_data.xml index ac7a174b05f..c8a6e304d1a 100644 --- a/addons/document/document_data.xml +++ b/addons/document/document_data.xml @@ -104,6 +104,10 @@ <!-- After we have setup the root directory, migrate the attachments to point to that. --> <function model="ir.attachment" name="_attach_parent_id"/> - + <function + eval="('default',False,'parent_id', [('document.directory', False)], ref('document.dir_root'), True, False, False, False, True)" + id="document_default_set" + model="ir.values" + name="set"/> </data> </openerp> |
