Merge lp:~mukunde/unifield-server/US-7852 into lp:unifield-server

Proposed by jftempo
Status: Merged
Merged at revision: 6321
Proposed branch: lp:~mukunde/unifield-server/US-7852
Merge into: lp:unifield-server
Diff against target: 17 lines (+5/-2)
1 file modified
bin/addons/register_accounting/account_analytic_line.py (+5/-2)
To merge this branch: bzr merge lp:~mukunde/unifield-server/US-7852
Reviewer Review Type Date Requested Status
UniField Reviewer Team Pending
Review via email: mp+429844@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
1=== modified file 'bin/addons/register_accounting/account_analytic_line.py'
2--- bin/addons/register_accounting/account_analytic_line.py 2017-10-02 15:51:29 +0000
3+++ bin/addons/register_accounting/account_analytic_line.py 2022-09-13 15:34:53 +0000
4@@ -45,8 +45,11 @@
5 else:
6 res[l.id] = False
7 if l.move_id:
8- if l.move_id.partner_type and l.move_id.partner_type.name:
9- res[l.id] = l.move_id.partner_type.name or False
10+ if l.move_id.partner_type:
11+ if l.move_id.partner_type._table_name != 'account.journal' and l.move_id.partner_type.name:
12+ res[l.id] = l.move_id.partner_type.name or False
13+ elif l.move_id.partner_type._table_name == 'account.journal' and l.move_id.partner_type.code:
14+ res[l.id] = l.move_id.partner_type.code or False
15 # UTP-1106: In case of HQ Entries, we don't have any "real 3RD party", but just a partner_txt. That's why we use it as it is!
16 else:
17 res[l.id] = l.move_id.partner_txt or False

Subscribers

People subscribed via source and target branches