From 3c31ab4438f7642b1639cefa4107cda06c6644d6 Mon Sep 17 00:00:00 2001 From: Holger Brunn Date: Tue, 17 Mar 2015 13:16:07 +0100 Subject: [PATCH 01/27] [ADD] web_ir_actions_act_window_message --- web_ir_actions_act_window_message/README.rst | 50 ++++++++++++++++++ web_ir_actions_act_window_message/__init__.py | 20 +++++++ .../__openerp__.py | 43 +++++++++++++++ .../static/description/icon.png | Bin 0 -> 2034 bytes .../js/web_ir_actions_act_window_message.js | 50 ++++++++++++++++++ .../xml/web_ir_actions_act_window_message.xml | 5 ++ .../views/templates.xml | 10 ++++ 7 files changed, 178 insertions(+) create mode 100644 web_ir_actions_act_window_message/README.rst create mode 100644 web_ir_actions_act_window_message/__init__.py create mode 100644 web_ir_actions_act_window_message/__openerp__.py create mode 100644 web_ir_actions_act_window_message/static/description/icon.png create mode 100644 web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js create mode 100644 web_ir_actions_act_window_message/static/src/xml/web_ir_actions_act_window_message.xml create mode 100644 web_ir_actions_act_window_message/views/templates.xml diff --git a/web_ir_actions_act_window_message/README.rst b/web_ir_actions_act_window_message/README.rst new file mode 100644 index 000000000..58cf35af9 --- /dev/null +++ b/web_ir_actions_act_window_message/README.rst @@ -0,0 +1,50 @@ +Client side message boxes +========================= + +This module allows to show a message popup on the client side as result of a button. + +Usage +===== + +Depend on this module and return + +.. code:: python + + { + 'type': 'ir.actions.act_window.message', + 'title': 'My title', + 'message': 'My message' + } + +You are responsible for translating the messages. + +* https://www.odoo.com/forum/help-1 + +Known issues / Roadmap +====================== + +* add `message_type` to differenciate between warnings, errors, etc. +* have one `message_type` to show a nonmodal warning on top right +* have `button_title` to set the button title +* have `buttons` containing button names and action definitions for triggering actions from the message box + +Credits +======= + +Contributors +------------ + +* Holger Brunn + +Maintainer +---------- + +.. image:: http://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: http://odoo-community.org + +This module is maintained by the OCA. + +OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use. + +To contribute to this module, please visit http://odoo-community.org. diff --git a/web_ir_actions_act_window_message/__init__.py b/web_ir_actions_act_window_message/__init__.py new file mode 100644 index 000000000..faef9dac0 --- /dev/null +++ b/web_ir_actions_act_window_message/__init__.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# This module copyright (C) 2015 Therp BV . +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## diff --git a/web_ir_actions_act_window_message/__openerp__.py b/web_ir_actions_act_window_message/__openerp__.py new file mode 100644 index 000000000..98f67900f --- /dev/null +++ b/web_ir_actions_act_window_message/__openerp__.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# This module copyright (C) 2015 Therp BV . +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## +{ + "name": "Client side message boxes", + "version": "1.0", + "author": "Therp BV", + "license": "AGPL-3", + "category": "Hidden/Dependency", + "summary": "Show a warning to users", + "depends": [ + 'web', + ], + "data": [ + 'views/templates.xml', + ], + "qweb": [ + 'static/src/xml/web_ir_actions_act_window_message.xml', + ], + "auto_install": False, + "installable": True, + "application": False, + "external_dependencies": { + 'python': [], + }, +} diff --git a/web_ir_actions_act_window_message/static/description/icon.png b/web_ir_actions_act_window_message/static/description/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..98965872769fff2e0a8aee1203260fcb8820eee6 GIT binary patch literal 2034 zcmVe zSad^gZEa<4bO1wgWnpw>WFU8GbZ8()Nlj2!fese{00&x0L_t(|+U=WNOjB7Nz<;;B zEtI0TfK)(b(L`vKEGk6|8kI!N#P~7~#+eLHhKGI7#E;C&JZ!R08;QO-iI0LWeniDY zvl_q=i7^A3!9|n`5eOeCTd*y(x3~9e9}pPlL)3AVspps6^!D`RHu>e8^Z%d!X+azxH7w zk>KRXlLUi7%FD~CtE*$hiWS)Hb{ZQSaXOtWUAmNph6eij`Y0?cXd85tSj&Ye5-^zty@{PY}uj`7z%~(csw{94nm<2>FMd%?e_N*D9bXX zrKJ=U6p)vfM@dNuH*b=enaT9@G`+pO?A*DN^z?MPySv%8Z5w{SpUKHd z^78VCMx#iQL}OzkE|-hy>S~6EhtYMN#kPH1zI-{7Bw<+=d3kvYjzkGyXlUr~d3kx? z|K5E65Oj2O@bu|ZDk>`Q`Fwx+U=xi-i9{kBO9s$1jd(ncrfI^=TcRimx~|U%bT}Mu-1iB7jbRw5sw&n%5k!PQAy5bu2!V@J zU_2h@+O=yaih^ZXoH=s_VD6m2vaGp#(=@RxYp(70?q|7v{rX({Z#@Sf7z{EnFz{OY z?CaRr7=wd@pIo54P_`Y7MhS<*JbCg2kHTN|C7o$TJdn-?!$5DW&XtE;2FzMiV8 zDhdk=xqbUKUayx(B!bK3VtRTS!!Q^g9_HAwV*pG{OmOw;Rf>v=n4FwsU|@jS+FCAO zzD#LpDHRnJOifME)z!tzmoI5;ZDsrR?MzNiVwxr{my1v+#LAT`-&isJq$AL>EQ*VZ zX=`gEnM{(ClY^?N)YR0VC<;EGZ?2-eWy=;aGc%c(n4qGfV(wg_qN0L$JkF|Bt605y z_1v@Vb~}6b?xnZ4mv!sb;dDB2I-RJhipS#tAT2G8%F0ScMn>4NV+U@x8;{3BAP}Im zw3N-8H-A!j3ksBFnWCa1{C+=s_Uxgcpny%AHZeFjNLg7Ki9~{>OP9{cb~>GG*sy`o z(NWf{SwnGgF@ZpU{QP{}Zue^f%gV}VX=&lWfdh<>k5gV=K6g$Mi^TvaEG%SjaFAWQ zb`cB)$<58hZnslgTZ^J7jE#+b^6lsUwWQzL+RDht2>bT!BRe}grGm#tDe2eL)QB`j zAOs45Lg42hP?YrFF@5=ENk0~gkxV9qnYTny6f{knFX_A8Zp42?-X6=cNG6l>Q}}Iv z&Lx=lWm%R8A|eV4fq!n^xEHoelV@#h^#Ak|*gl-=bf=T*ufD>Sm6h58|0 z0M#%^7zVSa8J4DzwRJ0h*|m%Kvu7YlOx(DEJ~f3T%OFWunug?XfMsFnI=1xm*Ovgp zz(|p_>CI~(kkm9(O`98mW->|E?%njCJ`JWx{?}ilIUKC1uP4&ki5?D<`^6W8Zrvhn z`Er(Q-poLKJ?hvP(yTJ{FsAk4ES3XV+1~U`a+s>I-ydXS3t;(IOG}GwGDY^LAB+C}ep*^uY%;*b zix>YL4u@O!@86%Fk&z+F`wI{Xh2-}3_J18Ya^ye4hCm. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as +// published by the Free Software Foundation, either version 3 of the +// License, or (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with this program. If not, see . +// +//############################################################################ + +openerp.web_ir_actions_act_window_message = function(instance) +{ + instance.web.ActionManager.include({ + ir_actions_act_window_message: function(action, options) + { + var dialog = new instance.web.Dialog( + this, + { + size: 'medium', + title: action.title, + buttons: [ + { + text: instance.web._t('Close'), + click: function() { dialog.close() }, + oe_link_class: 'oe_highlight', + }, + ], + }, + jQuery(instance.web.qweb.render( + 'web_ir_actions_act_window_message', + { + 'this': this, + 'action': action, + })) + ) + return dialog.open(); + }, + }); +} diff --git a/web_ir_actions_act_window_message/static/src/xml/web_ir_actions_act_window_message.xml b/web_ir_actions_act_window_message/static/src/xml/web_ir_actions_act_window_message.xml new file mode 100644 index 000000000..5f0742294 --- /dev/null +++ b/web_ir_actions_act_window_message/static/src/xml/web_ir_actions_act_window_message.xml @@ -0,0 +1,5 @@ + +
+
+
+
diff --git a/web_ir_actions_act_window_message/views/templates.xml b/web_ir_actions_act_window_message/views/templates.xml new file mode 100644 index 000000000..9ba42b0b2 --- /dev/null +++ b/web_ir_actions_act_window_message/views/templates.xml @@ -0,0 +1,10 @@ + + + + + + From 318266aee176f2c01348bece739e3ff757bc3de9 Mon Sep 17 00:00:00 2001 From: Holger Brunn Date: Wed, 18 Mar 2015 10:26:00 +0100 Subject: [PATCH 02/27] [IMP] better readme, manifest --- web_ir_actions_act_window_message/README.rst | 6 ++---- web_ir_actions_act_window_message/__openerp__.py | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/web_ir_actions_act_window_message/README.rst b/web_ir_actions_act_window_message/README.rst index 58cf35af9..c68947125 100644 --- a/web_ir_actions_act_window_message/README.rst +++ b/web_ir_actions_act_window_message/README.rst @@ -12,14 +12,12 @@ Depend on this module and return { 'type': 'ir.actions.act_window.message', - 'title': 'My title', - 'message': 'My message' + 'title': _('My title'), + 'message': _('My message'), } You are responsible for translating the messages. -* https://www.odoo.com/forum/help-1 - Known issues / Roadmap ====================== diff --git a/web_ir_actions_act_window_message/__openerp__.py b/web_ir_actions_act_window_message/__openerp__.py index 98f67900f..7cd5baaed 100644 --- a/web_ir_actions_act_window_message/__openerp__.py +++ b/web_ir_actions_act_window_message/__openerp__.py @@ -24,7 +24,7 @@ "author": "Therp BV", "license": "AGPL-3", "category": "Hidden/Dependency", - "summary": "Show a warning to users", + "summary": "Show a message box to users", "depends": [ 'web', ], From b50f6a9397f8fa9d732ccb0b7f574e69d36392bc Mon Sep 17 00:00:00 2001 From: Yannick Vaucher Date: Fri, 22 May 2015 19:45:36 +0200 Subject: [PATCH 03/27] Add bug tracker link on README.rst --- web_ir_actions_act_window_message/README.rst | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/web_ir_actions_act_window_message/README.rst b/web_ir_actions_act_window_message/README.rst index c68947125..f330f0bfd 100644 --- a/web_ir_actions_act_window_message/README.rst +++ b/web_ir_actions_act_window_message/README.rst @@ -26,6 +26,16 @@ Known issues / Roadmap * have `button_title` to set the button title * have `buttons` containing button names and action definitions for triggering actions from the message box + +Bug Tracker +=========== + +Bugs are tracked on `GitHub Issues `_. +In case of trouble, please check there if your issue has already been reported. +If you spotted it first, help us smashing it by providing a detailed and welcomed feedback +`here `_. + + Credits ======= From 850b7f081b5058dfc090b31953e639a643c1db0b Mon Sep 17 00:00:00 2001 From: Markus Schneider Date: Thu, 4 Jun 2015 14:30:25 +0200 Subject: [PATCH 04/27] add OCA to author --- web_ir_actions_act_window_message/__openerp__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/web_ir_actions_act_window_message/__openerp__.py b/web_ir_actions_act_window_message/__openerp__.py index 7cd5baaed..1cc57df0d 100644 --- a/web_ir_actions_act_window_message/__openerp__.py +++ b/web_ir_actions_act_window_message/__openerp__.py @@ -21,7 +21,8 @@ { "name": "Client side message boxes", "version": "1.0", - "author": "Therp BV", + "author": "Therp BV, " + "Odoo Community Association (OCA)", "license": "AGPL-3", "category": "Hidden/Dependency", "summary": "Show a message box to users", From a102481ada9e0368f0798558e81475d099c6bc12 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Bidoul?= Date: Fri, 9 Oct 2015 10:03:39 +0200 Subject: [PATCH 05/27] [UPD] prefix versions with 8.0 --- web_ir_actions_act_window_message/__openerp__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web_ir_actions_act_window_message/__openerp__.py b/web_ir_actions_act_window_message/__openerp__.py index 1cc57df0d..293f9f4de 100644 --- a/web_ir_actions_act_window_message/__openerp__.py +++ b/web_ir_actions_act_window_message/__openerp__.py @@ -20,7 +20,7 @@ ############################################################################## { "name": "Client side message boxes", - "version": "1.0", + "version": "8.0.1.0.0", "author": "Therp BV, " "Odoo Community Association (OCA)", "license": "AGPL-3", From 30c5e41db54ff90e2a7d4dc1849bf834bd9e859d Mon Sep 17 00:00:00 2001 From: "Pedro M. Baeza" Date: Wed, 14 Oct 2015 02:57:05 +0200 Subject: [PATCH 06/27] [MIG] Make modules uninstallable --- web_ir_actions_act_window_message/__openerp__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web_ir_actions_act_window_message/__openerp__.py b/web_ir_actions_act_window_message/__openerp__.py index 293f9f4de..7a553c520 100644 --- a/web_ir_actions_act_window_message/__openerp__.py +++ b/web_ir_actions_act_window_message/__openerp__.py @@ -36,7 +36,7 @@ 'static/src/xml/web_ir_actions_act_window_message.xml', ], "auto_install": False, - "installable": True, + 'installable': False, "application": False, "external_dependencies": { 'python': [], From 7803c5c12155b17355ad62f575acb1cdf979e34f Mon Sep 17 00:00:00 2001 From: "Pedro M. Baeza" Date: Thu, 6 Oct 2016 16:13:01 +0200 Subject: [PATCH 07/27] [MIG] Rename manifest files --- .../{__openerp__.py => __manifest__.py} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename web_ir_actions_act_window_message/{__openerp__.py => __manifest__.py} (100%) diff --git a/web_ir_actions_act_window_message/__openerp__.py b/web_ir_actions_act_window_message/__manifest__.py similarity index 100% rename from web_ir_actions_act_window_message/__openerp__.py rename to web_ir_actions_act_window_message/__manifest__.py From 8649a4ceeb08632ae411760b0f90a6c05f894668 Mon Sep 17 00:00:00 2001 From: Holger Brunn Date: Thu, 3 Mar 2016 17:27:19 +0100 Subject: [PATCH 08/27] allow to pass a list of buttons --- web_ir_actions_act_window_message/README.rst | 25 ++++++++- .../js/web_ir_actions_act_window_message.js | 55 ++++++++++++++++++- 2 files changed, 77 insertions(+), 3 deletions(-) diff --git a/web_ir_actions_act_window_message/README.rst b/web_ir_actions_act_window_message/README.rst index f330f0bfd..8341746d5 100644 --- a/web_ir_actions_act_window_message/README.rst +++ b/web_ir_actions_act_window_message/README.rst @@ -14,6 +14,30 @@ Depend on this module and return 'type': 'ir.actions.act_window.message', 'title': _('My title'), 'message': _('My message'), + # this is an optional list of buttons to show + 'buttons': [ + # a button can be any action (also ir.actions.report.xml et al) + { + 'type': 'ir.actions.act_window', + 'name': 'All customers', + 'res_model': 'res.partner', + 'view_mode': 'form', + 'views': [[False, 'list'], [False, 'form']], + 'domain': [('customer', '=', True)], + }, + # or if type == method, you need to pass a model, a method name and + # parameters + { + 'type': 'method', + 'name': _('Yes, do it'), + 'model': self._name, + 'method': 'myfunction', + # list of arguments to pass positionally + 'args': [self.ids], + # dictionary of keyword arguments + 'kwargs': {'force': True}, + } + ] } You are responsible for translating the messages. @@ -24,7 +48,6 @@ Known issues / Roadmap * add `message_type` to differenciate between warnings, errors, etc. * have one `message_type` to show a nonmodal warning on top right * have `button_title` to set the button title -* have `buttons` containing button names and action definitions for triggering actions from the message box Bug Tracker diff --git a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js index bfc6f55da..95f3b26d4 100644 --- a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js +++ b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js @@ -24,7 +24,8 @@ openerp.web_ir_actions_act_window_message = function(instance) instance.web.ActionManager.include({ ir_actions_act_window_message: function(action, options) { - var dialog = new instance.web.Dialog( + var self = this, + dialog = new instance.web.Dialog( this, { size: 'medium', @@ -35,7 +36,10 @@ openerp.web_ir_actions_act_window_message = function(instance) click: function() { dialog.close() }, oe_link_class: 'oe_highlight', }, - ], + ].concat( + this.ir_actions_act_window_message_get_buttons( + action, function() { dialog.close() }) + ), }, jQuery(instance.web.qweb.render( 'web_ir_actions_act_window_message', @@ -46,5 +50,52 @@ openerp.web_ir_actions_act_window_message = function(instance) ) return dialog.open(); }, + ir_actions_act_window_message_get_buttons: function(action, close_func) + { + // return an array of button definitions from action + var self = this; + return _.map(action.buttons || [], function(button_definition) + { + return { + text: button_definition.name || 'No name set', + oe_link_class: button_definition.oe_link_class || + 'oe_highlight', + click: function() { + if(button_definition.type == 'method') + { + (new instance.web.Model(button_definition.model)) + .call( + button_definition.method, + button_definition.args, + button_definition.kwargs + ).then(function(result) + { + if(_.isObject(result)) + { + self.do_action(result); + } + else + { + if( + self.inner_widget && + self.inner_widget.views + ) + { + self.inner_widget + .views[self.inner_widget.active_view] + .controller.recursive_reload(); + } + } + }); + } + else + { + self.do_action(button_definition); + } + close_func(); + }, + } + }); + }, }); } From 1dbe8b768af2a446e64cf4eb98f535b86bc223c6 Mon Sep 17 00:00:00 2001 From: Holger Brunn Date: Thu, 3 Mar 2016 17:38:57 +0100 Subject: [PATCH 09/27] implement close_button_title --- web_ir_actions_act_window_message/README.rst | 6 ++++- .../js/web_ir_actions_act_window_message.js | 22 ++++++++++++------- 2 files changed, 19 insertions(+), 9 deletions(-) diff --git a/web_ir_actions_act_window_message/README.rst b/web_ir_actions_act_window_message/README.rst index 8341746d5..cc368bed8 100644 --- a/web_ir_actions_act_window_message/README.rst +++ b/web_ir_actions_act_window_message/README.rst @@ -14,6 +14,11 @@ Depend on this module and return 'type': 'ir.actions.act_window.message', 'title': _('My title'), 'message': _('My message'), + # optional title of the close button, if not set, will be _('Close') + # if set False, no close button will be shown + # you can create your own close button with an action of type + # ir.actions.act_window_close + 'close_button_title': 'Make this window go away', # this is an optional list of buttons to show 'buttons': [ # a button can be any action (also ir.actions.report.xml et al) @@ -47,7 +52,6 @@ Known issues / Roadmap * add `message_type` to differenciate between warnings, errors, etc. * have one `message_type` to show a nonmodal warning on top right -* have `button_title` to set the button title Bug Tracker diff --git a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js index 95f3b26d4..227cd6710 100644 --- a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js +++ b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js @@ -25,18 +25,24 @@ openerp.web_ir_actions_act_window_message = function(instance) ir_actions_act_window_message: function(action, options) { var self = this, - dialog = new instance.web.Dialog( + buttons = []; + + if(action.close_button_title !== false) + { + buttons.push({ + text: action.close_button_title || + instance.web._t('Close'), + click: function() { dialog.close() }, + oe_link_class: 'oe_highlight', + }) + } + + var dialog = new instance.web.Dialog( this, { size: 'medium', title: action.title, - buttons: [ - { - text: instance.web._t('Close'), - click: function() { dialog.close() }, - oe_link_class: 'oe_highlight', - }, - ].concat( + buttons: buttons.concat( this.ir_actions_act_window_message_get_buttons( action, function() { dialog.close() }) ), From 589245ee87e2d7a7b67f1f23e8615760fbcaa718 Mon Sep 17 00:00:00 2001 From: OCA Transbot Date: Mon, 23 Nov 2015 23:43:23 -0500 Subject: [PATCH 10/27] OCA Transbot updated translations from Transifex --- web_ir_actions_act_window_message/i18n/ar.po | 25 ++++++++++++++++++ web_ir_actions_act_window_message/i18n/de.po | 26 +++++++++++++++++++ web_ir_actions_act_window_message/i18n/es.po | 26 +++++++++++++++++++ web_ir_actions_act_window_message/i18n/eu.po | 25 ++++++++++++++++++ web_ir_actions_act_window_message/i18n/fi.po | 25 ++++++++++++++++++ web_ir_actions_act_window_message/i18n/fr.po | 25 ++++++++++++++++++ web_ir_actions_act_window_message/i18n/hr.po | 25 ++++++++++++++++++ web_ir_actions_act_window_message/i18n/it.po | 25 ++++++++++++++++++ web_ir_actions_act_window_message/i18n/nl.po | 25 ++++++++++++++++++ .../i18n/pt_BR.po | 25 ++++++++++++++++++ web_ir_actions_act_window_message/i18n/sl.po | 25 ++++++++++++++++++ web_ir_actions_act_window_message/i18n/tr.po | 25 ++++++++++++++++++ 12 files changed, 302 insertions(+) create mode 100644 web_ir_actions_act_window_message/i18n/ar.po create mode 100644 web_ir_actions_act_window_message/i18n/de.po create mode 100644 web_ir_actions_act_window_message/i18n/es.po create mode 100644 web_ir_actions_act_window_message/i18n/eu.po create mode 100644 web_ir_actions_act_window_message/i18n/fi.po create mode 100644 web_ir_actions_act_window_message/i18n/fr.po create mode 100644 web_ir_actions_act_window_message/i18n/hr.po create mode 100644 web_ir_actions_act_window_message/i18n/it.po create mode 100644 web_ir_actions_act_window_message/i18n/nl.po create mode 100644 web_ir_actions_act_window_message/i18n/pt_BR.po create mode 100644 web_ir_actions_act_window_message/i18n/sl.po create mode 100644 web_ir_actions_act_window_message/i18n/tr.po diff --git a/web_ir_actions_act_window_message/i18n/ar.po b/web_ir_actions_act_window_message/i18n/ar.po new file mode 100644 index 000000000..c2bc8c41d --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/ar.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2015-12-16 07:41+0000\n" +"PO-Revision-Date: 2015-11-07 11:20+0000\n" +"Last-Translator: <>\n" +"Language-Team: Arabic (http://www.transifex.com/oca/OCA-web-8-0/language/ar/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: ar\n" +"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 && n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "إغلاق" diff --git a/web_ir_actions_act_window_message/i18n/de.po b/web_ir_actions_act_window_message/i18n/de.po new file mode 100644 index 000000000..1a53b6648 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/de.po @@ -0,0 +1,26 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +# Rudolf Schnapka , 2016 +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2016-01-10 07:31+0000\n" +"PO-Revision-Date: 2016-01-18 20:15+0000\n" +"Last-Translator: Rudolf Schnapka \n" +"Language-Team: German (http://www.transifex.com/oca/OCA-web-8-0/language/de/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: de\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Schließen" diff --git a/web_ir_actions_act_window_message/i18n/es.po b/web_ir_actions_act_window_message/i18n/es.po new file mode 100644 index 000000000..3b8d60e18 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/es.po @@ -0,0 +1,26 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +# Antonio Trueba, 2016 +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2016-01-10 07:31+0000\n" +"PO-Revision-Date: 2016-02-10 16:40+0000\n" +"Last-Translator: Antonio Trueba\n" +"Language-Team: Spanish (http://www.transifex.com/oca/OCA-web-8-0/language/es/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: es\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Cerrar" diff --git a/web_ir_actions_act_window_message/i18n/eu.po b/web_ir_actions_act_window_message/i18n/eu.po new file mode 100644 index 000000000..5ff5a28f4 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/eu.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-02-18 09:01+0000\n" +"PO-Revision-Date: 2015-11-07 11:20+0000\n" +"Last-Translator: <>\n" +"Language-Team: Basque (http://www.transifex.com/oca/OCA-web-8-0/language/eu/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: eu\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Itxi" diff --git a/web_ir_actions_act_window_message/i18n/fi.po b/web_ir_actions_act_window_message/i18n/fi.po new file mode 100644 index 000000000..30cc25fc6 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/fi.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2016-01-10 07:31+0000\n" +"PO-Revision-Date: 2015-11-07 11:20+0000\n" +"Last-Translator: <>\n" +"Language-Team: Finnish (http://www.transifex.com/oca/OCA-web-8-0/language/fi/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: fi\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Sulje" diff --git a/web_ir_actions_act_window_message/i18n/fr.po b/web_ir_actions_act_window_message/i18n/fr.po new file mode 100644 index 000000000..92af8cf48 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/fr.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2015-11-23 13:46+0000\n" +"PO-Revision-Date: 2015-11-07 11:20+0000\n" +"Last-Translator: <>\n" +"Language-Team: French (http://www.transifex.com/oca/OCA-web-8-0/language/fr/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: fr\n" +"Plural-Forms: nplurals=2; plural=(n > 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Fermer" diff --git a/web_ir_actions_act_window_message/i18n/hr.po b/web_ir_actions_act_window_message/i18n/hr.po new file mode 100644 index 000000000..6fdf3b7eb --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/hr.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2016-06-24 00:46+0000\n" +"PO-Revision-Date: 2015-11-07 11:20+0000\n" +"Last-Translator: <>\n" +"Language-Team: Croatian (http://www.transifex.com/oca/OCA-web-8-0/language/hr/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: hr\n" +"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Zatvori" diff --git a/web_ir_actions_act_window_message/i18n/it.po b/web_ir_actions_act_window_message/i18n/it.po new file mode 100644 index 000000000..108201e80 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/it.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2016-03-17 07:29+0000\n" +"PO-Revision-Date: 2015-11-07 11:20+0000\n" +"Last-Translator: <>\n" +"Language-Team: Italian (http://www.transifex.com/oca/OCA-web-8-0/language/it/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: it\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Chiudi" diff --git a/web_ir_actions_act_window_message/i18n/nl.po b/web_ir_actions_act_window_message/i18n/nl.po new file mode 100644 index 000000000..67049ccfe --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/nl.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-01-21 08:52+0000\n" +"PO-Revision-Date: 2015-11-07 11:20+0000\n" +"Last-Translator: <>\n" +"Language-Team: Dutch (http://www.transifex.com/oca/OCA-web-8-0/language/nl/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: nl\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Sluiten" diff --git a/web_ir_actions_act_window_message/i18n/pt_BR.po b/web_ir_actions_act_window_message/i18n/pt_BR.po new file mode 100644 index 000000000..dd6d8167e --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/pt_BR.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2016-03-11 02:17+0000\n" +"PO-Revision-Date: 2016-03-05 16:20+0000\n" +"Last-Translator: danimaribeiro \n" +"Language-Team: Portuguese (Brazil) (http://www.transifex.com/oca/OCA-web-8-0/language/pt_BR/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: pt_BR\n" +"Plural-Forms: nplurals=2; plural=(n > 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Fechar" diff --git a/web_ir_actions_act_window_message/i18n/sl.po b/web_ir_actions_act_window_message/i18n/sl.po new file mode 100644 index 000000000..63ddbc003 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/sl.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2015-11-23 13:46+0000\n" +"PO-Revision-Date: 2015-11-08 05:45+0000\n" +"Last-Translator: Matjaž Mozetič \n" +"Language-Team: Slovenian (http://www.transifex.com/oca/OCA-web-8-0/language/sl/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: sl\n" +"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n%100==4 ? 2 : 3);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Zaključi" diff --git a/web_ir_actions_act_window_message/i18n/tr.po b/web_ir_actions_act_window_message/i18n/tr.po new file mode 100644 index 000000000..7d4493a4f --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/tr.po @@ -0,0 +1,25 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +msgid "" +msgstr "" +"Project-Id-Version: web (8.0)\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2016-01-08 21:34+0000\n" +"PO-Revision-Date: 2015-12-30 22:16+0000\n" +"Last-Translator: Ahmet Altınışık \n" +"Language-Team: Turkish (http://www.transifex.com/oca/OCA-web-8-0/language/tr/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: tr\n" +"Plural-Forms: nplurals=2; plural=(n > 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#, python-format +msgid "Close" +msgstr "Kapat" From 96be237d244ca54661a985863adca56cd8e9554c Mon Sep 17 00:00:00 2001 From: Zakaria Makrelouf Date: Tue, 25 Apr 2017 13:15:01 +0100 Subject: [PATCH 11/27] web_ir_actions_act_window_message: Migration to V9 * Update the module version to 9.0. * Align file header to the OCA Guidelines. * Migrate Javascript file to the V9 API. * Refresh the view before closing the dialog when clicking on close button --- web_ir_actions_act_window_message/README.rst | 1 + web_ir_actions_act_window_message/__init__.py | 20 ----- .../__manifest__.py | 30 +------ .../js/web_ir_actions_act_window_message.js | 82 ++++++++----------- .../views/templates.xml | 23 +++--- 5 files changed, 54 insertions(+), 102 deletions(-) diff --git a/web_ir_actions_act_window_message/README.rst b/web_ir_actions_act_window_message/README.rst index cc368bed8..e991265c9 100644 --- a/web_ir_actions_act_window_message/README.rst +++ b/web_ir_actions_act_window_message/README.rst @@ -70,6 +70,7 @@ Contributors ------------ * Holger Brunn +* Zakaria Makrelouf (ACSONE SA/NV) Maintainer ---------- diff --git a/web_ir_actions_act_window_message/__init__.py b/web_ir_actions_act_window_message/__init__.py index faef9dac0..e69de29bb 100644 --- a/web_ir_actions_act_window_message/__init__.py +++ b/web_ir_actions_act_window_message/__init__.py @@ -1,20 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# This module copyright (C) 2015 Therp BV . -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## diff --git a/web_ir_actions_act_window_message/__manifest__.py b/web_ir_actions_act_window_message/__manifest__.py index 7a553c520..9a8bdcc1d 100644 --- a/web_ir_actions_act_window_message/__manifest__.py +++ b/web_ir_actions_act_window_message/__manifest__.py @@ -1,27 +1,11 @@ # -*- coding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# This module copyright (C) 2015 Therp BV . -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## +# Copyright 2017 Therp BV, ACSONE SA/NV +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). { "name": "Client side message boxes", - "version": "8.0.1.0.0", + "version": "9.0.1.0.0", "author": "Therp BV, " + "ACSONE SA/NV, " "Odoo Community Association (OCA)", "license": "AGPL-3", "category": "Hidden/Dependency", @@ -35,10 +19,4 @@ "qweb": [ 'static/src/xml/web_ir_actions_act_window_message.xml', ], - "auto_install": False, - 'installable': False, - "application": False, - "external_dependencies": { - 'python': [], - }, } diff --git a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js index 227cd6710..006ac8df3 100644 --- a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js +++ b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js @@ -1,59 +1,51 @@ -//-*- coding: utf-8 -*- -//############################################################################ -// -// OpenERP, Open Source Management Solution -// This module copyright (C) 2015 Therp BV . -// -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU Affero General Public License as -// published by the Free Software Foundation, either version 3 of the -// License, or (at your option) any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU Affero General Public License for more details. -// -// You should have received a copy of the GNU Affero General Public License -// along with this program. If not, see . -// -//############################################################################ +/* Copyright 2017 Therp BV, ACSONE SA/NV + * * License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). */ + +odoo.define('web.web_ir_actions_act_window_message', function (require) { + "use strict"; + + var ActionManager = require('web.ActionManager'), + core = require('web.core'), + _ = require('_'), + Model = require('web.Model'), + Dialog = require('web.Dialog'); + + var _t = core._t; + + ActionManager.include({ + ir_actions_act_window_message: function(action, options){ -openerp.web_ir_actions_act_window_message = function(instance) -{ - instance.web.ActionManager.include({ - ir_actions_act_window_message: function(action, options) - { var self = this, buttons = []; if(action.close_button_title !== false) { buttons.push({ - text: action.close_button_title || - instance.web._t('Close'), - click: function() { dialog.close() }, + text: action.close_button_title || _t('Close'), + click: function() { + // refresh the view before closing the dialog + self.inner_widget.active_view + .controller.recursive_reload(); + dialog.close() + }, oe_link_class: 'oe_highlight', }) } - var dialog = new instance.web.Dialog( + var dialog = new Dialog( this, - { + _.extend({ size: 'medium', title: action.title, + $content: $('
', { + text: action.message, + }), buttons: buttons.concat( this.ir_actions_act_window_message_get_buttons( action, function() { dialog.close() }) ), - }, - jQuery(instance.web.qweb.render( - 'web_ir_actions_act_window_message', - { - 'this': this, - 'action': action, - })) - ) + }, options) + ); return dialog.open(); }, ir_actions_act_window_message_get_buttons: function(action, close_func) @@ -67,9 +59,8 @@ openerp.web_ir_actions_act_window_message = function(instance) oe_link_class: button_definition.oe_link_class || 'oe_highlight', click: function() { - if(button_definition.type == 'method') - { - (new instance.web.Model(button_definition.model)) + if(button_definition.type == 'method'){ + (new Model(button_definition.model)) .call( button_definition.method, button_definition.args, @@ -94,14 +85,13 @@ openerp.web_ir_actions_act_window_message = function(instance) } }); } - else - { + else{ self.do_action(button_definition); } close_func(); - }, + } } }); - }, + } }); -} +}); diff --git a/web_ir_actions_act_window_message/views/templates.xml b/web_ir_actions_act_window_message/views/templates.xml index 9ba42b0b2..44b1c287e 100644 --- a/web_ir_actions_act_window_message/views/templates.xml +++ b/web_ir_actions_act_window_message/views/templates.xml @@ -1,10 +1,13 @@ - - - - - - + + + + + + + + \ No newline at end of file From 2a6bad1897007e707d9543b024b1b93c4d766491 Mon Sep 17 00:00:00 2001 From: Zakaria Makrelouf Date: Sun, 7 May 2017 10:16:19 +0100 Subject: [PATCH 12/27] web_ir_actions_act_window_message: always refresh view after action --- .../src/js/web_ir_actions_act_window_message.js | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js index 006ac8df3..6a71ace1d 100644 --- a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js +++ b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js @@ -71,18 +71,10 @@ odoo.define('web.web_ir_actions_act_window_message', function (require) { { self.do_action(result); } - else - { - if( - self.inner_widget && - self.inner_widget.views - ) - { - self.inner_widget - .views[self.inner_widget.active_view] - .controller.recursive_reload(); - } - } + // always refresh the view after the action + // ex: action updates a status + self.inner_widget.active_view + .controller.recursive_reload(); }); } else{ From 991e5ec36e4195f0d570386f95897fa4ad16017b Mon Sep 17 00:00:00 2001 From: Zakaria Makrelouf Date: Tue, 16 May 2017 08:56:39 +0100 Subject: [PATCH 13/27] Reformat the code to have coherent coding style --- .../js/web_ir_actions_act_window_message.js | 45 +++++++++++-------- 1 file changed, 26 insertions(+), 19 deletions(-) diff --git a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js index 6a71ace1d..fbc620a09 100644 --- a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js +++ b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js @@ -1,7 +1,8 @@ /* Copyright 2017 Therp BV, ACSONE SA/NV * * License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). */ -odoo.define('web.web_ir_actions_act_window_message', function (require) { +odoo.define('web.web_ir_actions_act_window_message', function(require) +{ "use strict"; var ActionManager = require('web.ActionManager'), @@ -13,8 +14,8 @@ odoo.define('web.web_ir_actions_act_window_message', function (require) { var _t = core._t; ActionManager.include({ - ir_actions_act_window_message: function(action, options){ - + ir_actions_act_window_message: function(action, options) + { var self = this, buttons = []; @@ -34,18 +35,22 @@ odoo.define('web.web_ir_actions_act_window_message', function (require) { var dialog = new Dialog( this, - _.extend({ - size: 'medium', - title: action.title, - $content: $('
', { - text: action.message, - }), - buttons: buttons.concat( - this.ir_actions_act_window_message_get_buttons( - action, function() { dialog.close() }) - ), - }, options) - ); + _.extend( + { + size: 'medium', + title: action.title, + $content: $('
', + { + text: action.message, + } + ), + buttons: buttons.concat( + this.ir_actions_act_window_message_get_buttons( + action, function() { dialog.close() }) + ), + }, + options) + ) return dialog.open(); }, ir_actions_act_window_message_get_buttons: function(action, close_func) @@ -59,7 +64,8 @@ odoo.define('web.web_ir_actions_act_window_message', function (require) { oe_link_class: button_definition.oe_link_class || 'oe_highlight', click: function() { - if(button_definition.type == 'method'){ + if(button_definition.type == 'method') + { (new Model(button_definition.model)) .call( button_definition.method, @@ -77,13 +83,14 @@ odoo.define('web.web_ir_actions_act_window_message', function (require) { .controller.recursive_reload(); }); } - else{ + else + { self.do_action(button_definition); } close_func(); - } + }, } }); - } + }, }); }); From 4af620a6ed19d445548ada2332cd90571397b90c Mon Sep 17 00:00:00 2001 From: Zakaria Makrelouf Date: Tue, 16 May 2017 09:00:16 +0100 Subject: [PATCH 14/27] s/oe_link_class/classes s/oe_highlight/btn-default and add it to readme * In v9.0 odoo uses classes for dialog buttons instead of oe_link_class --- web_ir_actions_act_window_message/README.rst | 2 ++ .../static/src/js/web_ir_actions_act_window_message.js | 5 ++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/web_ir_actions_act_window_message/README.rst b/web_ir_actions_act_window_message/README.rst index e991265c9..4a64a92ed 100644 --- a/web_ir_actions_act_window_message/README.rst +++ b/web_ir_actions_act_window_message/README.rst @@ -41,6 +41,8 @@ Depend on this module and return 'args': [self.ids], # dictionary of keyword arguments 'kwargs': {'force': True}, + # button style + 'classes': 'btn-primary', } ] } diff --git a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js index fbc620a09..d2a838e2f 100644 --- a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js +++ b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js @@ -29,7 +29,7 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) .controller.recursive_reload(); dialog.close() }, - oe_link_class: 'oe_highlight', + classes: 'btn-default', }) } @@ -61,8 +61,7 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) { return { text: button_definition.name || 'No name set', - oe_link_class: button_definition.oe_link_class || - 'oe_highlight', + classes: button_definition.classes || 'btn-default', click: function() { if(button_definition.type == 'method') { From c9c61f141954a60ddc202afc3f83b6a3875f5dea Mon Sep 17 00:00:00 2001 From: Zakaria Makrelouf Date: Tue, 16 May 2017 09:37:43 +0100 Subject: [PATCH 15/27] wrap line breaks of the action message --- .../static/src/js/web_ir_actions_act_window_message.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js index d2a838e2f..4ea153d48 100644 --- a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js +++ b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js @@ -42,6 +42,9 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) $content: $('
', { text: action.message, + css: { + 'white-space': 'pre-line', + } } ), buttons: buttons.concat( From e807e5ecd43899dadb053a0fc210573a9b2d4937 Mon Sep 17 00:00:00 2001 From: Benjamin Willig Date: Tue, 23 May 2017 17:25:01 +0200 Subject: [PATCH 16/27] [MIG] web_ir_actions_act_window_message: Migration to 10. Also added HTML handling --- web_ir_actions_act_window_message/README.rst | 5 +++- .../__manifest__.py | 2 +- .../js/web_ir_actions_act_window_message.js | 26 ++++++++++++------- 3 files changed, 22 insertions(+), 11 deletions(-) diff --git a/web_ir_actions_act_window_message/README.rst b/web_ir_actions_act_window_message/README.rst index 4a64a92ed..3772ad3e7 100644 --- a/web_ir_actions_act_window_message/README.rst +++ b/web_ir_actions_act_window_message/README.rst @@ -19,6 +19,8 @@ Depend on this module and return # you can create your own close button with an action of type # ir.actions.act_window_close 'close_button_title': 'Make this window go away', + # Use HTML instead of text + 'is_html_message': True, # this is an optional list of buttons to show 'buttons': [ # a button can be any action (also ir.actions.report.xml et al) @@ -73,6 +75,7 @@ Contributors * Holger Brunn * Zakaria Makrelouf (ACSONE SA/NV) +* Benjamin Willig (ACSONE SA/NV) Maintainer ---------- @@ -85,4 +88,4 @@ This module is maintained by the OCA. OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use. -To contribute to this module, please visit http://odoo-community.org. +To contribute to this module, please visit http://odoo-community.org. \ No newline at end of file diff --git a/web_ir_actions_act_window_message/__manifest__.py b/web_ir_actions_act_window_message/__manifest__.py index 9a8bdcc1d..5dd3b18b1 100644 --- a/web_ir_actions_act_window_message/__manifest__.py +++ b/web_ir_actions_act_window_message/__manifest__.py @@ -3,7 +3,7 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). { "name": "Client side message boxes", - "version": "9.0.1.0.0", + "version": "10.0.1.0.0", "author": "Therp BV, " "ACSONE SA/NV, " "Odoo Community Association (OCA)", diff --git a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js index 4ea153d48..1b0708d71 100644 --- a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js +++ b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js @@ -7,7 +7,6 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) var ActionManager = require('web.ActionManager'), core = require('web.core'), - _ = require('_'), Model = require('web.Model'), Dialog = require('web.Dialog'); @@ -33,20 +32,29 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) }) } + var is_html = action.is_html_message === true; + var content_properties = {}; + + if (is_html) { + content_properties = { + html: action.message, + }; + } else { + content_properties = { + text: action.message, + css: { + 'white-space': 'pre-line', + } + }; + } + var dialog = new Dialog( this, _.extend( { size: 'medium', title: action.title, - $content: $('
', - { - text: action.message, - css: { - 'white-space': 'pre-line', - } - } - ), + $content: $('
', content_properties), buttons: buttons.concat( this.ir_actions_act_window_message_get_buttons( action, function() { dialog.close() }) From 13fcc4c740685e01150bd2a87b7919b0327a0873 Mon Sep 17 00:00:00 2001 From: OCA Transbot Date: Sat, 3 Jun 2017 12:41:51 +0200 Subject: [PATCH 17/27] OCA Transbot updated translations from Transifex --- web_ir_actions_act_window_message/i18n/ar.po | 13 +++++----- web_ir_actions_act_window_message/i18n/de.po | 14 +++++----- web_ir_actions_act_window_message/i18n/es.po | 14 +++++----- web_ir_actions_act_window_message/i18n/eu.po | 13 +++++----- web_ir_actions_act_window_message/i18n/fi.po | 13 +++++----- web_ir_actions_act_window_message/i18n/fr.po | 13 +++++----- web_ir_actions_act_window_message/i18n/hr.po | 13 +++++----- web_ir_actions_act_window_message/i18n/it.po | 13 +++++----- web_ir_actions_act_window_message/i18n/nl.po | 13 +++++----- .../i18n/nl_NL.po | 26 +++++++++++++++++++ web_ir_actions_act_window_message/i18n/pt.po | 26 +++++++++++++++++++ .../i18n/pt_BR.po | 13 +++++----- web_ir_actions_act_window_message/i18n/ro.po | 26 +++++++++++++++++++ web_ir_actions_act_window_message/i18n/sl.po | 13 +++++----- web_ir_actions_act_window_message/i18n/tr.po | 13 +++++----- 15 files changed, 162 insertions(+), 74 deletions(-) create mode 100644 web_ir_actions_act_window_message/i18n/nl_NL.po create mode 100644 web_ir_actions_act_window_message/i18n/pt.po create mode 100644 web_ir_actions_act_window_message/i18n/ro.po diff --git a/web_ir_actions_act_window_message/i18n/ar.po b/web_ir_actions_act_window_message/i18n/ar.po index c2bc8c41d..0008b6b6d 100644 --- a/web_ir_actions_act_window_message/i18n/ar.po +++ b/web_ir_actions_act_window_message/i18n/ar.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-12-16 07:41+0000\n" -"PO-Revision-Date: 2015-11-07 11:20+0000\n" -"Last-Translator: <>\n" -"Language-Team: Arabic (http://www.transifex.com/oca/OCA-web-8-0/language/ar/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Arabic (https://www.transifex.com/oca/teams/23907/ar/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "إغلاق" diff --git a/web_ir_actions_act_window_message/i18n/de.po b/web_ir_actions_act_window_message/i18n/de.po index 1a53b6648..b1f6629a0 100644 --- a/web_ir_actions_act_window_message/i18n/de.po +++ b/web_ir_actions_act_window_message/i18n/de.po @@ -3,15 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: -# Rudolf Schnapka , 2016 +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2016-01-10 07:31+0000\n" -"PO-Revision-Date: 2016-01-18 20:15+0000\n" -"Last-Translator: Rudolf Schnapka \n" -"Language-Team: German (http://www.transifex.com/oca/OCA-web-8-0/language/de/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: German (https://www.transifex.com/oca/teams/23907/de/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -20,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Schließen" diff --git a/web_ir_actions_act_window_message/i18n/es.po b/web_ir_actions_act_window_message/i18n/es.po index 3b8d60e18..3b6d628ff 100644 --- a/web_ir_actions_act_window_message/i18n/es.po +++ b/web_ir_actions_act_window_message/i18n/es.po @@ -3,15 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: -# Antonio Trueba, 2016 +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2016-01-10 07:31+0000\n" -"PO-Revision-Date: 2016-02-10 16:40+0000\n" -"Last-Translator: Antonio Trueba\n" -"Language-Team: Spanish (http://www.transifex.com/oca/OCA-web-8-0/language/es/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Spanish (https://www.transifex.com/oca/teams/23907/es/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -20,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Cerrar" diff --git a/web_ir_actions_act_window_message/i18n/eu.po b/web_ir_actions_act_window_message/i18n/eu.po index 5ff5a28f4..41fb36af5 100644 --- a/web_ir_actions_act_window_message/i18n/eu.po +++ b/web_ir_actions_act_window_message/i18n/eu.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2017-02-18 09:01+0000\n" -"PO-Revision-Date: 2015-11-07 11:20+0000\n" -"Last-Translator: <>\n" -"Language-Team: Basque (http://www.transifex.com/oca/OCA-web-8-0/language/eu/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Basque (https://www.transifex.com/oca/teams/23907/eu/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Itxi" diff --git a/web_ir_actions_act_window_message/i18n/fi.po b/web_ir_actions_act_window_message/i18n/fi.po index 30cc25fc6..5f8ffd6a3 100644 --- a/web_ir_actions_act_window_message/i18n/fi.po +++ b/web_ir_actions_act_window_message/i18n/fi.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2016-01-10 07:31+0000\n" -"PO-Revision-Date: 2015-11-07 11:20+0000\n" -"Last-Translator: <>\n" -"Language-Team: Finnish (http://www.transifex.com/oca/OCA-web-8-0/language/fi/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Finnish (https://www.transifex.com/oca/teams/23907/fi/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Sulje" diff --git a/web_ir_actions_act_window_message/i18n/fr.po b/web_ir_actions_act_window_message/i18n/fr.po index 92af8cf48..458aeb94b 100644 --- a/web_ir_actions_act_window_message/i18n/fr.po +++ b/web_ir_actions_act_window_message/i18n/fr.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-11-23 13:46+0000\n" -"PO-Revision-Date: 2015-11-07 11:20+0000\n" -"Last-Translator: <>\n" -"Language-Team: French (http://www.transifex.com/oca/OCA-web-8-0/language/fr/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: French (https://www.transifex.com/oca/teams/23907/fr/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Fermer" diff --git a/web_ir_actions_act_window_message/i18n/hr.po b/web_ir_actions_act_window_message/i18n/hr.po index 6fdf3b7eb..5ac4e74c2 100644 --- a/web_ir_actions_act_window_message/i18n/hr.po +++ b/web_ir_actions_act_window_message/i18n/hr.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2016-06-24 00:46+0000\n" -"PO-Revision-Date: 2015-11-07 11:20+0000\n" -"Last-Translator: <>\n" -"Language-Team: Croatian (http://www.transifex.com/oca/OCA-web-8-0/language/hr/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Croatian (https://www.transifex.com/oca/teams/23907/hr/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Zatvori" diff --git a/web_ir_actions_act_window_message/i18n/it.po b/web_ir_actions_act_window_message/i18n/it.po index 108201e80..7baa87e59 100644 --- a/web_ir_actions_act_window_message/i18n/it.po +++ b/web_ir_actions_act_window_message/i18n/it.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2016-03-17 07:29+0000\n" -"PO-Revision-Date: 2015-11-07 11:20+0000\n" -"Last-Translator: <>\n" -"Language-Team: Italian (http://www.transifex.com/oca/OCA-web-8-0/language/it/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Italian (https://www.transifex.com/oca/teams/23907/it/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Chiudi" diff --git a/web_ir_actions_act_window_message/i18n/nl.po b/web_ir_actions_act_window_message/i18n/nl.po index 67049ccfe..a6a02243d 100644 --- a/web_ir_actions_act_window_message/i18n/nl.po +++ b/web_ir_actions_act_window_message/i18n/nl.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2017-01-21 08:52+0000\n" -"PO-Revision-Date: 2015-11-07 11:20+0000\n" -"Last-Translator: <>\n" -"Language-Team: Dutch (http://www.transifex.com/oca/OCA-web-8-0/language/nl/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Dutch (https://www.transifex.com/oca/teams/23907/nl/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Sluiten" diff --git a/web_ir_actions_act_window_message/i18n/nl_NL.po b/web_ir_actions_act_window_message/i18n/nl_NL.po new file mode 100644 index 000000000..c6bd95c79 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/nl_NL.po @@ -0,0 +1,26 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +# Peter Hageman , 2017 +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 10.0\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-22 08:27+0000\n" +"PO-Revision-Date: 2017-06-22 08:27+0000\n" +"Last-Translator: Peter Hageman , 2017\n" +"Language-Team: Dutch (Netherlands) (https://www.transifex.com/oca/teams/23907/nl_NL/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: nl_NL\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 +#, python-format +msgid "Close" +msgstr "Sluiten" diff --git a/web_ir_actions_act_window_message/i18n/pt.po b/web_ir_actions_act_window_message/i18n/pt.po new file mode 100644 index 000000000..0bb7ba965 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/pt.po @@ -0,0 +1,26 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +# Pedro Castro Silva , 2017 +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 10.0\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2018-01-03 03:50+0000\n" +"PO-Revision-Date: 2018-01-03 03:50+0000\n" +"Last-Translator: Pedro Castro Silva , 2017\n" +"Language-Team: Portuguese (https://www.transifex.com/oca/teams/23907/pt/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: pt\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 +#, python-format +msgid "Close" +msgstr "Fechar" diff --git a/web_ir_actions_act_window_message/i18n/pt_BR.po b/web_ir_actions_act_window_message/i18n/pt_BR.po index dd6d8167e..6e9f2a684 100644 --- a/web_ir_actions_act_window_message/i18n/pt_BR.po +++ b/web_ir_actions_act_window_message/i18n/pt_BR.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2016-03-11 02:17+0000\n" -"PO-Revision-Date: 2016-03-05 16:20+0000\n" -"Last-Translator: danimaribeiro \n" -"Language-Team: Portuguese (Brazil) (http://www.transifex.com/oca/OCA-web-8-0/language/pt_BR/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Portuguese (Brazil) (https://www.transifex.com/oca/teams/23907/pt_BR/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Fechar" diff --git a/web_ir_actions_act_window_message/i18n/ro.po b/web_ir_actions_act_window_message/i18n/ro.po new file mode 100644 index 000000000..5f0f9ca7d --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/ro.po @@ -0,0 +1,26 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +# Translators: +# Dorin Hongu , 2017 +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 10.0\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2018-01-03 03:50+0000\n" +"PO-Revision-Date: 2018-01-03 03:50+0000\n" +"Last-Translator: Dorin Hongu , 2017\n" +"Language-Team: Romanian (https://www.transifex.com/oca/teams/23907/ro/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Language: ro\n" +"Plural-Forms: nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?2:1));\n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 +#, python-format +msgid "Close" +msgstr "Închide" diff --git a/web_ir_actions_act_window_message/i18n/sl.po b/web_ir_actions_act_window_message/i18n/sl.po index 63ddbc003..5725b8df4 100644 --- a/web_ir_actions_act_window_message/i18n/sl.po +++ b/web_ir_actions_act_window_message/i18n/sl.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-11-23 13:46+0000\n" -"PO-Revision-Date: 2015-11-08 05:45+0000\n" -"Last-Translator: Matjaž Mozetič \n" -"Language-Team: Slovenian (http://www.transifex.com/oca/OCA-web-8-0/language/sl/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Slovenian (https://www.transifex.com/oca/teams/23907/sl/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Zaključi" diff --git a/web_ir_actions_act_window_message/i18n/tr.po b/web_ir_actions_act_window_message/i18n/tr.po index 7d4493a4f..4f3a7178d 100644 --- a/web_ir_actions_act_window_message/i18n/tr.po +++ b/web_ir_actions_act_window_message/i18n/tr.po @@ -3,14 +3,15 @@ # * web_ir_actions_act_window_message # # Translators: +# OCA Transbot , 2017 msgid "" msgstr "" -"Project-Id-Version: web (8.0)\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2016-01-08 21:34+0000\n" -"PO-Revision-Date: 2015-12-30 22:16+0000\n" -"Last-Translator: Ahmet Altınışık \n" -"Language-Team: Turkish (http://www.transifex.com/oca/OCA-web-8-0/language/tr/)\n" +"POT-Creation-Date: 2017-06-02 09:52+0000\n" +"PO-Revision-Date: 2017-06-02 09:52+0000\n" +"Last-Translator: OCA Transbot , 2017\n" +"Language-Team: Turkish (https://www.transifex.com/oca/teams/23907/tr/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" @@ -19,7 +20,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:34 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 #, python-format msgid "Close" msgstr "Kapat" From 1a5a6d3d86839580655ad9e0d665e18f28791f35 Mon Sep 17 00:00:00 2001 From: oca-travis Date: Sun, 24 Jun 2018 01:39:29 +0000 Subject: [PATCH 18/27] [UPD] Update web_ir_actions_act_window_message.pot --- web_ir_actions_act_window_message/i18n/ar.po | 7 +++--- web_ir_actions_act_window_message/i18n/de.po | 4 ++-- web_ir_actions_act_window_message/i18n/es.po | 4 ++-- web_ir_actions_act_window_message/i18n/eu.po | 4 ++-- web_ir_actions_act_window_message/i18n/fi.po | 4 ++-- web_ir_actions_act_window_message/i18n/fr.po | 4 ++-- web_ir_actions_act_window_message/i18n/hr.po | 7 +++--- web_ir_actions_act_window_message/i18n/it.po | 4 ++-- web_ir_actions_act_window_message/i18n/nl.po | 4 ++-- .../i18n/nl_NL.po | 7 +++--- web_ir_actions_act_window_message/i18n/pt.po | 4 ++-- .../i18n/pt_BR.po | 7 +++--- web_ir_actions_act_window_message/i18n/ro.po | 7 +++--- web_ir_actions_act_window_message/i18n/sl.po | 7 +++--- web_ir_actions_act_window_message/i18n/tr.po | 4 ++-- .../web_ir_actions_act_window_message.pot | 22 +++++++++++++++++++ 16 files changed, 64 insertions(+), 36 deletions(-) create mode 100644 web_ir_actions_act_window_message/i18n/web_ir_actions_act_window_message.pot diff --git a/web_ir_actions_act_window_message/i18n/ar.po b/web_ir_actions_act_window_message/i18n/ar.po index 0008b6b6d..6c0e056f7 100644 --- a/web_ir_actions_act_window_message/i18n/ar.po +++ b/web_ir_actions_act_window_message/i18n/ar.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,11 +12,12 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: Arabic (https://www.transifex.com/oca/teams/23907/ar/)\n" +"Language: ar\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: ar\n" -"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 && n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n" +"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 " +"&& n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n" #. module: web_ir_actions_act_window_message #. openerp-web diff --git a/web_ir_actions_act_window_message/i18n/de.po b/web_ir_actions_act_window_message/i18n/de.po index b1f6629a0..15a278657 100644 --- a/web_ir_actions_act_window_message/i18n/de.po +++ b/web_ir_actions_act_window_message/i18n/de.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,10 +12,10 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: German (https://www.transifex.com/oca/teams/23907/de/)\n" +"Language: de\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: de\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/es.po b/web_ir_actions_act_window_message/i18n/es.po index 3b6d628ff..b5ea46f18 100644 --- a/web_ir_actions_act_window_message/i18n/es.po +++ b/web_ir_actions_act_window_message/i18n/es.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,10 +12,10 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: Spanish (https://www.transifex.com/oca/teams/23907/es/)\n" +"Language: es\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: es\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/eu.po b/web_ir_actions_act_window_message/i18n/eu.po index 41fb36af5..182c1e76b 100644 --- a/web_ir_actions_act_window_message/i18n/eu.po +++ b/web_ir_actions_act_window_message/i18n/eu.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,10 +12,10 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: Basque (https://www.transifex.com/oca/teams/23907/eu/)\n" +"Language: eu\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: eu\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/fi.po b/web_ir_actions_act_window_message/i18n/fi.po index 5f8ffd6a3..932ae1e7b 100644 --- a/web_ir_actions_act_window_message/i18n/fi.po +++ b/web_ir_actions_act_window_message/i18n/fi.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,10 +12,10 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: Finnish (https://www.transifex.com/oca/teams/23907/fi/)\n" +"Language: fi\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: fi\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/fr.po b/web_ir_actions_act_window_message/i18n/fr.po index 458aeb94b..bcb10858c 100644 --- a/web_ir_actions_act_window_message/i18n/fr.po +++ b/web_ir_actions_act_window_message/i18n/fr.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,10 +12,10 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: French (https://www.transifex.com/oca/teams/23907/fr/)\n" +"Language: fr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: fr\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/hr.po b/web_ir_actions_act_window_message/i18n/hr.po index 5ac4e74c2..799efce48 100644 --- a/web_ir_actions_act_window_message/i18n/hr.po +++ b/web_ir_actions_act_window_message/i18n/hr.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,11 +12,12 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: Croatian (https://www.transifex.com/oca/teams/23907/hr/)\n" +"Language: hr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: hr\n" -"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" +"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" +"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" #. module: web_ir_actions_act_window_message #. openerp-web diff --git a/web_ir_actions_act_window_message/i18n/it.po b/web_ir_actions_act_window_message/i18n/it.po index 7baa87e59..b68dc6564 100644 --- a/web_ir_actions_act_window_message/i18n/it.po +++ b/web_ir_actions_act_window_message/i18n/it.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,10 +12,10 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: Italian (https://www.transifex.com/oca/teams/23907/it/)\n" +"Language: it\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: it\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/nl.po b/web_ir_actions_act_window_message/i18n/nl.po index a6a02243d..5f3a60ad1 100644 --- a/web_ir_actions_act_window_message/i18n/nl.po +++ b/web_ir_actions_act_window_message/i18n/nl.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,10 +12,10 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: Dutch (https://www.transifex.com/oca/teams/23907/nl/)\n" +"Language: nl\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: nl\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/nl_NL.po b/web_ir_actions_act_window_message/i18n/nl_NL.po index c6bd95c79..cb772c2f7 100644 --- a/web_ir_actions_act_window_message/i18n/nl_NL.po +++ b/web_ir_actions_act_window_message/i18n/nl_NL.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # Peter Hageman , 2017 msgid "" @@ -11,11 +11,12 @@ msgstr "" "POT-Creation-Date: 2017-06-22 08:27+0000\n" "PO-Revision-Date: 2017-06-22 08:27+0000\n" "Last-Translator: Peter Hageman , 2017\n" -"Language-Team: Dutch (Netherlands) (https://www.transifex.com/oca/teams/23907/nl_NL/)\n" +"Language-Team: Dutch (Netherlands) (https://www.transifex.com/oca/" +"teams/23907/nl_NL/)\n" +"Language: nl_NL\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: nl_NL\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/pt.po b/web_ir_actions_act_window_message/i18n/pt.po index 0bb7ba965..e25efb477 100644 --- a/web_ir_actions_act_window_message/i18n/pt.po +++ b/web_ir_actions_act_window_message/i18n/pt.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # Pedro Castro Silva , 2017 msgid "" @@ -12,10 +12,10 @@ msgstr "" "PO-Revision-Date: 2018-01-03 03:50+0000\n" "Last-Translator: Pedro Castro Silva , 2017\n" "Language-Team: Portuguese (https://www.transifex.com/oca/teams/23907/pt/)\n" +"Language: pt\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: pt\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/pt_BR.po b/web_ir_actions_act_window_message/i18n/pt_BR.po index 6e9f2a684..c9a7d2189 100644 --- a/web_ir_actions_act_window_message/i18n/pt_BR.po +++ b/web_ir_actions_act_window_message/i18n/pt_BR.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -11,11 +11,12 @@ msgstr "" "POT-Creation-Date: 2017-06-02 09:52+0000\n" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" -"Language-Team: Portuguese (Brazil) (https://www.transifex.com/oca/teams/23907/pt_BR/)\n" +"Language-Team: Portuguese (Brazil) (https://www.transifex.com/oca/" +"teams/23907/pt_BR/)\n" +"Language: pt_BR\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: pt_BR\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/ro.po b/web_ir_actions_act_window_message/i18n/ro.po index 5f0f9ca7d..25cae0dd5 100644 --- a/web_ir_actions_act_window_message/i18n/ro.po +++ b/web_ir_actions_act_window_message/i18n/ro.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # Dorin Hongu , 2017 msgid "" @@ -12,11 +12,12 @@ msgstr "" "PO-Revision-Date: 2018-01-03 03:50+0000\n" "Last-Translator: Dorin Hongu , 2017\n" "Language-Team: Romanian (https://www.transifex.com/oca/teams/23907/ro/)\n" +"Language: ro\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: ro\n" -"Plural-Forms: nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?2:1));\n" +"Plural-Forms: nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?" +"2:1));\n" #. module: web_ir_actions_act_window_message #. openerp-web diff --git a/web_ir_actions_act_window_message/i18n/sl.po b/web_ir_actions_act_window_message/i18n/sl.po index 5725b8df4..85dfd671a 100644 --- a/web_ir_actions_act_window_message/i18n/sl.po +++ b/web_ir_actions_act_window_message/i18n/sl.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,11 +12,12 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: Slovenian (https://www.transifex.com/oca/teams/23907/sl/)\n" +"Language: sl\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: sl\n" -"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n%100==4 ? 2 : 3);\n" +"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n" +"%100==4 ? 2 : 3);\n" #. module: web_ir_actions_act_window_message #. openerp-web diff --git a/web_ir_actions_act_window_message/i18n/tr.po b/web_ir_actions_act_window_message/i18n/tr.po index 4f3a7178d..bdd84af6b 100644 --- a/web_ir_actions_act_window_message/i18n/tr.po +++ b/web_ir_actions_act_window_message/i18n/tr.po @@ -1,7 +1,7 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: # * web_ir_actions_act_window_message -# +# # Translators: # OCA Transbot , 2017 msgid "" @@ -12,10 +12,10 @@ msgstr "" "PO-Revision-Date: 2017-06-02 09:52+0000\n" "Last-Translator: OCA Transbot , 2017\n" "Language-Team: Turkish (https://www.transifex.com/oca/teams/23907/tr/)\n" +"Language: tr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Language: tr\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" #. module: web_ir_actions_act_window_message diff --git a/web_ir_actions_act_window_message/i18n/web_ir_actions_act_window_message.pot b/web_ir_actions_act_window_message/i18n/web_ir_actions_act_window_message.pot new file mode 100644 index 000000000..f878e4512 --- /dev/null +++ b/web_ir_actions_act_window_message/i18n/web_ir_actions_act_window_message.pot @@ -0,0 +1,22 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * web_ir_actions_act_window_message +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 10.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: <>\n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: web_ir_actions_act_window_message +#. openerp-web +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 +#, python-format +msgid "Close" +msgstr "" + From 7d957f87d3d989181d97b4db94aef524fc8c9cfe Mon Sep 17 00:00:00 2001 From: Abraham Anes Date: Thu, 21 Nov 2019 16:01:14 +0100 Subject: [PATCH 19/27] [12.0][MIG] web_ir_actions_act_window_message: Migration to 12.0 --- web_ir_actions_act_window_message/README.rst | 65 ++- .../__manifest__.py | 2 +- .../readme/CONTRIBUTORS.rst | 5 + .../readme/DESCRIPTION.rst | 1 + .../readme/ROADMAP.rst | 2 + .../readme/USAGE.rst | 44 ++ .../static/description/index.html | 456 ++++++++++++++++++ .../js/web_ir_actions_act_window_message.js | 35 +- 8 files changed, 584 insertions(+), 26 deletions(-) create mode 100644 web_ir_actions_act_window_message/readme/CONTRIBUTORS.rst create mode 100644 web_ir_actions_act_window_message/readme/DESCRIPTION.rst create mode 100644 web_ir_actions_act_window_message/readme/ROADMAP.rst create mode 100644 web_ir_actions_act_window_message/readme/USAGE.rst create mode 100644 web_ir_actions_act_window_message/static/description/index.html diff --git a/web_ir_actions_act_window_message/README.rst b/web_ir_actions_act_window_message/README.rst index 3772ad3e7..73d5c905e 100644 --- a/web_ir_actions_act_window_message/README.rst +++ b/web_ir_actions_act_window_message/README.rst @@ -1,8 +1,37 @@ +========================= Client side message boxes ========================= +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png + :target: https://odoo-community.org/page/development-status + :alt: Beta +.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 +.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fweb-lightgray.png?logo=github + :target: https://github.com/OCA/web/tree/12.0/web_ir_actions_act_window_message + :alt: OCA/web +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/web-12-0/web-12-0-web_ir_actions_act_window_message + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/162/12.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + This module allows to show a message popup on the client side as result of a button. +**Table of contents** + +.. contents:: + :local: + Usage ===== @@ -57,35 +86,47 @@ Known issues / Roadmap * add `message_type` to differenciate between warnings, errors, etc. * have one `message_type` to show a nonmodal warning on top right - Bug Tracker =========== Bugs are tracked on `GitHub Issues `_. In case of trouble, please check there if your issue has already been reported. -If you spotted it first, help us smashing it by providing a detailed and welcomed feedback -`here `_. +If you spotted it first, help us smashing it by providing a detailed and welcomed +`feedback `_. +Do not contact contributors directly about support or help with technical issues. Credits ======= +Authors +~~~~~~~ + +* Therp BV +* ACSONE SA/NV + Contributors ------------- +~~~~~~~~~~~~ * Holger Brunn * Zakaria Makrelouf (ACSONE SA/NV) * Benjamin Willig (ACSONE SA/NV) +* Ioan Galan (Studio73) +* Abraham Anes (Studio73) -Maintainer ----------- - -.. image:: http://odoo-community.org/logo.png - :alt: Odoo Community Association - :target: http://odoo-community.org +Maintainers +~~~~~~~~~~~ This module is maintained by the OCA. -OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use. +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org -To contribute to this module, please visit http://odoo-community.org. \ No newline at end of file +OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use. + +This module is part of the `OCA/web `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/web_ir_actions_act_window_message/__manifest__.py b/web_ir_actions_act_window_message/__manifest__.py index 5dd3b18b1..8b17eb02d 100644 --- a/web_ir_actions_act_window_message/__manifest__.py +++ b/web_ir_actions_act_window_message/__manifest__.py @@ -3,7 +3,7 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). { "name": "Client side message boxes", - "version": "10.0.1.0.0", + "version": "12.0.1.0.0", "author": "Therp BV, " "ACSONE SA/NV, " "Odoo Community Association (OCA)", diff --git a/web_ir_actions_act_window_message/readme/CONTRIBUTORS.rst b/web_ir_actions_act_window_message/readme/CONTRIBUTORS.rst new file mode 100644 index 000000000..7b22f2ca0 --- /dev/null +++ b/web_ir_actions_act_window_message/readme/CONTRIBUTORS.rst @@ -0,0 +1,5 @@ +* Holger Brunn +* Zakaria Makrelouf (ACSONE SA/NV) +* Benjamin Willig (ACSONE SA/NV) +* Ioan Galan (Studio73) +* Abraham Anes (Studio73) diff --git a/web_ir_actions_act_window_message/readme/DESCRIPTION.rst b/web_ir_actions_act_window_message/readme/DESCRIPTION.rst new file mode 100644 index 000000000..1223482e3 --- /dev/null +++ b/web_ir_actions_act_window_message/readme/DESCRIPTION.rst @@ -0,0 +1 @@ +This module allows to show a message popup on the client side as result of a button. diff --git a/web_ir_actions_act_window_message/readme/ROADMAP.rst b/web_ir_actions_act_window_message/readme/ROADMAP.rst new file mode 100644 index 000000000..1a49589d6 --- /dev/null +++ b/web_ir_actions_act_window_message/readme/ROADMAP.rst @@ -0,0 +1,2 @@ +* add `message_type` to differenciate between warnings, errors, etc. +* have one `message_type` to show a nonmodal warning on top right diff --git a/web_ir_actions_act_window_message/readme/USAGE.rst b/web_ir_actions_act_window_message/readme/USAGE.rst new file mode 100644 index 000000000..3f34ff7ce --- /dev/null +++ b/web_ir_actions_act_window_message/readme/USAGE.rst @@ -0,0 +1,44 @@ +Depend on this module and return + +.. code:: python + + { + 'type': 'ir.actions.act_window.message', + 'title': _('My title'), + 'message': _('My message'), + # optional title of the close button, if not set, will be _('Close') + # if set False, no close button will be shown + # you can create your own close button with an action of type + # ir.actions.act_window_close + 'close_button_title': 'Make this window go away', + # Use HTML instead of text + 'is_html_message': True, + # this is an optional list of buttons to show + 'buttons': [ + # a button can be any action (also ir.actions.report.xml et al) + { + 'type': 'ir.actions.act_window', + 'name': 'All customers', + 'res_model': 'res.partner', + 'view_mode': 'form', + 'views': [[False, 'list'], [False, 'form']], + 'domain': [('customer', '=', True)], + }, + # or if type == method, you need to pass a model, a method name and + # parameters + { + 'type': 'method', + 'name': _('Yes, do it'), + 'model': self._name, + 'method': 'myfunction', + # list of arguments to pass positionally + 'args': [self.ids], + # dictionary of keyword arguments + 'kwargs': {'force': True}, + # button style + 'classes': 'btn-primary', + } + ] + } + +You are responsible for translating the messages. diff --git a/web_ir_actions_act_window_message/static/description/index.html b/web_ir_actions_act_window_message/static/description/index.html new file mode 100644 index 000000000..5eb47701f --- /dev/null +++ b/web_ir_actions_act_window_message/static/description/index.html @@ -0,0 +1,456 @@ + + + + + + +Client side message boxes + + + +
+

Client side message boxes

+ + +

Beta License: AGPL-3 OCA/web Translate me on Weblate Try me on Runbot

+

This module allows to show a message popup on the client side as result of a button.

+

Table of contents

+ +
+

Usage

+

Depend on this module and return

+
+{
+    'type': 'ir.actions.act_window.message',
+    'title': _('My title'),
+    'message': _('My message'),
+    # optional title of the close button, if not set, will be _('Close')
+    # if set False, no close button will be shown
+    # you can create your own close button with an action of type
+    # ir.actions.act_window_close
+    'close_button_title': 'Make this window go away',
+    # Use HTML instead of text
+    'is_html_message': True,
+    # this is an optional list of buttons to show
+    'buttons': [
+        # a button can be any action (also ir.actions.report.xml et al)
+        {
+            'type': 'ir.actions.act_window',
+            'name': 'All customers',
+            'res_model': 'res.partner',
+            'view_mode': 'form',
+            'views': [[False, 'list'], [False, 'form']],
+            'domain': [('customer', '=', True)],
+        },
+        # or if type == method, you need to pass a model, a method name and
+        # parameters
+        {
+            'type': 'method',
+            'name': _('Yes, do it'),
+            'model': self._name,
+            'method': 'myfunction',
+            # list of arguments to pass positionally
+            'args': [self.ids],
+            # dictionary of keyword arguments
+            'kwargs': {'force': True},
+            # button style
+            'classes': 'btn-primary',
+        }
+    ]
+}
+
+

You are responsible for translating the messages.

+
+
+

Known issues / Roadmap

+
    +
  • add message_type to differenciate between warnings, errors, etc.
  • +
  • have one message_type to show a nonmodal warning on top right
  • +
+
+
+

Bug Tracker

+

Bugs are tracked on GitHub Issues. +In case of trouble, please check there if your issue has already been reported. +If you spotted it first, help us smashing it by providing a detailed and welcomed +feedback.

+

Do not contact contributors directly about support or help with technical issues.

+
+
+

Credits

+
+

Authors

+
    +
  • Therp BV
  • +
  • ACSONE SA/NV
  • +
+
+
+

Contributors

+ +
+
+

Maintainers

+

This module is maintained by the OCA.

+Odoo Community Association +

OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use.

+

This module is part of the OCA/web project on GitHub.

+

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

+
+
+
+ + diff --git a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js index 1b0708d71..1651a40d5 100644 --- a/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js +++ b/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js @@ -7,13 +7,18 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) var ActionManager = require('web.ActionManager'), core = require('web.core'), - Model = require('web.Model'), Dialog = require('web.Dialog'); var _t = core._t; ActionManager.include({ - ir_actions_act_window_message: function(action, options) + _handleAction: function (action, options) { + if (action.type === 'ir.actions.act_window.message') { + return this._executeWindowMessageAction(action, options); + } + return this._super.apply(this, arguments); + }, + _executeWindowMessageAction: function(action, options) { var self = this, buttons = []; @@ -24,8 +29,10 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) text: action.close_button_title || _t('Close'), click: function() { // refresh the view before closing the dialog - self.inner_widget.active_view - .controller.recursive_reload(); + var controller = self.getCurrentController(); + if (controller && controller.widget) { + controller.widget.reload(); + } dialog.close() }, classes: 'btn-default', @@ -62,7 +69,7 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) }, options) ) - return dialog.open(); + return dialog.open()._opened; }, ir_actions_act_window_message_get_buttons: function(action, close_func) { @@ -76,12 +83,12 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) click: function() { if(button_definition.type == 'method') { - (new Model(button_definition.model)) - .call( - button_definition.method, - button_definition.args, - button_definition.kwargs - ).then(function(result) + self._rpc({ + model: button_definition.model, + method: button_definition.method, + args: button_definition.args, + kwargs: button_definition.kwargs + }).then(function(result) { if(_.isObject(result)) { @@ -89,8 +96,10 @@ odoo.define('web.web_ir_actions_act_window_message', function(require) } // always refresh the view after the action // ex: action updates a status - self.inner_widget.active_view - .controller.recursive_reload(); + var controller = self.getCurrentController(); + if (controller && controller.widget) { + controller.widget.reload(); + } }); } else From 6fba438d657cdaaa5ba885eeae90cf07f3a53a1a Mon Sep 17 00:00:00 2001 From: oca-travis Date: Tue, 26 Nov 2019 16:54:22 +0000 Subject: [PATCH 20/27] [UPD] Update web_ir_actions_act_window_message.pot --- .../i18n/web_ir_actions_act_window_message.pot | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web_ir_actions_act_window_message/i18n/web_ir_actions_act_window_message.pot b/web_ir_actions_act_window_message/i18n/web_ir_actions_act_window_message.pot index f878e4512..4e9bada5a 100644 --- a/web_ir_actions_act_window_message/i18n/web_ir_actions_act_window_message.pot +++ b/web_ir_actions_act_window_message/i18n/web_ir_actions_act_window_message.pot @@ -4,7 +4,7 @@ # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 10.0\n" +"Project-Id-Version: Odoo Server 12.0\n" "Report-Msgid-Bugs-To: \n" "Last-Translator: <>\n" "Language-Team: \n" @@ -15,7 +15,7 @@ msgstr "" #. module: web_ir_actions_act_window_message #. openerp-web -#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:24 +#: code:addons/web_ir_actions_act_window_message/static/src/js/web_ir_actions_act_window_message.js:29 #, python-format msgid "Close" msgstr "" From 1ab53346bf1c3d74307a928fee7bdd688fa89fe4 Mon Sep 17 00:00:00 2001 From: OCA-git-bot Date: Tue, 26 Nov 2019 17:20:35 +0000 Subject: [PATCH 21/27] [UPD] README.rst --- .../static/description/index.html | 30 ++++++++++++++++--- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/web_ir_actions_act_window_message/static/description/index.html b/web_ir_actions_act_window_message/static/description/index.html index 5eb47701f..055573076 100644 --- a/web_ir_actions_act_window_message/static/description/index.html +++ b/web_ir_actions_act_window_message/static/description/index.html @@ -3,13 +3,13 @@ - + Client side message boxes