Esempio n. 1
0
 /**
  * Disable the specified resource in storage.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function disable($id)
 {
     $map = $this->map->getById($id);
     if (!$map) {
         return redirect()->route('admin.map.index');
     }
     $result = $this->map->disableMap($map->id);
     if (!$result) {
         return redirect()->back()->with('status', 'update-error');
     }
     return redirect()->back()->with('status', 'update-success');
 }