minor changes

This commit is contained in:
2024-12-19 04:24:08 +02:00
parent cade33cfb6
commit 75d62872c3
3 changed files with 12 additions and 9 deletions
+3 -3
View File
@@ -7,9 +7,9 @@ Every notification is an instance of `LucentNotifications\Models\Notification` m
### Mail notifications
The static::create function accepts a Mailable class as its mail parameter. Lucent Notifications will instanciate the new Mailable class with the following parameters:
- Notification $notification,
- array $userFrom and
- array $userTo
# Notification $notification,
# array $userFrom and
# array $userTo
so keep that in mind when defining your own Mailable class
+5 -3
View File
@@ -1,11 +1,13 @@
<?php
return [
'defaults' => [
'quietHours' => ['18:00-10:00'],
'commented' => 'both',
'notificationsSettings' => [
'commented' => 'broadcast',
'assigned' => 'none',
'mentioned' => 'none',
],
'userPreferences' => [
'quietHours' => ['18:00-10:00'],
'dailyBriefing' => false
]
];
@@ -11,9 +11,10 @@ return new class extends Migration
*/
public function up(): void
{
Schema::create('notificationsSettings', function (Blueprint $table) {
Schema::create('userSettings', function (Blueprint $table) {
$table->uuid('userId')->primary();
$table->text('data');
$table->text('notificationsSettings');
$table->text('userPreferences');
});
}
@@ -22,6 +23,6 @@ return new class extends Migration
*/
public function down(): void
{
Schema::dropIfExists('notificationsSettings');
Schema::dropIfExists('userSettings');
}
};