- Laravel 11, Blade, Alpine.js, Tailwind CSS - Produkt- & Kategorieverwaltung mit Varianten - Checkout (Vorkasse + Rechnung), Session-Warenkorb - Admin-Backend (Dashboard, Bestellungen, Kunden, CMS) - DSGVO-konform: Cookie-Consent, Impressum, Widerruf, AGB - PDF-Rechnung via dompdf, SMTP-Mailversand - Kundenverwaltung mit manueller Freischaltung Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
48 lines
1.5 KiB
PHP
48 lines
1.5 KiB
PHP
<?php
|
|
|
|
namespace Database\Seeders;
|
|
|
|
use App\Models\Setting;
|
|
use App\Models\ShippingRate;
|
|
use Illuminate\Database\Seeder;
|
|
|
|
class SettingsSeeder extends Seeder
|
|
{
|
|
public function run(): void
|
|
{
|
|
$defaults = [
|
|
'shop_name' => 'Mein Online-Shop',
|
|
'shop_email' => 'info@example.de',
|
|
'shop_phone' => '',
|
|
'shop_address' => '',
|
|
'shop_owner' => '',
|
|
'shop_vat_id' => '',
|
|
'bank_name' => '',
|
|
'bank_iban' => '',
|
|
'bank_bic' => '',
|
|
'invoice_payment_days' => '14',
|
|
'currency' => 'EUR',
|
|
'currency_symbol' => '€',
|
|
'smtp_host' => '',
|
|
'smtp_port' => '587',
|
|
'smtp_user' => '',
|
|
'smtp_password' => '',
|
|
'smtp_from_name' => 'Mein Online-Shop',
|
|
'smtp_from_email' => 'noreply@example.de',
|
|
'cookie_consent' => '1',
|
|
'google_analytics' => '',
|
|
];
|
|
|
|
foreach ($defaults as $key => $value) {
|
|
Setting::firstOrCreate(['key' => $key], ['value' => $value]);
|
|
}
|
|
|
|
ShippingRate::firstOrCreate(['name' => 'Standard (Deutschland)'], [
|
|
'zone' => 'DE',
|
|
'price' => 4.99,
|
|
'free_from' => 50.00,
|
|
'active' => true,
|
|
]);
|
|
}
|
|
}
|