Initial Ladill Give extraction — online giving pages at give.ladill.com.

Donation checkout via Ladill Pay (9% fee), church/giving QR pages, SSO, and platform scan forwarding.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
isaacclad
2026-06-09 07:25:49 +00:00
co-authored by Cursor
commit 0860b08af7
295 changed files with 37190 additions and 0 deletions
+59
View File
@@ -0,0 +1,59 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
class GiveDonation extends Model
{
public const STATUS_PENDING = 'pending';
public const STATUS_PAID = 'paid';
public const STATUS_FAILED = 'failed';
/** Platform fee on donations (Ladill Give tier). */
public const PLATFORM_FEE_RATE = 0.09;
protected $fillable = [
'pay_order_id',
'qr_code_id',
'user_id',
'reference',
'collection_type',
'amount_minor',
'currency',
'platform_fee_minor',
'merchant_amount_minor',
'payer_name',
'payer_email',
'payer_phone',
'payer_note',
'status',
'payment_reference',
'paid_at',
'metadata',
];
protected $casts = [
'amount_minor' => 'integer',
'platform_fee_minor' => 'integer',
'merchant_amount_minor' => 'integer',
'metadata' => 'array',
'paid_at' => 'datetime',
];
public function qrCode(): BelongsTo
{
return $this->belongsTo(QrCode::class);
}
public function merchant(): BelongsTo
{
return $this->belongsTo(User::class, 'user_id');
}
public function amountMajor(): float
{
return $this->amount_minor / 100;
}
}