📜  获取软删除数据 laravel - PHP 代码示例

📅  最后修改于: 2022-03-11 14:53:48.550000             🧑  作者: Mango

代码示例1
To also get soft deleted models : 

$trashedAndNotTrashed = Model::withTrashed()->get();

Only soft deleted models in your results : 

$onlySoftDeleted = Model::onlyTrashed()->get();