HasResourceActions.php 708 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. namespace Dcat\Admin\Controllers;
  3. trait HasResourceActions
  4. {
  5. /**
  6. * Update the specified resource in storage.
  7. *
  8. * @param int $id
  9. *
  10. * @return \Illuminate\Http\Response
  11. */
  12. public function update($id)
  13. {
  14. return $this->form()->update($id);
  15. }
  16. /**
  17. * Store a newly created resource in storage.
  18. *
  19. * @return mixed
  20. */
  21. public function store()
  22. {
  23. return $this->form()->store();
  24. }
  25. /**
  26. * Remove the specified resource from storage.
  27. *
  28. * @param int $id
  29. *
  30. * @return \Illuminate\Http\Response
  31. */
  32. public function destroy($id)
  33. {
  34. return $this->form()->destroy($id);
  35. }
  36. }