<?php

namespace Database\Seeders;

use Illuminate\Database\Console\Seeds\WithoutModelEvents;
use Illuminate\Database\Seeder;
use Illuminate\Support\Facades\DB;

class SettingSeeder extends Seeder
{
    /**
     * Run the database seeds.
     */
public function run(): void
{
    $settings = [
        ['key_name' => 'digiflazz_username', 'value' => 'dibeziDay6VD'],
        ['key_name' => 'digiflazz_api_key', 'value' => 'dev-ca2c9af0-e929-11f0-a4f4-d175b4de8bca'],
        ['key_name' => 'digiflazz_balance', 'value' => '0'],
    ];

    foreach ($settings as $setting) {
        DB::table('settings')->updateOrInsert(
            ['key_name' => $setting['key_name']], // Cék dumasar konci ieu
            ['value' => $setting['value']]        // Upami aya, apdet nilaina
        );
    }
}
}