mirror of
https://github.com/HolgerHatGarKeineNode/einundzwanzig-app.git
synced 2026-05-03 16:24:55 +00:00
1f0bfba0d3
🛠️ **Factory:** Created factories for `TwitterAccount`, `EmailCampaign`, `EmailTexts`, and `BookCase`. ✨ **Helper:** Added `NostrHelper` with methods for generating fake/mocked Nostr data. ⬆️ **Dependencies:** Updated multiple Composer dependencies including `laravel/framework`, `astrotomic/laravel-translatable`, and others to their latest versions.
31 lines
763 B
PHP
31 lines
763 B
PHP
<?php
|
|
|
|
namespace Database\Factories;
|
|
|
|
use App\Models\City;
|
|
use App\Models\User;
|
|
use App\Models\Venue;
|
|
use Illuminate\Database\Eloquent\Factories\Factory;
|
|
use Illuminate\Support\Str;
|
|
|
|
/**
|
|
* @extends Factory<Venue>
|
|
*/
|
|
class VenueFactory extends Factory
|
|
{
|
|
protected $model = Venue::class;
|
|
|
|
public function definition(): array
|
|
{
|
|
$name = fake()->randomElement(['Bitcoin Café', 'Sound Money Lounge', 'Hodl Hodl Bar', 'The Orange Pill', 'Satoshi\'s Place']).' '.fake()->unique()->numberBetween(1, 99999);
|
|
|
|
return [
|
|
'city_id' => City::factory(),
|
|
'name' => $name,
|
|
'slug' => Str::slug($name),
|
|
'street' => fake()->streetAddress(),
|
|
'created_by' => User::factory(),
|
|
];
|
|
}
|
|
}
|