Skip to content

Conversation

@zeezo887
Copy link
Collaborator

@zeezo887 zeezo887 commented Mar 7, 2024

Description

This PR overrides the scopeOrWhereTranslationLike method of astrotomic/laravel-translatable to select the like operator based on the database driver used.

public function scopeOrWhereTranslationLike(Builder $query, string $translationField, $value, ?string $locale = null): Builder
{
    return $this->scopeWhereTranslation($query, $translationField, $value, $locale, 'orWhereHas', getLikeOperator());
}

Related Issues

Fixes #2112

@ifox ifox merged commit 6eea37a into area17:3.x May 24, 2024
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.

CMS search case sensitivity with translated models and Postgres

2 participants