Skip to content
Open
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
2 changes: 1 addition & 1 deletion contract_refund_on_stop/models/contract_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ def stop(self, date_end, manual_renew_needed=False, post_message=True):
to_refund_start_date=date_end,
to_refund_end_date=rec.last_date_invoiced,
)
rec.last_date_invoiced = date_end
return super().stop(
date_end, manual_renew_needed=manual_renew_needed, post_message=post_message
)
Expand All @@ -31,6 +30,7 @@ def _create_refund_on_stop(self, to_refund_start_date, to_refund_end_date):
self.env["account.move"].create(
self._prepare_refund_on_stop_vals(to_refund_start_date, to_refund_end_date)
)
self.last_date_invoiced = to_refund_start_date

def _prepare_refund_on_stop_vals(self, to_refund_start_date, to_refund_end_date):
self.ensure_one()
Expand Down
Loading