[MERGE] merged with main trunk
bzr revid: qdp-launchpad@openerp.com-20120301112946-ih5qecogkenkcxlc
This commit is contained in:
commit
32ec4eff11
|
@ -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 <EMAIL@ADDRESS>, 2012.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: openobject-addons\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\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 <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: Portuguese <pt@li.org>\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 ""
|
|
@ -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));
|
||||
|
|
|
@ -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 '<a href="#" target="_blank"><img src="/web_livechat/static/src/img/busy.png"/>Support</a>'
|
||||
|
||||
publisher_warranty_contract()
|
||||
|
||||
|
||||
|
|
|
@ -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: '<img src="/web_livechat/static/src/img/available.png"/>Support',
|
||||
offline: '<img src="/web_livechat/static/src/img/away.png"/>Support',
|
||||
online: '<img src="/web_livechat/static/src/img/available.png"/>',
|
||||
offline: '<img src="/web_livechat/static/src/img/away.png"/>',
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
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,
|
||||
|
|
|
@ -2,7 +2,9 @@
|
|||
<!-- vim:fdl=1:
|
||||
-->
|
||||
<templates id="template" xml:space="preserve">
|
||||
<t t-name="Header-LiveChat">
|
||||
<div class="livechat block logout"></div>
|
||||
</t>
|
||||
<t t-name="Systray.LiveChat">
|
||||
<div class="oe_systray_livechat" title="Support">
|
||||
<a href="#"><img src="/web_livechat/static/src/img/busy.png"/></a>
|
||||
</div>
|
||||
</t>
|
||||
</templates>
|
||||
|
|
|
@ -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",
|
||||
],
|
||||
|
|
|
@ -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;
|
||||
}
|
|
@ -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";
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<!-- vim:fdl=1:
|
||||
-->
|
||||
<templates id="template" xml:space="preserve">
|
||||
<t t-name="Header-UserVoice">
|
||||
<div class="block logout feedback"><a href="#"><img src="/web_uservoice/static/src/img/uv_favicon.png" />feedback</a></div>
|
||||
</t>
|
||||
<t t-name="Systray.UserVoice">
|
||||
<div class="oe_systray_uservoice" title="Feedback"><a href="#"><img src="/web_uservoice/static/src/img/uv_favicon.png"/></a></div>
|
||||
</t>
|
||||
</templates>
|
||||
|
|
Loading…
Reference in New Issue