链街Dcat后台
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

49 lines
903 B

  1. <?php
  2. namespace App\Admin\Forms;
  3. use Dcat\Admin\Widgets\Form;
  4. use Symfony\Component\HttpFoundation\Response;
  5. class CouponTieForm extends Form
  6. {
  7. /**
  8. * Handle the form request.
  9. *
  10. * @param array $input
  11. *
  12. * @return Response
  13. */
  14. public function handle(array $input)
  15. {
  16. // dump($input);
  17. // return $this->error('Your error message.');
  18. return $this->success('Processed successfully.', '/');
  19. }
  20. /**
  21. * Build a form here.
  22. */
  23. public function form()
  24. {
  25. $this->text('activity')->required();
  26. $this->text('name')->required();
  27. $this->text('repay')->required();
  28. }
  29. /**
  30. * The data of the form.
  31. *
  32. * @return array
  33. */
  34. public function default()
  35. {
  36. return [
  37. 'activity' => '0',
  38. 'forward' => '',
  39. 'repay' => '',
  40. ];
  41. }
  42. }