Ejemplo n.º 1
0
 /**
  * Define the fields of the form
  *
  * @param FormBuilder $form
  */
 public function form(FormBuilder $form)
 {
     $this->action = route('administr.auth.login');
     $this->method = 'post';
     $form->email('email', trans('administr::users.email'))->password('password', trans('administr::users.password'))->submit('login', trans('administr::users.login'));
 }
Ejemplo n.º 2
0
 /** @test */
 public function it_adds_an_email_field_and_returns_form_builder_object()
 {
     $formBuilder = new FormBuilder();
     $builder = $formBuilder->email('test', 'Test');
     $field = $formBuilder->fields()['test'];
     $this->assertInstanceOf(Email::class, $field);
     $this->assertInstanceOf(FormBuilder::class, $builder);
 }