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

Add Model query whereDate support #2251

Merged
merged 3 commits into from May 12, 2021
Merged

Add Model query whereDate support #2251

merged 3 commits into from May 12, 2021

Conversation

yexk
Copy link
Contributor

@yexk yexk commented May 11, 2021

issue: Not supprt whereDate query.
image

solutions:
According to the document:

So I hope to add whereXXX, in order to compatible with laravel and facilitate dcat admin to use mongodb.

@divine
Copy link
Contributor

divine commented May 11, 2021

Add tests please.

@yexk
Copy link
Contributor Author

yexk commented May 12, 2021

Add tests please.

Submitted test and add doc

@Smolevich Smolevich merged commit e16794d into mongodb:master May 12, 2021
@divine divine linked an issue May 13, 2021 that may be closed by this pull request
@kudjieRaymond
Copy link

Hello, I think WhereDay , WhereYear do not work as expected.

In the laravel documentation for instance for whereYear() the first parameter is the date and the second parameter is the year
Screenshot from 2021-06-30 13-32-59

However in this instance the search operation is doing a standard search. You can see below a screenshot of the tests in this pull request
Screenshot from 2021-06-30 13-35-41

@divine
Copy link
Contributor

divine commented Jun 30, 2021

Hello @kudjieRaymond ,

Instead of replying to merged pull requests create a new issue.

Thanks!

@mongodb mongodb locked as resolved and limited conversation to collaborators Jun 30, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

whereDate / whereMonth / whereDay / whereYear / whereTime ???
4 participants