oroalej
194
3
Tips

Shortcut of Where.

Posted 11 months ago by oroalej

Hi All,

If you would like to query like this

Modal::where('some_column', 'some value')->get();

You can code it this way.

Modal::whereSomeColumn('some value')->get();

The result will be the same.

Unfortunately, this will only work when you are looking for the equal value. It doesn't work with !=.

Please sign in or create an account to participate in this conversation.