Esempio n. 1
0
 /**
  * Show the application welcome screen to the user.
  *
  * @return Response
  */
 public function index()
 {
     $data = ['sitename' => \Config::get('diablo.sitename')];
     $characters = Character::all();
     if (count($characters) === 0) {
         return view('welcome', $data);
     } else {
         $data['characters'] = Character::with('member', 'stats')->get();
         $data['ClassHelper'] = new CharacterClass();
         return view('home', $data);
         //return view('index', $data);
     }
 }
Esempio n. 2
0
 /**
  * Character Listing
  * @return \Illuminate\View\View
  */
 public function characters()
 {
     $data = ['user' => Auth::user(), 'sitename' => \Config::get('diablo.sitename'), 'fields' => ['name' => ['type' => 'text', 'min' => 2, 'max' => 30], 'battletag' => ['type' => 'text', 'min' => 4, 'max' => 20]], 'endpoint' => \URL::route('member.post'), 'container' => 'memberForm', 'success' => "location.reload();", 'button' => 'addMember', 'title' => 'Add Member', 'characters' => Character::with('member')->get()];
     return view('admin/characters/index', $data);
 }
Esempio n. 3
0
 /**
  * Show the application dashboard to the user.
  *
  * @return Response
  */
 public function index()
 {
     $data = ['sitename' => \Config::get('diablo.sitename'), 'characters' => Character::with('member', 'stats')->get(), 'user' => Auth::user(), 'ClassHelper' => new CharacterClass()];
     return view('home', $data);
 }