/** * Run the database seeds. * * @return void */ public function run() { factory(\Flisk\User::class, 5)->create(); User::create(['first_name' => 'Gareth', 'last_name' => 'Nicholson', 'gender' => 'm', 'confirmed' => 1, 'username' => 'Gareth', 'email' => '*****@*****.**', 'timezone' => 'Africa/Johannesburg', 'password' => bcrypt('password'), 'remember_token' => str_random(10)]); }
/** * Create a new user instance after a valid registration. * * @param array $data * @return User */ protected function create(array $data) { return User::create(['first_name' => $data['first_name'], 'last_name' => $data['last_name'], 'username' => $data['username'], 'gender' => $data['gender'], 'timezone' => $data['timezone'], 'email' => $data['email'], 'password' => bcrypt($data['password'])]); }