public function editGeotagFoto(Request $request) { $rth = $request->rth == 'publik' ? $this->table : $this->table_privat; //$table = DB::connection('pgsqlsde')->table($rth); $objectid = $request->objectid; $foto = $request->foto; if ($request->ajax()) { if ($rth == 'publik') { $GeoTag = RTHPUBLIK::where('objectid', '=', $objectid)->first(); } else { $GeoTag = RTHPRIVAT::where('objectid', '=', $objectid)->first(); } $GeoTag->image_link = 'images/rth/' . $foto; //$GeoTag->personil = \Auth::user()->name; //$GeoTag->tanggal = Carbon::now(); $GeoTag->save(); } print $objectid . ' - ' . $foto; }
public function TitikDelete($id) { $titik = RTHPUBLIK::find($id); $titik->delete(); //return view('rth.TitikEdit')->with('titik',$titik); return redirect('rth-titik-list'); }