diff options
| author | Denis Ledoux <dle@odoo.com> | 2015-05-05 17:55:25 +0200 |
|---|---|---|
| committer | Denis Ledoux <dle@odoo.com> | 2015-05-05 17:55:25 +0200 |
| commit | a939a272efa7cdd047e79a0a6da361e94ca93d4f (patch) | |
| tree | fae02e8a090e8acf30d6e09e4e6e38016d4c8fee | |
| parent | 0c665edb66098d95a407a0d2be9351bbea81b2db (diff) | |
| parent | ae634e7a045b0a9e53be021b3f9ec9e22429f850 (diff) | |
[MERGE] forward port of branch saas-3 up to ae634e7
| -rw-r--r-- | addons/account/wizard/account_statement_from_invoice.py | 8 | ||||
| -rw-r--r-- | addons/web/static/lib/datejs/globalization/bs-BA.js (renamed from addons/web/static/lib/datejs/globalization/bs-BS.js) | 0 | ||||
| -rw-r--r-- | addons/web/static/lib/datejs/globalization/lo-LA.js | 0 | ||||
| -rw-r--r-- | addons/web/static/src/js/chrome.js | 2 |
4 files changed, 7 insertions, 3 deletions
diff --git a/addons/account/wizard/account_statement_from_invoice.py b/addons/account/wizard/account_statement_from_invoice.py index fd1b5790bf8..65657f33787 100644 --- a/addons/account/wizard/account_statement_from_invoice.py +++ b/addons/account/wizard/account_statement_from_invoice.py @@ -63,8 +63,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) diff --git a/addons/web/static/lib/datejs/globalization/bs-BS.js b/addons/web/static/lib/datejs/globalization/bs-BA.js index e69de29bb2d..e69de29bb2d 100644 --- a/addons/web/static/lib/datejs/globalization/bs-BS.js +++ b/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 --- /dev/null +++ b/addons/web/static/lib/datejs/globalization/lo-LA.js diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index a5a6df17fcf..0a35bfd1244 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -1078,7 +1078,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'); }); } }, |
