Voyager: Support Soft Delete

Created on 3 Aug 2017  路  6Comments  路  Source: the-control-group/voyager

  • Laravel Version: 5.4
  • Voyager Version: 0.11.14
  • PHP Version: 7.1
  • Database Driver & Version:

Description:

I use Laravel soft delete for my user model.

So if I want to see all the users, I have to do a query with ->withTrashed().
To achieve that in Voyager, I had to override the default controller to add ->withTrashed() to all the queries concerning users.

As Voyager is my administration panel, I think it would make sense to add ->withTrashed() to queries by default.

Is there a smart way to do this ? (because overriding controllers for this is painful and it's easy to forget one query)

Or will it be add in Voyager next version ?

Thanks

feature question

Most helpful comment

We could suggest for the next version of Voyager to view the objects that were deleted with the status of removed with the possibility to activate :-D

All 6 comments

We could suggest for the next version of Voyager to view the objects that were deleted with the status of removed with the possibility to activate :-D

Labels: feature, question

Hi, some news about that? Im waiting for the same

This appears to be a older duplicate of #2165

Closing in favor of #2165

This issue has been automatically locked since there has not been any recent activity after it was closed. If you have further questions please ask in our Slack group.

Was this page helpful?
0 / 5 - 0 ratings