public function run() { $faker = Faker\factory::create(); DB::table('challenges')->delete(); foreach (range(1, 5) as $index) { Challenge::create(['name' => $faker->word, 'description' => $faker->text($maxNbChars = 50), 'secrecy' => $faker->numberBetween($min = 1, $max = 3), 'type' => $faker->numberBetween($min = 1, $max = 2), 'admin' => $faker->numberBetween($min = 0, $max = 1), 'active' => $faker->numberBetween($min = 0, $max = 1)]); } }
/** * Run the database seeds. * * @return void */ public function run() { Model::unguard(); $faker = Faker\factory::create(); foreach (range(1, 50) as $index) { User::create(['name' => $faker->sentence(3), 'email' => $faker->email, 'password' => Hash::make($faker->word)]); } }
public function run() { $faker = Faker\factory::create(); DB::table('results')->delete(); foreach (range(1, 5) as $index) { Result::create(['question1' => $faker->word, 'question1_option' => $faker->word, 'question1_answer' => $faker->word, 'question1_points' => $faker->numberBetween($min = 1, $max = 100), 'secrecy' => $faker->numberBetween($min = 1, $max = 3)]); } }
public function run() { $faker = Faker\factory::create(); DB::table('questions')->delete(); foreach (range(1, 5) as $index) { Question::create(['question' => $faker->word, 'points' => $faker->numberBetween($min = 1, $max = 100), 'type' => $faker->numberBetween($min = 1, $max = 2)]); } }
public function run() { $faker = Faker\factory::create(); DB::table('options')->delete(); foreach (range(1, 5) as $index) { Option::create(['option' => $faker->word]); } }
/** * Run the database seeds. * * @return void */ public function run() { Model::unguard(); $faker = Faker\factory::create(); foreach (range(1, 75) as $index) { Negocio::create(['nombre_negocio' => $faker->sentence(4), 'correo' => $faker->email, 'descripcion' => $faker->paragraph(1), 'categoria' => $faker->numberBetween($min = 1, $max = 13), 'direccion' => $faker->address, 'telefono' => $faker->phoneNumber, 'sitio_web' => $faker->domainName, 'coords' => '20.' . $faker->numberBetween($min = 690000, $max = 700000) . ',-103.' . $faker->numberBetween($min = 370000, $max = 380000), 'fb' => $faker->word, 'tw' => $faker->word, 'ig' => $faker->word, 'ciudad' => $faker->randomElement(['Irapuato', 'Salamanca', 'Celaya', 'Guadalajara', 'Zapopan', 'Tlaquepaque', 'Hermosillo', 'Cd. Obregón', 'San Luis Potosí', 'Tijuana', 'Ensenada']), 'status' => $faker->randomElement([0, 1]), 'nombre_responsable' => $faker->name, 'correo_responsable' => $faker->email, 'telefono_responsable' => $faker->phoneNumber]); } }
/** * Run the database seeds. * * @return void */ public function run() { Model::unguard(); $faker = Faker\factory::create(); foreach (range(1, 6) as $index) { Banner::create(['title' => $faker->sentence(4), 'description' => $faker->paragraph($nbSentences = 3, $variableNbSentences = true), 'link' => $faker->url, 'place' => $faker->randomElement(['home', 'inner', 'footer'])]); } }
public function run() { $faker = Faker\factory::create(); DB::table('users')->delete(); foreach (range(1, 5) as $index) { User::create(['firstname' => $faker->firstName($gender = null | 'male' | 'female'), 'lastname' => $faker->lastName, 'alias' => $faker->email, 'city' => $faker->city, 'secrecy' => $faker->numberBetween($min = 1, $max = 3)]); } }
public function run() { $faker = Faker\factory::create(); $users = User::lists('id')->All(); $challenges = Challenge::lists('id')->All(); $questions = Question::lists('id')->All(); $options = Option::lists('id')->All(); foreach (range(1, 5) as $index) { User::create(['user_id' => $faker->randomElement($users), 'challenge_id' => $faker->randomElement($challenges), 'active' => $faker->numberBetween($min = 0, $max = 1)]); } }