From b8ecbe3191f86cd28272c2aa0f3900c527a060dd Mon Sep 17 00:00:00 2001 From: Denis Michiels Date: Fri, 20 Feb 2015 16:08:10 +0100 Subject: [PATCH] [FIX] google_drive : translate the record Pass the context, with the language setting, when the record is read to fill the google drive template. That allows to translate the name of the document and all the informations inside. opw-626675 --- addons/google_drive/static/src/js/gdrive.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/google_drive/static/src/js/gdrive.js b/addons/google_drive/static/src/js/gdrive.js index dbbe50d0794..6b5e1f83bf9 100644 --- a/addons/google_drive/static/src/js/gdrive.js +++ b/addons/google_drive/static/src/js/gdrive.js @@ -64,7 +64,7 @@ openerp.google_drive = function (instance, m) { var loaded = self.fetch('google.drive.config', ['google_drive_resource_id', 'google_drive_client_id'], [['id', '=', doc_item.config_id]]) .then(function (configs) { var ds = new instance.web.DataSet(self, 'google.drive.config'); - ds.call('get_google_drive_url', [doc_item.config_id, doc_item.res_id,configs[0].google_drive_resource_id]).done(function (url) { + ds.call('get_google_drive_url', [doc_item.config_id, doc_item.res_id,configs[0].google_drive_resource_id, self.dataset.context]).done(function (url) { if (url){ window.open(url, '_blank'); }