Skip to content

πŸŽ‰ Optimized filter operators

Compare
Choose a tag to compare
@LasseRafn LasseRafn released this 28 Oct 10:29
· 28 commits to master since this release

AND / OR operators

You can now use AND / OR operators simply by doing so:

$economic->customers()->get([
    ['customerNumber', '=', 1234],
    'and',
    ['email', '!=', 'test@gmail.com'],
    'or',
    ['customerNumber', '=', 4444],
]);

NULL operators

You can check if a value is NULL by doing so:

$economic->customers()->get([
    ['customerNumber', '=', null],
]);

Which will, behind the scenes, transform your null into a $null: operator.

IN operator

The 'in' operator has not been working properly. Now it does. Use it as this:

$economic->customers()->get([
    ['customerNumber', 'in', [1,2,3,4,5]],
]);