summaryrefslogtreecommitdiff
path: root/addons/document/document.py
diff options
context:
space:
mode:
authorSanjay Gohel (Open ERP) <sgo@tinyerp.com>2012-08-09 10:52:45 +0530
committerSanjay Gohel (Open ERP) <sgo@tinyerp.com>2012-08-09 10:52:45 +0530
commit374b834d9a689a1a9a19bc5fd1cc1e2ed7e04bca (patch)
tree830fddd3d30195eb8e9e31c7b4ff420ce545d7db /addons/document/document.py
parent0e77a7cbda6ea1e7500c42b84f741c5ecbd48a4e (diff)
parente970ecd62cb627a33832a561a082d211ab9923c7 (diff)
[MERGE]merge with trunk
bzr revid: sgo@tinyerp.com-20120809052245-638xhf0oyjtnhcak
Diffstat (limited to 'addons/document/document.py')
-rw-r--r--addons/document/document.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/addons/document/document.py b/addons/document/document.py
index fa65f8d9966..3ee52f8e4fb 100644
--- a/addons/document/document.py
+++ b/addons/document/document.py
@@ -23,7 +23,7 @@ import base64
from osv import osv, fields
import os
-# from psycopg2 import Binary
+#from psycopg2 import Binary
#from tools import config
import tools
from tools.translate import _
@@ -37,8 +37,8 @@ DMS_ROOT_PATH = tools.config.get('document_path', os.path.join(tools.config['roo
class document_file(osv.osv):
_inherit = 'ir.attachment'
_rec_name = 'datas_fname'
-
-
+
+
def _attach_parent_id(self, cr, uid, ids=None, context=None):
"""Migrate ir.attachments to the document module.
@@ -61,7 +61,7 @@ class document_file(osv.osv):
return False
if ids is not None:
- raise NotImplementedError("Ids is just there by convention! Don't use it yet, please.")
+ raise NotImplementedError("Ids are just there by convention, please do not use it.")
cr.execute("UPDATE ir_attachment " \
"SET parent_id = %s, db_datas = decode(encode(db_datas,'escape'), 'base64') " \
@@ -294,7 +294,7 @@ class document_file(osv.osv):
('datas_fname', '=', vals['datas_fname']),
]
attach_ids = self.search(cr, uid, domain, context=context)
- super(document_file, self).write(cr, uid, attach_ids,
+ super(document_file, self).write(cr, uid, attach_ids,
{'datas' : vals['datas']},
context=context)
result = attach_ids[0]
@@ -339,7 +339,7 @@ class document_file(osv.osv):
if r:
unres.append(r)
else:
- self.loggerdoc.warning("Unlinking attachment #%s %s that has no storage",
+ self.loggerdoc.warning("Unlinking attachment #%s %s that has no storage.",
f.id, f.name)
res = super(document_file, self).unlink(cr, uid, ids, context)
stor.do_unlink(cr, uid, unres)