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

Parse the where param for column mappings #16318

Merged
merged 2 commits into from
Dec 11, 2024
Merged

Conversation

brandonkelly
Copy link
Member

@brandonkelly brandonkelly commented Dec 11, 2024

Description

Parses element queries’ where params for column mappings (e.g. idelements.id, or fieldHandlefields’ value SQL), making things like this possible:

{% set entries = craft.entries()
  .section('news')
  .andWhere([
    'or',
    ['<', 'myNumberField', 100],
    ['>', 'myNumberField', 200],
  ])
  .andWhere("[[myTextField]] LIKE 'foo%'")
  .all() %}

@brandonkelly brandonkelly merged commit 335fa0f into 5.6 Dec 11, 2024
@brandonkelly brandonkelly deleted the feature/parse-where-param branch December 11, 2024 22:21
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

Successfully merging this pull request may close these issues.

1 participant