Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[15.0][FIX] hr_expense: set exclude_from_invoice_tab on destination move line #4386

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,15 @@ def _fill_payment_state(env):
WHERE account_move_id IS NULL
""",
)
# set exclude_from_invoice_tab the way v15 does it
openupgrade.logged_query(
env.cr,
"""
UPDATE account_move_line
SET exclude_from_invoice_tab=(coalesce(quantity, 0) = 0)
WHERE expense_id IS NOT NULL
""",
)
# Recompute payment_state for the moves associated to the expenses, as on
# v14 these ones were not computed being of type `entry`, which changes now
# on v15 if the method `_payment_state_matters` returns True, which is the
Expand Down
Loading