Merge pull request #16494 from marcusmoore/bug/sc-28675

Avoid logging consumable checkins and purge action log of bad entries
This commit is contained in:
snipe
2025-04-19 14:24:52 +01:00
committed by GitHub
3 changed files with 46 additions and 20 deletions

View File

@@ -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...
}
};