orchidsoftware / orchidsoftware/platform
Configure Relation search query
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 4.8k
- Forks
- 662
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 7
Description
It would be nice to have a bit more flexibility on this query.
in my case I would like to use ILIKE (Postgres)
it's possible to use scope but the $search parameter is not passed to the scope.
maybe we can add something like filterWithScope on the Relation field and call it with
$model = $model->{$filterScope['name']}(...array_merge($filterScope['parameters'] ?? [], $search));
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with src/Platform/Http/Controllers/Systems/RelationController.php around line 85 and trace how Relation fields apply filter scopes. Check how the $search parameter reaches the scope and define the smallest configurable API that supports the reported PostgreSQL ILIKE use case. Done means relation searches can pass the search value to a configured scope without breaking existing filtering.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- laravel, php, postgresql
- Domain
- backend, databases
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100