public function index()
 {
     $param['pageNo'] = 21;
     if ($alert = Session::get('alert')) {
         $param['alert'] = $alert;
     }
     $param['unit'] = UnitModel::all();
     return View::make('admin.square.index')->with($param);
 }
Esempio n. 2
0
 /**
  * Get paths behind 'admin'.
  *
  * Compose sidebar variable.
  */
 private function composeUnits()
 {
     View::composer('product.form', function ($view) {
         $view->with(['units' => Unit::all()->lists('name', 'id')]);
     });
 }