示例#1
0
 public function buildForm(\Symfony\Component\Form\FormBuilderInterface $builder, array $options)
 {
     parent::buildForm($builder, $options);
     $builder->add('intCreditAmount', 'hidden', array('data' => $this->getCredit()->getCreditAmount()));
     $builder->add('intRepaymentTime', 'hidden', array('data' => $this->getCredit()->getReplaymentTime()));
     $builder->add('intRepaymentMethod', 'choice', array('choices' => \App\FrontendBundle\Utils\Session\CreditCreator::GetReplaymentMethodsToDropDown(), 'placeholder' => 'Sposób spłaty pożyczki', 'data' => $this->getCredit()->getReplaymentMethod()));
     $builder->add('strPurpose', 'text', array('attr' => array('placeholder' => 'Cel pożyczki'), 'data' => $this->getCredit()->getPurpose()));
     $builder->add('strTypeOfSecurity', 'text', array('attr' => array('placeholder' => 'Rodzaj zabezpieczenia'), 'data' => $this->getCredit()->getTypeOfSecurity()));
     $builder->add('strTypeOfSecurityDescription', 'textarea', array('attr' => array('placeholder' => 'Szczegółowy opis zabezpieczenia pożyczki'), 'data' => $this->getCredit()->getTypeOfSecurityDescription()));
 }
示例#2
0
 public function buildForm(\Symfony\Component\Form\FormBuilderInterface $builder, array $options)
 {
     parent::buildForm($builder, $options);
     $builder->add('amount', 'hidden', array('data' => $this->getCredit()->getCreditAmount()));
     $builder->add('replaymentTime', 'hidden', array('data' => $this->getCredit()->getReplaymentTime()));
     $builder->add('interest', 'text', array('attr' => array('placeholder' => 'Oprocentowanie', 'regex' => '\\d+')));
     $builder->add('typeOfSecurity', 'text', array('attr' => array('placeholder' => 'Rodzaj zabezpieczenia', 'regex' => '.{1,255}'), 'data' => $this->getCredit()->getTypeOfSecurity()));
     $builder->add('replaymentMethod', 'choice', array('choices' => \App\FrontendBundle\Utils\Session\CreditCreator::GetReplaymentMethodsToDropDown(), 'placeholder' => 'Sposób spłaty pożyczki', 'data' => $this->getCredit()->getReplaymentMethod()));
     $builder->add('description', 'textarea', array('attr' => array('placeholder' => 'Uwagi', 'regex' => '.+')));
     $builder->add('expiredAt', 'text', array('attr' => array('placeholder' => 'Ważność oferty', 'regex' => '\\d\\d\\.\\d\\d\\.\\d\\d\\d\\d')));
 }
示例#3
0
 public function buildForm(\Symfony\Component\Form\FormBuilderInterface $builder, array $options)
 {
     parent::buildForm($builder, $options);
     $builder->add('strPurpose', 'text', array('attr' => array('placeholder' => 'Cel pożyczki', 'pattern' => '^.{1,255}$')));
     $builder->add('strPurposeDescription', 'textarea', array('attr' => array('placeholder' => 'Szczegółowy opis celu pożyczki', 'pattern' => '^.+$')));
     $builder->add('intRepaymentMethod', 'choice', array('choices' => CreditCreator::GetReplaymentMethodsToDropDown(), 'placeholder' => 'Sposób spłaty pożyczki'));
     $builder->add('intSourceOfIncome', 'choice', array('choices' => CreditCreator::GetSourceOfIncomesToDropDown(), 'placeholder' => 'Źródło przychodów'));
     $builder->add('intSalary', 'text', array('attr' => array('placeholder' => 'Dochody miesięczne', 'pattern' => '^\\d{1,8}$')));
     $builder->add('intMaritalStatus', 'choice', array('choices' => CreditCreator::GetMaritalStatusesToDropDown(), 'placeholder' => 'Stan cywilny'));
     $builder->add('intNumberOfChildren', 'choice', array('choices' => CreditCreator::GetNumbersOfChildrenToDropDown(), 'placeholder' => 'Ilość dzieci'));
     $builder->add('strTypeOfSecurity', 'text', array('attr' => array('placeholder' => 'Rodzaj zabezpieczenia', 'pattern' => '^.{1,255}$')));
     $builder->add('strTypeOfSecurityDescription', 'textarea', array('attr' => array('placeholder' => 'Szczegółowy opis zabezpieczenia pożyczki', 'pattern' => '^.+$')));
     $builder->add('filesName', 'text', array('required' => false, 'attr' => array('readonly' => true, 'placeholder' => 'Dokumenty, zdjęcia', 'class' => 'selectedFiles')));
     $builder->add('files', 'file', array('attr' => array('class' => 'selectFiles', 'style' => 'display: none;'), 'required' => false, 'multiple' => true));
     $this->setDefault($builder);
 }