12-05-2026 Frontend dev
This commit is contained in:
parent
405df0a122
commit
5b8bdf4182
779 changed files with 480564 additions and 6241 deletions
31
database/factories/UserPaymentFactory.php
Normal file
31
database/factories/UserPaymentFactory.php
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
<?php
|
||||
|
||||
namespace Database\Factories;
|
||||
|
||||
use App\Enums\PaymentStatus;
|
||||
use App\Models\UserPayment;
|
||||
use App\Models\UserPaymentOption;
|
||||
use Illuminate\Database\Eloquent\Factories\Factory;
|
||||
|
||||
/**
|
||||
* @extends Factory<UserPayment>
|
||||
*/
|
||||
class UserPaymentFactory extends Factory
|
||||
{
|
||||
/**
|
||||
* Define the model's default state.
|
||||
*
|
||||
* @return array<string, mixed>
|
||||
*/
|
||||
public function definition(): array
|
||||
{
|
||||
return [
|
||||
'user_payment_option_id' => UserPaymentOption::factory(),
|
||||
'amount_cents' => fake()->numberBetween(990, 19900),
|
||||
'currency' => 'EUR',
|
||||
'status' => fake()->randomElement(PaymentStatus::cases())->value,
|
||||
'stripe_charge_id' => fake()->optional()->regexify('ch_[A-Za-z0-9]{14}'),
|
||||
'stripe_invoice_id' => fake()->optional()->regexify('in_[A-Za-z0-9]{14}'),
|
||||
];
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue