示例#1
0
 /**
  * Run the database seeds.
  *
  * @return void
  */
 public function run()
 {
     Model::unguard();
     // $this->call(UserTableSeeder::class);
     \Bloglyzer\Models\User::create(['name' => 'Blogi Analüüsija']);
     Model::reguard();
 }
示例#2
0
 public function doLogin()
 {
     $password = \Input::get('password');
     if ($password == env('ACCESS_PASSWORD')) {
         $user = \Bloglyzer\Models\User::first();
         \Auth::LoginUsingId($user->id, true);
         return \Redirect::to('/');
     }
 }