Esempio n. 1
0
 /**
  * Remove the specified Partners from storage.
  *
  * @param  int $id
  *
  * @return Response
  */
 public function destroy($id)
 {
     $partners = $this->partnersRepository->find($id);
     if (empty($partners)) {
         Flash::error('Partners not found');
         return redirect(route('partners.index'));
     }
     $this->partnersRepository->delete($id);
     Flash::success('Partners deleted successfully.');
     return redirect(route('partners.index'));
 }
Esempio n. 2
0
 /**
  * Remove the specified Partners from storage.
  * DELETE /partners/{id}
  *
  * @param  int $id
  *
  * @return Response
  */
 public function destroy($id)
 {
     $this->partnersRepository->apiDeleteOrFail($id);
     return $this->sendResponse($id, "Partners deleted successfully");
 }