<?php
require __DIR__.'/vendor/autoload.php';
$app = require_once __DIR__.'/bootstrap/app.php';
$kernel = $app->make(Illuminate\Contracts\Console\Kernel::class);
$kernel->bootstrap();

$penugasan = \App\Models\Penugasan::findOrFail(4);
try {
    \Illuminate\Support\Facades\Notification::send($penugasan->petugas, new \App\Notifications\PenugasanStatusNotification($penugasan, 'selesai', 'disetujui'));
    echo "OK\n";
} catch (\Exception $e) {
    echo "Error: " . $e->getMessage() . "\n";
}
