Skip to content

Dashboard - "This Year" wrong #3249

@AndrePerestrelo

Description

@AndrePerestrelo

Akaunting version

3.1.14

PHP version

8.1

Operating system

Linux

Steps to reproduce

  1. Navigate to Settings > Localisation
  2. Set Financial Year Start to "1 October"
  3. Set Financial Year Denote to "By the year in which it begins"
  4. Click Save
  5. Open the dashboard

Expected result

When the Dashboard opens it defaults to the This Year period.

The expectation is the period should be 1 October 2024 - 30 September 2025.

Actual result

When the Dashboard opens it defaults to the This Year period.

The actual period is being shown is 1 October 2025 - 30 September 2025.

Additional comments

When the Dashboard opens it defaults to the This Year period.

The expectation is the period should be 1 October 2024 - 30 September 2025 except the dashboard interprets This Year as 1 October 2025 - 30 September 2025.

The expectation is that if the current day (in this case 8 January 2025) falls within a period that is considered the current period - ie. 08 Jan 2025 is between (inclusively) 1 October 2024 - 30 September 2025 and therefore the current period aka "This Year" should be 1 October 2024 - 30 September 2024.

What is actually happening is the code is possibly doing something along the lines of:

  1. The current year is 2025
  2. The Financial Year Start is 1 October
  3. Make a date of 1 October 2025 and set that as the start of the This Year period.

Relevant log output

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions