Skip to content

Report date range incorrect #3239

@vitis586

Description

@vitis586

Akaunting version

3.1.12

PHP version

Cloud Trial

Operating system

Cloud Trial

Steps to reproduce

  1. Start company, go to reports
  2. Go to any report
  3. Delete date range from the filters
  4. Add Date range = Previous year
  5. Delete range again
  6. Add Date range = This year

Expected result

  1. I would expect that the This year shows always 2024
  2. I would expect that the Previous year shows always 2023 - but I might be mistaken in this one
  3. I would expect that selecting This year again takes me back to 2024

Actual result

  1. Result when the report is first opened
    obrazek
  2. Switch to last year - notice that the Date Range filter still says This year but the URL parameters are correct, so the data are correct
    obrazek
  3. Selected Previous year again - Date Range still says This year but the URL parameters went to 2022 - to the previous year from the previously selected
    obrazek
  4. Selected This year - does nothing, URL still says 2022 - nothing has changes
    obrazek

Additional comments

I noticed that the URL query parameters are sometimes not separated by & but just by (whitespace) or both. - example below

common/reports/2135880?search=basis:accrual period:monthly &start_date=2023-01-01&end_date=2023-12-31

When selecting which accounts to omit the parameter has space in it. This sometimes led me to just zero in the report, although there should have been some transactions accounted for.

common/reports/2?search=basis:accrual period:monthly not account_id:2,3,4

Shouldn't these be URL encoded?

Might be connected to #3230

Relevant log output

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions