Merge lp:~julie-w/unifield-server/US-5663 into lp:unifield-server

Proposed by jftempo
Status: Merged
Merged at revision: 5319
Proposed branch: lp:~julie-w/unifield-server/US-5663
Merge into: lp:unifield-server
Diff against target: 17 lines (+6/-1)
1 file modified
bin/addons/res_currency_functional/account_move_line_compute_currency.py (+6/-1)
To merge this branch: bzr merge lp:~julie-w/unifield-server/US-5663
Reviewer Review Type Date Requested Status
UniField Reviewer Team Pending
Review via email: mp+366898@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'bin/addons/res_currency_functional/account_move_line_compute_currency.py'
--- bin/addons/res_currency_functional/account_move_line_compute_currency.py 2019-01-09 17:26:04 +0000
+++ bin/addons/res_currency_functional/account_move_line_compute_currency.py 2019-05-03 09:52:06 +0000
@@ -576,7 +576,12 @@
576# if ctxcurr.get('date', False):576# if ctxcurr.get('date', False):
577# newvals['date'] = ctxcurr['date']577# newvals['date'] = ctxcurr['date']
578578
579 if vals.get('credit_currency') or vals.get('debit_currency'):579 if context.get('from_web_menu') and (vals.get('debit_currency', False) is not False or vals.get('credit_currency', False) is not False):
580 # use case where one of the booking fields MANUALLY CHANGED IN THE INTERFACE has a value, EVEN IF IT IS 0.00
581 newvals['amount_currency'] = vals.get('debit_currency') or 0.0 - vals.get('credit_currency') or 0.0
582 newvals['debit'] = cur_obj.compute(cr, uid, currency_id, curr_fun, vals.get('debit_currency') or 0.0, round=True, context=ctxcurr)
583 newvals['credit'] = cur_obj.compute(cr, uid, currency_id, curr_fun, vals.get('credit_currency') or 0.0, round=True, context=ctxcurr)
584 elif vals.get('credit_currency') or vals.get('debit_currency'):
580 newvals['amount_currency'] = vals.get('debit_currency') or 0.0 - vals.get('credit_currency') or 0.0585 newvals['amount_currency'] = vals.get('debit_currency') or 0.0 - vals.get('credit_currency') or 0.0
581 newvals['debit'] = cur_obj.compute(cr, uid, currency_id, curr_fun, vals.get('debit_currency') or 0.0, round=True, context=ctxcurr)586 newvals['debit'] = cur_obj.compute(cr, uid, currency_id, curr_fun, vals.get('debit_currency') or 0.0, round=True, context=ctxcurr)
582 newvals['credit'] = cur_obj.compute(cr, uid, currency_id, curr_fun, vals.get('credit_currency') or 0.0, round=True, context=ctxcurr)587 newvals['credit'] = cur_obj.compute(cr, uid, currency_id, curr_fun, vals.get('credit_currency') or 0.0, round=True, context=ctxcurr)

Subscribers

People subscribed via source and target branches