/** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { $users = User::all(); $actions = ActionSchema::getActionSchema($this->module); $roles = Role::all(); return view('backend.user.index')->with('content_title', 'Users')->with('users', $users)->with('actions', $actions)->with('roles', $roles)->with('module', $this->module); }
/** * Display the specified resource. * * @param int $id * @return \Illuminate\Http\Response */ public function show($id) { $role = Role::find($id); $actions = ActionSchema::getActionSchema($this->module); $permission_ids = PermissionRole::where('role_id', $id)->lists('permission_id')->toArray(); // return $permission_ids; return view('backend.role.show')->with('content_title', "Role Details")->with('role', $role)->with('permission_ids', $permission_ids)->with('actions', $actions)->with('module', $this->module); }
/** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { $notifications = Notification::all(); $actions = ActionSchema::getActionSchema($this->module); return view('backend.notification.index')->with('content_title', 'Notifications')->with('notifications', $notifications)->with('actions', $actions)->with('module', $this->module); }
/** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { $posts = Post::all(); $actions = ActionSchema::getActionSchema($this->module); return view('backend.post.index')->with('content_title', 'All Posts')->with('posts', $posts)->with('actions', $actions)->with('module', $this->module); }
/** * Display the specified resource. * * @param int $id * @return \Illuminate\Http\Response */ public function show($id) { $feature = Feature::find($id); if (!isset($feature)) { return Redirect::to('/crm/feature')->withMessage(Generate::message('Invalid', 'Invalid Feature or Feature has been deleted')); } $permissions = $feature->permissions; $actions = ActionSchema::getActionSchema($this->module); return view('backend.feature.show')->with('content_title', 'Feature and Permissions')->with('feature', $feature)->with('actions', $actions)->with('permissions', $permissions)->with('module', $this->module); }