Purge activity log of consumable bulk checkins
This commit is contained in:
parent
be6caf936e
commit
d5bc5caacd
1 changed files with 30 additions and 0 deletions
|
@ -0,0 +1,30 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
use App\Models\Consumable;
|
||||||
|
use Illuminate\Database\Migrations\Migration;
|
||||||
|
use Illuminate\Support\Facades\DB;
|
||||||
|
|
||||||
|
return new class extends Migration
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Run the migrations.
|
||||||
|
*/
|
||||||
|
public function up(): void
|
||||||
|
{
|
||||||
|
DB::table('action_logs')
|
||||||
|
->where([
|
||||||
|
'action_type' => 'checkin from',
|
||||||
|
'note' => 'Bulk checkin items',
|
||||||
|
'item_type' => Consumable::class,
|
||||||
|
])
|
||||||
|
->delete();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Reverse the migrations.
|
||||||
|
*/
|
||||||
|
public function down(): void
|
||||||
|
{
|
||||||
|
// nothing to do here...
|
||||||
|
}
|
||||||
|
};
|
Loading…
Add table
Reference in a new issue