<?php

namespace App\Database\Seeds;

use CodeIgniter\Database\Seeder;

class ConfigsSeeder extends Seeder
{
    public function run()
    {
        $data = [
            [
                'id_config' => '1',
                'iva'    => '16.00',
                'tasa' => '42.86',
            ],
            [
                'id_config' => '2',
                'iva'    => '0.00',
                'tasa' => '42.86',
            ]
        ];

        // Simple Queries
        // $this->db->query('INSERT INTO users (username, email) VALUES(:username:, :email:)', $data);

        // Using Query Builder
        $this->db->table('configs')->insertBatch($data);

        $this->call('ClientesSeeder');
        $this->call('EmpresasSeeder');
        $this->call('ProductosSeeder');
    }
}
