Skip to content

Payment Terms calculation issue with Month option  #919

@VBNext

Description

@VBNext

Module

payment_terms_extension

Describe the bug

When a payment term is set to “Months after end of month”, the due date is incorrectly calculated based on the day number of the invoice date’s month, instead of the actual end of the target month.

To Reproduce

Affected versions:

Steps to reproduce the behavior:

  1. Configure a payment term with 1 Month after end of month.
Image
  1. Set Example date with a date in a month that has fewer days (e.g. February with 28 days).

Expected behavior
The due date should be set to the end of the following month, for example 03/31/2025, and not 03/28/2025

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions