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

Grid Filter Throwing Exception on empty Date filter #1689

Closed
mkrecek234 opened this issue Nov 5, 2021 · 3 comments
Closed

Grid Filter Throwing Exception on empty Date filter #1689

mkrecek234 opened this issue Nov 5, 2021 · 3 comments
Assignees

Comments

@mkrecek234
Copy link
Contributor

In a grid view where you activate the filter function, do the following step to reproduce an error:

  1. Have a grid view with a DateTime column
  2. Add a filter on a datetime column, and just press "Set" (leave the filter empty).

This will throw an error TypeError: DateTime::__construct(): Argument #1 ($datetime) must be of type string, null given
As the filter is stored in a cookie, this error will never go away on reload of the page. The user is trapped, unless he deletes cookies.

Verified in 2.4 and current dev-develop branches

@mvorisek
Copy link
Member

mvorisek commented Nov 6, 2021

please reproduce on demos

@mkrecek234
Copy link
Contributor Author

@mvorisek Please check my PR on this - the filter is not capable handling an empty/null input field which should be resolved using the attached PR.

@mvorisek
Copy link
Member

mvorisek commented Dec 6, 2021

fixed in #1718

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants