Fix remaining merchant surfaces still using merchant.ladill.com/q URLs.
Deploy Ladill Merchant / deploy (push) Successful in 26s

Storefront QR cards, slug preview, payment callbacks, and document downloads now use LadillLink so displayed and encoded links match ladl.link.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
isaacclad
2026-06-27 16:06:32 +00:00
co-authored by Cursor
parent a3029d475d
commit 2991d71ea0
8 changed files with 16 additions and 8 deletions
+2
View File
@@ -46,4 +46,6 @@ AFIA_PROVIDER=openai
AFIA_MODEL=gpt-4o-mini
AFIA_API_KEY=
LINK_PUBLIC_DOMAIN=ladl.link
VITE_APP_NAME="${APP_NAME}"
+1 -1
View File
@@ -312,7 +312,7 @@ class QrCodeController extends Controller
}
}
$png = $this->imageGenerator->renderPng(QrCode::publicBaseUrl() . '/q/' . $shortCode, $style);
$png = $this->imageGenerator->renderPng(\App\Support\LadillLink::url($shortCode), $style);
if ($tempLogoPath) {
Storage::disk('qr')->delete($tempLogoPath);
@@ -10,6 +10,7 @@ use App\Services\Billing\BillingClient;
use App\Services\Billing\PaystackService;
use App\Services\Billing\SmsService;
use App\Services\Pay\PayClient;
use App\Support\LadillLink;
use App\Support\Qr\QrTypeCatalog;
use RuntimeException;
@@ -50,7 +51,7 @@ class MerchantSaleService
$qrCode->loadMissing('user');
$customerEmail = trim((string) ($data['customer_email'] ?? ''));
$callbackUrl = route('qr.public.order.callback', ['shortCode' => $qrCode->short_code]);
$callbackUrl = LadillLink::path($qrCode->short_code, 'order/callback');
$payOrder = $this->pay->createCheckout([
'merchant' => $qrCode->user->public_id,
@@ -122,7 +123,7 @@ class MerchantSaleService
$qrCode->loadMissing('user');
$customerEmail = trim((string) ($data['customer_email'] ?? ''));
$callbackUrl = route('qr.public.booking.callback', ['shortCode' => $qrCode->short_code]);
$callbackUrl = LadillLink::path($qrCode->short_code, 'booking/callback');
$booking = QrBooking::create([
'qr_code_id' => $qrCode->id,
+5
View File
@@ -0,0 +1,5 @@
<?php
return [
'public_domain' => env('LINK_PUBLIC_DOMAIN', 'ladl.link'),
];
@@ -24,7 +24,7 @@
<div class="min-w-0 flex-1">
<p class="truncate font-semibold text-slate-900">{{ $qr->label }}</p>
<p class="mt-0.5 truncate text-sm text-slate-500">{{ $qr->content()['name'] ?? 'Organisation' }}</p>
<p class="mt-2 text-xs text-slate-400">{{ $qr->is_active ? 'Active' : 'Inactive' }} · /q/{{ $qr->short_code }}</p>
<p class="mt-2 truncate text-xs text-slate-400">{{ $qr->is_active ? 'Active' : 'Inactive' }} · {{ $qr->publicUrl() }}</p>
</div>
</div>
</a>
@@ -2,7 +2,7 @@
<x-slot name="title">{{ $qrCode->label }}</x-slot>
@php
$content = $qrCode->content();
$publicUrl = route('qr.public.resolve', ['shortCode' => $qrCode->short_code]);
$publicUrl = \App\Support\LadillLink::url($qrCode->short_code);
$typeLabel = \App\Support\Qr\QrTypeCatalog::label($qrCode->type);
@endphp
@@ -111,7 +111,7 @@
<div id="toolbar">
<span class="tb-label">{{ $qrCode->label }}</span>
@if($allowDownload)
<a href="{{ route('qr.public.file', $qrCode->short_code) }}" download class="tb-download">
<a href="{{ $qrCode->publicPath('file') }}" download class="tb-download">
<svg fill="none" stroke="currentColor" stroke-width="2" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" d="M3 16.5v2.25A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75V16.5M16.5 12 12 16.5m0 0L7.5 12m4.5 4.5V3"/>
</svg>
+2 -2
View File
@@ -106,7 +106,7 @@
status: '',
timer: null,
checkUrl: @js(route('events.check-slug')),
baseUrl: @js(\App\Models\QrCode::publicBaseUrl() . '/q'),
baseUrl: @js(\App\Support\LadillLink::baseUrl()),
check() {
clearTimeout(this.timer);
const s = this.slug.trim();
@@ -126,7 +126,7 @@
:class="status === 'available' ? 'border-green-400' : status === 'taken' || status === 'invalid' ? 'border-red-400' : 'border-slate-200'">
<span class="flex items-center rounded-l-xl border-r border-slate-200 bg-slate-50 px-3 text-xs text-slate-400 whitespace-nowrap select-none"
:class="status === 'available' ? 'border-green-400' : status === 'taken' || status === 'invalid' ? 'border-red-400' : 'border-slate-200'">
{{ \App\Models\QrCode::publicBaseUrl() }}/q/
{{ \App\Support\LadillLink::baseUrl() }}/
</span>
<input type="text" name="custom_short_code"
x-model="slug"