Is there a way to display no records in the list view by default and only see records when searchin?
I want to make it so that:
User accesses list records page -> User sees 0 records by default -> User starts seeing records for search results once they type something in the search bar
Thank you.
2 Replies
See https://discord.com/channels/883083792112300104/1082256110402162688
$this->getTableSearchQuery()
thanks, that worked.
code for future reference
if (empty($this->getTableSearchQuery())) return Model::query()->whereRaw("1=0");