From b5a797ba0af00cebcf26005bdcfda8151e39cb48 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Thu, 15 Dec 2011 11:40:31 +0100 Subject: [IMP] mark a bunch of dialog stuff as exportable (mostly buttons, but also dialog titles) bzr revid: xmo@openerp.com-20111215104031-h2xjkf0zwf8x8zjk --- addons/web_process/static/src/js/process.js | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'addons/web_process/static/src/js/process.js') diff --git a/addons/web_process/static/src/js/process.js b/addons/web_process/static/src/js/process.js index 9bf814aa4f4..e650530a914 100644 --- a/addons/web_process/static/src/js/process.js +++ b/addons/web_process/static/src/js/process.js @@ -1,5 +1,6 @@ openerp.web_process = function (openerp) { - var QWeb = openerp.web.qweb; + var QWeb = openerp.web.qweb, + _t = openerp.web._t; openerp.web.ViewManager.include({ start: function() { this._super(); @@ -275,19 +276,17 @@ openerp.web_process = function (openerp) { var dialog = new openerp.web.Dialog(this, { width: 800, height: 600, - buttons : { - Cancel : function() { - $(this).dialog('destroy'); - }, - Save : function() { + buttons : [ + {text: _t("Cancel"), click: function() { $(this).dialog('destroy'); }}, + {text: _t("Save"), click: function() { var form_view = action_manager.inner_viewmanager.views.form.controller; form_view.do_save(function() { self.initialize_process_view(); }); $(this).dialog('destroy'); - } - } + }} + ] }).start().open(); action_manager.appendTo(dialog.$element); -- cgit v1.2.3