Add virtual event sessions with Meet sync and platform-billed messaging.
Deploy Ladill Events / deploy (push) Successful in 41s
Deploy Ladill Events / deploy (push) Successful in 41s
Events can define hybrid/virtual sessions synced to Meet rooms; SMS and email use wallet-billed platform APIs instead of Termii and Laravel mail. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
namespace App\Services\Events;
|
||||
|
||||
use App\Services\Billing\PlatformEmailClient;
|
||||
use Illuminate\Support\Facades\View;
|
||||
|
||||
class EventEmailService
|
||||
{
|
||||
public function __construct(private readonly PlatformEmailClient $platform) {}
|
||||
|
||||
public function sendProgrammeShare(
|
||||
string $ownerPublicId,
|
||||
string $to,
|
||||
string $eventName,
|
||||
string $programmeUrl,
|
||||
?string $attendeeName = null,
|
||||
): bool {
|
||||
$html = View::make('mail.notifications.event-programme', [
|
||||
'eventName' => $eventName,
|
||||
'programmeUrl' => $programmeUrl,
|
||||
'attendeeName' => $attendeeName,
|
||||
])->render();
|
||||
|
||||
return $this->platform->send(
|
||||
$ownerPublicId,
|
||||
$to,
|
||||
'Programme for '.$eventName,
|
||||
$html,
|
||||
strip_tags(str_replace(['<br>', '<br/>', '<br />'], "\n", $html)),
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user