From 7dd2d201a00fa08ae79f4dfe67be95454eab9c8e Mon Sep 17 00:00:00 2001 From: Martin Trigaux Date: Tue, 5 May 2015 10:17:51 +0200 Subject: [PATCH 1/3] [FIX] web: localisation for Lao and Bosnian The datejs globalisation files are loaded based on the user's language. If the file is not present, the loading crashed and the user could not access to the web client. Adding empty files for lo_LA and renaming bs-BS.js to bs-BA.js for bs_BA (see 65d92da) that were missing. By the way, this is a 0 bit commit, beat that! --- addons/web/static/lib/datejs/globalization/{bs-BS.js => bs-BA.js} | 0 addons/web/static/lib/datejs/globalization/lo-LA.js | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename addons/web/static/lib/datejs/globalization/{bs-BS.js => bs-BA.js} (100%) create mode 100644 addons/web/static/lib/datejs/globalization/lo-LA.js diff --git a/addons/web/static/lib/datejs/globalization/bs-BS.js b/addons/web/static/lib/datejs/globalization/bs-BA.js similarity index 100% rename from addons/web/static/lib/datejs/globalization/bs-BS.js rename to addons/web/static/lib/datejs/globalization/bs-BA.js diff --git a/addons/web/static/lib/datejs/globalization/lo-LA.js b/addons/web/static/lib/datejs/globalization/lo-LA.js new file mode 100644 index 00000000000..e69de29bb2d From 8e6f9be08ff0ab4fcc68df2364300b12a3387313 Mon Sep 17 00:00:00 2001 From: Julien Legros Date: Tue, 5 May 2015 11:29:15 +0200 Subject: [PATCH 2/3] [CHG] web: odoo.com account fallback url The default odoo.com account page is now located at https://accounts.odoo.com/account. --- addons/web/static/src/js/chrome.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index d0f14a63804..c28b9de651a 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -1161,7 +1161,7 @@ instance.web.UserMenu = instance.web.Widget.extend({ instance.web.redirect('https://accounts.odoo.com/oauth2/auth?'+$.param(params)); }).fail(function(result, ev){ ev.preventDefault(); - instance.web.redirect('https://accounts.odoo.com/web'); + instance.web.redirect('https://accounts.odoo.com/account'); }); } }, From 567ade56df66e1726a98177d9bec63f3f7b6cacc Mon Sep 17 00:00:00 2001 From: Denis Ledoux Date: Tue, 5 May 2015 17:47:30 +0200 Subject: [PATCH 3/3] [FIX] account: import invoices wizard currency amount Within the 'import invoices' wizard in bank statements (addons/account/wizard/account_statement_from_invoice.py) Prevent currency rate differences when the statement currency is within the company currency (and therefore the debit/credit fields are already within the currency of the statement) opw-631895 Closes #6504 --- .../wizard/account_statement_from_invoice.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/addons/account_voucher/wizard/account_statement_from_invoice.py b/addons/account_voucher/wizard/account_statement_from_invoice.py index 41d3560e278..362cb516e7c 100644 --- a/addons/account_voucher/wizard/account_statement_from_invoice.py +++ b/addons/account_voucher/wizard/account_statement_from_invoice.py @@ -68,8 +68,12 @@ class account_statement_from_invoice_lines(osv.osv_memory): amount = -line.credit if line.amount_currency: - amount = currency_obj.compute(cr, uid, line.currency_id.id, - statement.currency.id, line.amount_currency, context=ctx) + if line.company_id.currency_id.id != statement.currency.id: + # In the specific case where the company currency and the statement currency are the same + # the debit/credit field already contains the amount in the right currency. + # We therefore avoid to re-convert the amount in the currency, to prevent Gain/loss exchanges + amount = currency_obj.compute(cr, uid, line.currency_id.id, + statement.currency.id, line.amount_currency, context=ctx) elif (line.invoice and line.invoice.currency_id.id <> statement.currency.id): amount = currency_obj.compute(cr, uid, line.invoice.currency_id.id, statement.currency.id, amount, context=ctx)