In this video tutorial, you will be able to get delete and soft delete in laravel. Delete - will delete the entry from table
Soft Delete - will just update the column deleted_At with current date and time
Steps:
For Soft delete
1. In migration, add one column for soft delete
$table-softDeletes();
2. In model, use trait soft delete
Video Timings:
Introduction: 00:00
Delete: 01:20
Soft Delete: 02:00
Force Delete: 02:48
Restore:
Code: (branch: soft-delete )
https://github.com/sushma-singh-yadav...
#php #laravel #knowledgethrusters