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

(bug) Ensure all report date delimiters exactly respect dates #1274

Open
sfount opened this issue Feb 27, 2017 · 1 comment
Open

(bug) Ensure all report date delimiters exactly respect dates #1274

sfount opened this issue Feb 27, 2017 · 1 comment

Comments

@sfount
Copy link
Contributor

sfount commented Feb 27, 2017

Currently our reports allow very flexible from and to date configuration however it has been reported that often they include data from dates outside of the range. This often happens because of timezones and 00:00 being represented at 23:00 etc.

We should write a series of tests to ensure that all of our reports represent only the data for the period they have been selected for.

@sfount sfount added the Bug label Feb 27, 2017
@jniles
Copy link
Collaborator

jniles commented Feb 27, 2017

For the most part, I think these bugs can be avoided by passing all dates that come from the client through new Date() before giving them to the database. This will parse them according to JS's timezone interpretation rather than MySQL's (which sets 23:00 to the previous day).

If that doesn't cut it, we should likely just go to shipping all dates back to server as strings without timestamps. That could be accomplished by decorating the $httpParamSerializer service.

jniles pushed a commit to jniles/bhima that referenced this issue Feb 27, 2017
This commit fixes the account report's date handling so that it limits
to the correct dates.  It is a critical bug fix for Vanga.

Caused by a variation on Third-Culture-Software#1274.
jniles pushed a commit that referenced this issue Feb 28, 2017
This commit fixes the account report's date handling so that it limits
to the correct dates.  It is a critical bug fix for Vanga.

Caused by a variation on #1274.
@jniles jniles added the Report label Mar 28, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants