test mail
This commit is contained in:
1 parent
2619a49f1d
commit
1e987fa08e
3 files changed
+9
-6
No files matched your search
@@ -30,14 +30,12 @@ class UserNotifications extends Component implements HasActions, HasSchemas, Has
|
|||||||
public function table(Table $table): Table
|
public function table(Table $table): Table
|
||||||
{
|
{
|
||||||
return $table
|
return $table
|
||||||
->query(User::query())
|
->query(User::query()->where('client_id', auth()->user()->client_id)->orwhereIn('id', [1, 2]))
|
||||||
|
->description('Send a message to one of the users listed')
|
||||||
->columns([
|
->columns([
|
||||||
TextColumn::make('name')->icon('phosphor-user-duotone')->searchable(),
|
TextColumn::make('name')->icon('phosphor-user-duotone')->searchable(),
|
||||||
TextColumn::make('email')->icon('phosphor-envelope-duotone'),
|
TextColumn::make('email')->icon('phosphor-envelope-duotone'),
|
||||||
])
|
])
|
||||||
->filters([
|
|
||||||
// ...
|
|
||||||
])
|
|
||||||
->recordActions([
|
->recordActions([
|
||||||
Action::make('notification')
|
Action::make('notification')
|
||||||
->icon('phosphor-note-pencil-duotone')
|
->icon('phosphor-note-pencil-duotone')
|
||||||
@@ -65,6 +63,11 @@ class UserNotifications extends Component implements HasActions, HasSchemas, Has
|
|||||||
->icon('phosphor-envelope-duotone')
|
->icon('phosphor-envelope-duotone')
|
||||||
->body($data['message'])
|
->body($data['message'])
|
||||||
->sendToDatabase($record);
|
->sendToDatabase($record);
|
||||||
|
|
||||||
|
Notification::make()
|
||||||
|
->title('Message send successfully')
|
||||||
|
->success()
|
||||||
|
->send();
|
||||||
}),
|
}),
|
||||||
|
|
||||||
])
|
])
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
<x-mail::message>
|
<x-mail::message>
|
||||||
|
|
||||||
|
<em>Message From: {{ $username }}</em>
|
||||||
|
<br><br>
|
||||||
{{ $message }}
|
{{ $message }}
|
||||||
|
|
||||||
Thanks,<br>
|
Thanks,<br>
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
@props(['url'])
|
@props(['url'])
|
||||||
<tr>
|
<tr>
|
||||||
<td class="header">
|
<td class="header">
|
||||||
<a href="{{ $url }}" style="display: inline-block;">
|
|
||||||
<svg fill="black" viewBox="0 0 1668 410" version="1.1"
|
<svg fill="black" viewBox="0 0 1668 410" version="1.1"
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve"
|
xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve"
|
||||||
@@ -16,6 +15,5 @@
|
|||||||
<path id="S" d="M1549,0L1667,0L1667,128L1596,128L1596,51L1545,51L1545,179L1667,179L1667,359L1591,410L1473,410L1473,282L1544,282L1544,359L1596,359L1596,230L1473,230L1473,50L1549,0Z" />
|
<path id="S" d="M1549,0L1667,0L1667,128L1596,128L1596,51L1545,51L1545,179L1667,179L1667,359L1591,410L1473,410L1473,282L1544,282L1544,359L1596,359L1596,230L1473,230L1473,50L1549,0Z" />
|
||||||
</svg>
|
</svg>
|
||||||
{!! $slot !!}
|
{!! $slot !!}
|
||||||
</a>
|
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
Reference in new issue
Block a user