Laravel Soft Delete

Laravel Soft Delete

Soft Delete
Data Base 

In database add column ‘deleted_at’ in the table
deleted_at Field, default NULL value


In model file add ‘use SoftDeletes’ statement
use Illuminate\Database\Eloquent\SoftDeletes;

class User extends Model {
use SoftDeletes;



In your controller file add destroy function.
public function destroy($id)

Please follow and like us:

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload the CAPTCHA.