first commit

This commit is contained in:
benjibennn
2023-12-22 12:35:55 +08:00
commit 9f89a732d6
872 changed files with 156291 additions and 0 deletions

20
app/helpers.php Normal file
View File

@@ -0,0 +1,20 @@
<?php
use App\Models\UserNotification;
if (! function_exists('storeUserNotification')) {
function storeUserNotification($userId, $title, $description = null, $category = null, $isAdmin = false, $targetId = null, $targetType = null, $status = 'success', $isRead = false)
{
return UserNotification::create([
'user_id' => $userId,
'title' => $title,
'description' => $description,
'category' => $category,
'target_id' => $targetId,
'target_type' => $targetType,
'is_read' => $isRead,
'is_admin' => $isAdmin,
'status' => $status,
]);
}
}