filter by search query after order by priority