Route webinar and conference registration through Ladill Events.
Deploy Ladill Meet / deploy (push) Successful in 1m26s
Deploy Ladill Meet / deploy (push) Successful in 1m26s
Add Events linking UI and service client, remove Meet-native registration and invitation flows for these room types, and redirect attendees to Events registration when joining. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -9,6 +9,7 @@ use App\Models\Invitation;
|
||||
use App\Models\Room;
|
||||
use App\Services\Meet\ContactService;
|
||||
use App\Services\Meet\InvitationService;
|
||||
use App\Support\EventsSourceLink;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\RedirectResponse;
|
||||
use Illuminate\Http\Request;
|
||||
@@ -24,11 +25,25 @@ class InvitationController extends Controller
|
||||
protected ContactService $contacts,
|
||||
) {}
|
||||
|
||||
public function index(Request $request, Room $room): View
|
||||
public function index(Request $request, Room $room): View|RedirectResponse
|
||||
{
|
||||
$this->authorizeAbility($request, 'meetings.manage');
|
||||
$this->authorizeOwner($request, $room);
|
||||
|
||||
if ($room->isWebinar() || $room->isConference()) {
|
||||
$adminUrl = EventsSourceLink::eventCommsUrl($room) ?? EventsSourceLink::eventAdminUrl($room);
|
||||
|
||||
if ($adminUrl) {
|
||||
return redirect()->away($adminUrl);
|
||||
}
|
||||
|
||||
$showRoute = $room->isWebinar() ? 'meet.webinars.show' : 'meet.conferences.show';
|
||||
|
||||
return redirect()
|
||||
->route($showRoute, $room)
|
||||
->withErrors(['invitations' => 'Link this session to Ladill Events to send bulk invitations.']);
|
||||
}
|
||||
|
||||
$room->load(['invitations' => fn ($q) => $q->orderByDesc('created_at')]);
|
||||
$groups = ContactGroup::owned($this->ownerRef($request))
|
||||
->where('organization_id', $room->organization_id)
|
||||
|
||||
Reference in New Issue
Block a user