/**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function edit($id)
 {
     $roleModel = new Role();
     $navigationModel = new Navigation();
     $permissionModel = new Permission();
     if (!($roleRow = $roleModel->getForEdit($id))) {
         return view('admin.common.alert', ['type' => 'warning', 'error' => [trans('page_404')], 'location' => ['url' => route('admin.rbac.roles.index'), 'name' => trans('rbac.role') . trans('common.list')]]);
     }
     return view('admin.rbac.roles.create')->with('navigationRows', $navigationModel->getAllNavigationForChildren())->with('permissionRows', $permissionModel->getAllPermissionForChildren())->with('roleRow', $roleRow);
 }
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function edit(Navigation $navigationModel, $id)
 {
     return view('admin.rbac.navigation.create')->with('navigationRow', $navigationModel->find($id))->with('navigationRows', $navigationModel->getAllNavigationForChildren());
 }