29 lines
		
	
	
	
		
			639 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
			
		
		
	
	
			29 lines
		
	
	
	
		
			639 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
<?php
 | 
						|
 | 
						|
use Illuminate\Database\Seeder;
 | 
						|
use Illuminate\Support\Facades\DB;
 | 
						|
 | 
						|
class DatabaseSeeder extends Seeder
 | 
						|
{
 | 
						|
	const CHUNK_SIZE = 100;
 | 
						|
 | 
						|
    static function addTimestamps($object) {
 | 
						|
        $now = DB::raw('CURRENT_TIMESTAMP');
 | 
						|
        $object['created_at'] = $now;
 | 
						|
        $object['updated_at'] = $now;
 | 
						|
        return $object;
 | 
						|
    }
 | 
						|
 | 
						|
    /**
 | 
						|
     * Seed the application's database.
 | 
						|
     *
 | 
						|
     * @return void
 | 
						|
     */
 | 
						|
    public function run()
 | 
						|
    {
 | 
						|
        $this->call(CanastaSeeder::class);
 | 
						|
        $this->call(GrupoDeCompraSeeder::class);
 | 
						|
        $this->call(UserSeeder::class);
 | 
						|
        $this->call(UsuarioOllasSeeder::class);
 | 
						|
    }
 | 
						|
}
 |