Cannot get $useSoftDelete working |
I cannot make the 'Soft Delete' feature working in Codeigniter 4.1.1.
I setup the migration, model, and controller according to the documentation. But the row is removed instead of marked delete date at 'deleted_at' column. Wonder what I have missed to make it work as expected. Migration PHP Code: $this->forge->addField("`deleted_at` datetime NULL"); Model PHP Code: class TestModel extends Model Controller PHP Code: $this->model = model('App\Models\TestModel');
Dear moderators,
I have found the cause of this problem, which is due to a typo in the spark command template for model. It has already been fixed 6days ago, as shown in the Github repo: https://github.com/codeigniter4/CodeIgni...1a819c92c2 |
Welcome Guest, Not a member yet? Register Sign In |