diff options
| author | Vidhin Mehta <vme@tinyerp.com> | 2013-01-28 15:10:49 +0530 |
|---|---|---|
| committer | Vidhin Mehta <vme@tinyerp.com> | 2013-01-28 15:10:49 +0530 |
| commit | b45cea4ab860743d21c1ff9991c2f881bc841608 (patch) | |
| tree | 972f7fe2b131995481b68d775b9a52a32301f7ad /addons/google_docs/google_docs.py | |
| parent | ef72f482fbeaa1998a5d857d1081d21b9e759ddd (diff) | |
| parent | b390a5697cd4eb8cced5f4cdcf2c34b6cad3a7e4 (diff) | |
[MERGE]Trunk.
bzr revid: vme@tinyerp.com-20130128094049-oddx6ks274hrfq4c
Diffstat (limited to 'addons/google_docs/google_docs.py')
| -rw-r--r-- | addons/google_docs/google_docs.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/addons/google_docs/google_docs.py b/addons/google_docs/google_docs.py index 1f6af0378ca..4b98798c832 100644 --- a/addons/google_docs/google_docs.py +++ b/addons/google_docs/google_docs.py @@ -20,9 +20,9 @@ import logging from datetime import datetime -from tools import DEFAULT_SERVER_DATETIME_FORMAT -from osv import osv, fields -from tools.translate import _ +from openerp.tools import DEFAULT_SERVER_DATETIME_FORMAT +from openerp.osv import fields, osv +from openerp.tools.translate import _ _logger = logging.getLogger(__name__) @@ -94,9 +94,9 @@ class google_docs_ir_attachment(osv.osv): client = self._auth(cr, uid) # fetch and copy the original document try: - original_resource = client.get_resource_by_id(gdoc_template_id) + doc = client.GetDoc(gdoc_template_id) #copy the document you choose in the configuration - copy_resource = client.copy_resource(original_resource, name_gdocs) + copy_resource = client.copy(doc, name_gdocs) except: raise osv.except_osv(_('Google Docs Error!'), _("Your resource id is not correct. You can find the id in the google docs URL.")) # create an ir.attachment |
