Use platform Paystack email and Figtree on Mini payment pages.
Deploy Ladill Mini / deploy (push) Successful in 1m11s
Deploy Ladill Mini / deploy (push) Successful in 1m11s
Route Paystack receipts to pay@ladill.com instead of vendor emails, and load Figtree on the public payment and confirmation screens. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -33,13 +33,7 @@ class MiniPaymentService
|
||||
throw new RuntimeException('Enter an amount greater than zero.');
|
||||
}
|
||||
|
||||
$qrCode->loadMissing('user.qrSetting');
|
||||
$merchant = $qrCode->user;
|
||||
$email = trim((string) ($merchant?->qrSetting?->notify_email ?: $merchant?->email));
|
||||
if ($email === '' || ! str_contains($email, '@')) {
|
||||
throw new RuntimeException('This payment QR is not ready yet — the vendor must add an email in Ladill Mini settings.');
|
||||
}
|
||||
|
||||
$qrCode->loadMissing('user');
|
||||
$amountMinor = (int) round($amountGhs * 100);
|
||||
$reference = 'MINP-'.strtoupper(Str::random(16));
|
||||
$payRef = 'MIN-'.strtoupper(Str::random(16));
|
||||
@@ -59,7 +53,7 @@ class MiniPaymentService
|
||||
]);
|
||||
|
||||
$paystackData = $this->paystack->initializeTransaction([
|
||||
'email' => $email,
|
||||
'email' => (string) config('services.paystack.checkout_email', 'pay@ladill.com'),
|
||||
'amount' => $amountMinor,
|
||||
'currency' => $payment->currency,
|
||||
'reference' => $payRef,
|
||||
|
||||
Reference in New Issue
Block a user