Add Merchant-style hero to Giving Pages index.
Deploy Ladill Give / deploy (push) Successful in 1m5s
Deploy Ladill Give / deploy (push) Successful in 1m5s
Surface wallet balance, page count, and active stats in a gradient hero with balance-gated create CTA. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -4,6 +4,7 @@ namespace App\Http\Controllers\Give;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Models\QrCode;
|
||||
use App\Models\QrWallet;
|
||||
use App\Services\Qr\QrCodeManagerService;
|
||||
use App\Services\Qr\QrImageGeneratorService;
|
||||
use App\Services\Qr\QrPdfExporter;
|
||||
@@ -36,9 +37,15 @@ class GivingPageController extends Controller
|
||||
return [$qr->id => $this->imageGenerator->previewDataUri($qr)];
|
||||
});
|
||||
|
||||
$wallet = $this->manager->walletFor($account);
|
||||
|
||||
return view('give.giving-pages.index', [
|
||||
'qrCodes' => $qrCodes,
|
||||
'previewDataUris' => $previewDataUris,
|
||||
'wallet' => $wallet,
|
||||
'activeCount' => $qrCodes->where('is_active', true)->count(),
|
||||
'pricePerQr' => QrWallet::pricePerQr(),
|
||||
'topupUrl' => 'https://'.config('app.account_domain').'/wallet',
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user