diff --git a/addons/fetchmail_hr_recruitment/i18n/pt.po b/addons/fetchmail_hr_recruitment/i18n/pt.po new file mode 100644 index 00000000000..c1256badb11 --- /dev/null +++ b/addons/fetchmail_hr_recruitment/i18n/pt.po @@ -0,0 +1,32 @@ +# Portuguese translation for openobject-addons +# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012 +# This file is distributed under the same license as the openobject-addons package. +# FIRST AUTHOR , 2012. +# +msgid "" +msgstr "" +"Project-Id-Version: openobject-addons\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2012-02-08 00:36+0000\n" +"PO-Revision-Date: 2012-02-29 22:48+0000\n" +"Last-Translator: FULL NAME \n" +"Language-Team: Portuguese \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2012-03-01 04:46+0000\n" +"X-Generator: Launchpad (build 14874)\n" + +#. module: fetchmail_hr_recruitment +#: model:ir.actions.act_window,help:fetchmail_hr_recruitment.action_link_applicant_to_email_account +msgid "" +"You can synchronize the job email account (e.g. job@yourcompany.com) with " +"OpenERP so that new applicants are created automatically in OpenERP for the " +"followup of the recruitment process. Attachments are automatically stored in " +"the DMS of OpenERP so that you get an indexation of all the CVs received." +msgstr "" + +#. module: fetchmail_hr_recruitment +#: model:ir.actions.act_window,name:fetchmail_hr_recruitment.action_link_applicant_to_email_account +msgid "Create Applicants from Email Account" +msgstr "" diff --git a/addons/point_of_sale/static/src/js/pos.js b/addons/point_of_sale/static/src/js/pos.js index c713389ac71..1885604d42c 100644 --- a/addons/point_of_sale/static/src/js/pos.js +++ b/addons/point_of_sale/static/src/js/pos.js @@ -681,7 +681,7 @@ openerp.point_of_sale = function(db) { }, this)); return (this.shop.get('selectedOrder')).addPaymentLine(cashRegister); }, - render_element: function() { + renderElement: function() { this.$element.empty(); return (this.shop.get('cashRegisters')).each(_.bind( function(cashRegister) { var button = new PaymentButtonWidget(); @@ -692,7 +692,7 @@ openerp.point_of_sale = function(db) { }); var PaymentButtonWidget = db.web.OldWidget.extend({ template_fct: qweb_template('pos-payment-button-template'), - render_element: function() { + renderElement: function() { this.$element.html(this.template_fct({ id: this.model.get('id'), name: (this.model.get('journal_id'))[1] @@ -735,7 +735,7 @@ openerp.point_of_sale = function(db) { Shopping carts. */ var OrderlineWidget = db.web.OldWidget.extend({ - tag_name: 'tr', + tagName: 'tr', template_fct: qweb_template('pos-orderline-template'), init: function(parent, options) { this._super(parent); @@ -755,12 +755,12 @@ openerp.point_of_sale = function(db) { clickHandler: function() { this.select(); }, - render_element: function() { + renderElement: function() { this.$element.html(this.template_fct(this.model.toJSON())); this.select(); }, refresh: function() { - this.render_element(); + this.renderElement(); var heights = _.map(this.$element.prevAll(), function(el) {return $(el).outerHeight();}); heights.push($('#current-order thead').outerHeight()); var position = _.reduce(heights, function(memo, num){ return memo + num; }, 0); @@ -805,12 +805,12 @@ openerp.point_of_sale = function(db) { changeSelectedOrder: function() { this.currentOrderLines.unbind(); this.bindOrderLineEvents(); - this.render_element(); + this.renderElement(); }, bindOrderLineEvents: function() { this.currentOrderLines = (this.shop.get('selectedOrder')).get('orderLines'); this.currentOrderLines.bind('add', this.addLine, this); - this.currentOrderLines.bind('remove', this.render_element, this); + this.currentOrderLines.bind('remove', this.renderElement, this); }, addLine: function(newLine) { var line = new OrderlineWidget(null, { @@ -832,7 +832,7 @@ openerp.point_of_sale = function(db) { this.numpadState.reset(); this.updateSummary(); }, - render_element: function() { + renderElement: function() { this.$element.empty(); this.currentOrderLines.each(_.bind( function(orderLine) { var line = new OrderlineWidget(null, { @@ -863,7 +863,7 @@ openerp.point_of_sale = function(db) { this.$element.find(".oe-pos-categories-list a").click(_.bind(this.changeCategory, this)); }, template_fct: qweb_template('pos-category-template'), - render_element: function() { + renderElement: function() { var self = this; var c; this.$element.html(this.template_fct({ @@ -894,7 +894,7 @@ openerp.point_of_sale = function(db) { on_change_category: function(id) {}, }); var ProductWidget = db.web.OldWidget.extend({ - tag_name:'li', + tagName:'li', template_fct: qweb_template('pos-product-template'), init: function(parent, options) { this._super(parent); @@ -909,7 +909,7 @@ openerp.point_of_sale = function(db) { event.preventDefault(); return (this.shop.get('selectedOrder')).addProduct(this.model); }, - render_element: function() { + renderElement: function() { this.$element.addClass("product"); this.$element.html(this.template_fct(this.model.toJSON())); return this; @@ -920,9 +920,9 @@ openerp.point_of_sale = function(db) { this._super(parent); this.model = options.model; this.shop = options.shop; - this.shop.get('products').bind('reset', this.render_element, this); + this.shop.get('products').bind('reset', this.renderElement, this); }, - render_element: function() { + renderElement: function() { this.$element.empty(); (this.shop.get('products')).each(_.bind( function(product) { var p = new ProductWidget(null, { @@ -938,7 +938,7 @@ openerp.point_of_sale = function(db) { "Payment" step. */ var PaymentlineWidget = db.web.OldWidget.extend({ - tag_name: 'tr', + tagName: 'tr', template_fct: qweb_template('pos-paymentline-template'), init: function(parent, options) { this._super(parent); @@ -958,9 +958,9 @@ openerp.point_of_sale = function(db) { }, changedAmount: function() { if (this.amount !== this.model.get('amount')) - this.render_element(); + this.renderElement(); }, - render_element: function() { + renderElement: function() { this.amount = this.model.get('amount'); this.$element.html(this.template_fct({ name: (this.model.get('journal_id'))[1], @@ -1004,7 +1004,7 @@ openerp.point_of_sale = function(db) { bindPaymentLineEvents: function() { this.currentPaymentLines = (this.shop.get('selectedOrder')).get('paymentLines'); this.currentPaymentLines.bind('add', this.addPaymentLine, this); - this.currentPaymentLines.bind('remove', this.render_element, this); + this.currentPaymentLines.bind('remove', this.renderElement, this); this.currentPaymentLines.bind('all', this.updatePaymentSummary, this); }, bindOrderLineEvents: function() { @@ -1016,7 +1016,7 @@ openerp.point_of_sale = function(db) { this.bindPaymentLineEvents(); this.currentOrderLines.unbind(); this.bindOrderLineEvents(); - this.render_element(); + this.renderElement(); }, addPaymentLine: function(newPaymentLine) { var x = new PaymentlineWidget(null, { @@ -1025,7 +1025,7 @@ openerp.point_of_sale = function(db) { x.on_delete.add(_.bind(this.deleteLine, this, x)); x.appendTo(this.paymentLineList()); }, - render_element: function() { + renderElement: function() { this.paymentLineList().empty(); this.currentPaymentLines.each(_.bind( function(paymentLine) { this.addPaymentLine(paymentLine); @@ -1079,7 +1079,7 @@ openerp.point_of_sale = function(db) { this.shop.bind('change:selectedOrder', this.changeSelectedOrder, this); this.changeSelectedOrder(); }, - render_element: function() { + renderElement: function() { this.$element.html(qweb_template('pos-receipt-view')); $('button#pos-finish-order', this.$element).click(_.bind(this.finishOrder, this)); $('button#print-the-ticket', this.$element).click(_.bind(this.print, this)); @@ -1109,7 +1109,7 @@ openerp.point_of_sale = function(db) { }, }); var OrderButtonWidget = db.web.OldWidget.extend({ - tag_name: 'li', + tagName: 'li', template_fct: qweb_template('pos-order-selector-button-template'), init: function(parent, options) { this._super(parent); @@ -1142,7 +1142,7 @@ openerp.point_of_sale = function(db) { closeOrder: function(event) { this.order.destroy(); }, - render_element: function() { + renderElement: function() { this.$element.html(this.template_fct({widget:this})); this.$element.addClass('order-selector-button'); } @@ -1161,13 +1161,13 @@ openerp.point_of_sale = function(db) { shop: this.shop }); this.productListView.$element = $("#products-screen-ol"); - this.productListView.render_element(); + this.productListView.renderElement(); this.productListView.start(); this.paypadView = new PaypadWidget(null, { shop: this.shop }); this.paypadView.$element = $('#paypad'); - this.paypadView.render_element(); + this.paypadView.renderElement(); this.paypadView.start(); this.numpadView = new NumpadWidget(null); this.numpadView.$element = $('#numpad'); @@ -1181,7 +1181,7 @@ openerp.point_of_sale = function(db) { shop: this.shop }); this.paymentView.$element = $('#payment-screen'); - this.paymentView.render_element(); + this.paymentView.renderElement(); this.paymentView.start(); this.receiptView = new ReceiptWidget(null, { shop: this.shop, @@ -1251,7 +1251,7 @@ openerp.point_of_sale = function(db) { c = pos.categories[id]; this.categoryView.ancestors = c.ancestors; this.categoryView.children = c.children; - this.categoryView.render_element(); + this.categoryView.renderElement(); this.categoryView.start(); products = pos.store.get('product.product').filter( function(p) { var _ref; @@ -1288,13 +1288,13 @@ openerp.point_of_sale = function(db) { this._super.apply(this, arguments); this.nbr_pending = 0; }, - render_element: function() { + renderElement: function() { this._super.apply(this, arguments); $('.oe_pos_synch-notification-button', this.$element).click(this.on_synch); }, on_change_nbr_pending: function(nbr_pending) { this.nbr_pending = nbr_pending; - this.render_element(); + this.renderElement(); }, on_synch: function() {} }); @@ -1312,7 +1312,7 @@ openerp.point_of_sale = function(db) { start: function() { var self = this; return pos.ready.then(_.bind(function() { - this.render_element(); + this.renderElement(); this.synch_notification = new db.point_of_sale.SynchNotification(this); this.synch_notification.replace($('.oe_pos_synch-notification', this.$element)); this.synch_notification.on_synch.add(_.bind(pos.flush, pos)); diff --git a/addons/web_livechat/publisher_warranty.py b/addons/web_livechat/publisher_warranty.py index a3b59811ff8..0328e4181a7 100644 --- a/addons/web_livechat/publisher_warranty.py +++ b/addons/web_livechat/publisher_warranty.py @@ -42,10 +42,6 @@ class publisher_warranty_contract(osv.osv): domain = [('state', '=', 'valid'), ('check_support', '=', True)] return self.search_count(cr, uid, domain) != 0 - @cache(skiparg=3) - def get_default_livechat_text(self, cr, uid): - return 'Support' - publisher_warranty_contract() diff --git a/addons/web_livechat/static/src/js/web_livechat.js b/addons/web_livechat/static/src/js/web_livechat.js index 4ddc93e3e6e..540af94310f 100644 --- a/addons/web_livechat/static/src/js/web_livechat.js +++ b/addons/web_livechat/static/src/js/web_livechat.js @@ -22,8 +22,8 @@ var __lc_buttons = []; openerp.web_livechat = function (openerp) { -openerp.web_livechat.Livechat = openerp.web.OldWidget.extend({ - template: 'Header-LiveChat', +openerp.web_livechat.Livechat = openerp.web.Widget.extend({ + template: 'Systray.LiveChat', start: function() { this._super(); @@ -31,26 +31,25 @@ openerp.web_livechat.Livechat = openerp.web.OldWidget.extend({ return; var self = this; var pwc = new openerp.web.Model("publisher_warranty.contract"); - return pwc.get_func('get_default_livechat_text')().then(function(text) { - self.$element.html(text); - pwc.get_func('is_livechat_enable')().then(function(res) { - if(res) { - self.$element.click(self.do_load_livechat); - } else { - self.$element.click(self.do_open_url); - } - }) + pwc.get_func('is_livechat_enable')().then(function(res) { + if(res) { + self.$element.click(self.do_load_livechat); + } else { + self.$element.click(self.do_open_url); + } }); }, do_open_url: function(evt) { - evt.preventDefault(); + evt.preventDefault(); openerp.webclient.action_manager.do_action({type: 'ir.actions.act.url', url: 'http://www.openerp.com/support-or-publisher-warranty-contract', target: 'new'}); }, do_load_livechat: function(evt) { - evt.preventDefault(); var self = this; + if (evt) { + evt.preventDefault(); + } this.$element.unbind('click', this.do_load_livechat); @@ -58,9 +57,8 @@ openerp.web_livechat.Livechat = openerp.web.OldWidget.extend({ this.$element.attr('id', lc_id); var pwc = new openerp.web.Model("publisher_warranty.contract"); - + pwc.get_func('is_livechat_enable')().then(function(res) { - console.log('res', res); if(!res) { return; } @@ -74,39 +72,35 @@ openerp.web_livechat.Livechat = openerp.web.OldWidget.extend({ skill: '2', type: 'text', labels: { - online: 'Support', - offline: 'Support', + online: '', + offline: '', } }); }); } }); - -openerp.web.Header.include({ +openerp.web.UserMenu.include({ do_update: function() { var self = this; - this._super(); + this._super.apply(this, arguments); this.update_promise.then(function() { if (self.livechat) { self.livechat.destroy(); } self.livechat = new openerp.web_livechat.Livechat(self); - self.livechat.prependTo(self.$element.find('div.header_corner')); + self.livechat.appendTo(openerp.webclient.$element.find('.oe_systray')); }); } }); - - - if (openerp.webclient) { // tracking code from LiveChat var license = '1035052', params = '', lang = 'en', skill = '0'; - __lc_load = function (p) { + __lc_load = function (p) { if (typeof __lc_loaded != 'function') if (p) { var d = document, diff --git a/addons/web_livechat/static/src/xml/web_livechat.xml b/addons/web_livechat/static/src/xml/web_livechat.xml index b5e2db515b0..0f1bf073bc2 100644 --- a/addons/web_livechat/static/src/xml/web_livechat.xml +++ b/addons/web_livechat/static/src/xml/web_livechat.xml @@ -2,7 +2,9 @@ - -
-
+ +
+ +
+
diff --git a/addons/web_uservoice/__openerp__.py b/addons/web_uservoice/__openerp__.py index 971401dc3c9..8385b97ccaf 100644 --- a/addons/web_uservoice/__openerp__.py +++ b/addons/web_uservoice/__openerp__.py @@ -38,7 +38,6 @@ Invite OpenERP user feedback, powered by uservoice. 'certificate': '0040452504963885', 'js': ['static/src/js/web_uservoice.js'], - 'css': ['static/src/css/uservoice.css'], 'qweb' : [ "static/src/xml/*.xml", ], diff --git a/addons/web_uservoice/static/src/css/uservoice.css b/addons/web_uservoice/static/src/css/uservoice.css deleted file mode 100644 index 665ccee7f6e..00000000000 --- a/addons/web_uservoice/static/src/css/uservoice.css +++ /dev/null @@ -1,7 +0,0 @@ -div.header_corner div.feedback a { - /*color: #9a0404;*/ -} -div.header_corner div.feedback img { - vertical-align: middle; - margin-right: 0.5em; -} diff --git a/addons/web_uservoice/static/src/js/web_uservoice.js b/addons/web_uservoice/static/src/js/web_uservoice.js index 4871fb80c9d..3daa91beb82 100644 --- a/addons/web_uservoice/static/src/js/web_uservoice.js +++ b/addons/web_uservoice/static/src/js/web_uservoice.js @@ -1,8 +1,7 @@ - openerp.web_uservoice = function(instance) { -instance.web_uservoice.UserVoice = instance.web.OldWidget.extend({ - template: 'Header-UserVoice', +instance.web_uservoice.UserVoice = instance.web.Widget.extend({ + template: 'Systray.UserVoice', default_forum: '77459', init: function() { @@ -16,7 +15,12 @@ instance.web_uservoice.UserVoice = instance.web.OldWidget.extend({ showTab: false }; - instance.webclient.menu.do_menu_click.add_first(this.do_menu_click); + instance.webclient.menu.on('menuClicked', this, function(id, $clicked_menu) { + var root = $clicked_menu.parents('div.oe_menu').length === 1; + if (id && root) { + this.uservoiceOptions.forum = this.uservoiceForums[id] || this.default_forum; + } + }); }, start: function() { @@ -45,27 +49,16 @@ instance.web_uservoice.UserVoice = instance.web.OldWidget.extend({ self.uservoiceForums[menu.id] = forum_mapping[menu.name.toLowerCase()] || self.default_forum; }); }); - + this.$element.find('a').click(function(e) { e.preventDefault(); UserVoice.Popin.show(self.uservoiceOptions); return false; - }); - }, - - - do_menu_click: function($clicked_menu, manual) { - var id = $clicked_menu.attr('data-menu'), - root = $clicked_menu.parents('div.menu').length === 1; - if (id && root) { - this.uservoiceOptions.forum = this.uservoiceForums[id] || this.default_forum; - } - }, - + }).tipsy(); + } }); - -instance.web.Header.include({ +instance.web.UserMenu.include({ do_update: function() { var self = this; this._super(); @@ -74,12 +67,11 @@ instance.web.Header.include({ self.uservoice.destroy(); } self.uservoice = new instance.web_uservoice.UserVoice(self); - self.uservoice.prependTo(self.$element.find('div.header_corner')); + self.uservoice.appendTo(instance.webclient.$element.find('.oe_systray')); }); } }); - if (instance.webclient) { $(function() { var src = ("https:" == document.location.protocol ? "https://" : "http://") + "cdn.uservoice.com/javascripts/widgets/tab.js"; diff --git a/addons/web_uservoice/static/src/xml/web_uservoice.xml b/addons/web_uservoice/static/src/xml/web_uservoice.xml index e37ed2c17d3..f9b7040ec64 100644 --- a/addons/web_uservoice/static/src/xml/web_uservoice.xml +++ b/addons/web_uservoice/static/src/xml/web_uservoice.xml @@ -2,7 +2,7 @@ - - - + +
+