Welcome Guest, Not a member yet? Register   Sign In
Soft delete doesn't work with like?
#1

(This post was last modified: 10-30-2019, 05:54 AM by edica.)

$q = 'test';

$list = ['title' => $q, 'slug' => $q, 'body' => $q];
$data = [
'news' => $model->orLike($list)->paginate(5),
'pager' => $model->pager
];

Using ($useSoftDeletes = true) in the model the above request is looking for deleted too. Is this correct? I think I shouldn't look for the deleted ones. Only when using withDeleted().
Reply


Messages In This Thread
Soft delete doesn't work with like? - by edica - 10-29-2019, 07:51 AM



Theme © iAndrew 2016 - Forum software by © MyBB