/** * Show the form for editing the specified resource. * * @param int $id * @return Response */ public function edit(Parcels $parcel) { if ($parcel->isDelivered()) { alert()->info('The parcel has been delivered already.', 'Oops'); return redirect('parcel'); } $towns = Towns::lists('name', 'id'); return view('parcel.edit', compact('parcel', 'towns')); }