feat: [#646] The Where function of Orm supports func condition#975
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds support for function-based conditions in the Orm Where method and updates the tests to verify this new functionality.
- Introduce a new branch in the Query.Where method for functional conditions.
- Add a new test case to verify that the functional condition is applied correctly.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| tests/query_test.go | Adds a test case for functional conditions but appears to check the wrong user variable. |
| database/gorm/query.go | Implements support for functional condition in the Where method. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #975 +/- ##
=======================================
Coverage 69.25% 69.25%
=======================================
Files 160 160
Lines 10712 10712
=======================================
Hits 7419 7419
Misses 2958 2958
Partials 335 335 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
hwbrzzl
added a commit
that referenced
this pull request
Jun 27, 2026
…ve engine rebuild (#975) (#1508) In Build(), configureMiddleware was called after Boot(), which means routes registered by service providers during Boot() were silently dropped when SetGlobalMiddleware rebuilt the route engine. Moving configureMiddleware between Register() and Boot() ensures the engine is set up with global middleware before providers register their routes. Fixes goravel/goravel#975 Co-authored-by: Bowen <hwbrzzl@gmail.com>
hwbrzzl
added a commit
that referenced
this pull request
Jun 27, 2026
…ve engine rebuild (#975) (#1510) In Build(), configureMiddleware was called after Boot(), which means routes registered by service providers during Boot() were silently dropped when SetGlobalMiddleware rebuilt the route engine. Moving configureMiddleware between Register() and Boot() ensures the engine is set up with global middleware before providers register their routes. Fixes goravel/goravel#975 (cherry picked from commit on master) Co-authored-by: Bowen <hwbrzzl@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📑 Description
Closes goravel/goravel#646
✅ Checks