1 | <?php |
||
2 | |||
3 | /** |
||
4 | * MIT License |
||
5 | * Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file. |
||
6 | */ |
||
7 | |||
8 | namespace SprykerEco\Yves\Ratepay\Form; |
||
9 | |||
10 | use Generated\Shared\Transfer\RatepayPaymentElvTransfer; |
||
0 ignored issues
–
show
|
|||
11 | use Spryker\Yves\StepEngine\Dependency\Form\SubFormInterface; |
||
12 | use SprykerEco\Shared\Ratepay\RatepayConfig; |
||
13 | use Symfony\Component\Form\Extension\Core\Type\TextType; |
||
14 | use Symfony\Component\Form\FormBuilderInterface; |
||
15 | use Symfony\Component\OptionsResolver\OptionsResolver; |
||
16 | use Symfony\Component\OptionsResolver\OptionsResolverInterface; |
||
0 ignored issues
–
show
The type
Symfony\Component\Option...ptionsResolverInterface was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths
Loading history...
|
|||
17 | |||
18 | class ElvSubForm extends SubFormAbstract |
||
19 | { |
||
20 | public const PAYMENT_METHOD = 'elv'; |
||
21 | |||
22 | public const FIELD_BUNK_ACCOUNT_HOLDER = 'bank_account_holder'; |
||
23 | public const FIELD_BUNK_ACCOUNT_BIC = 'bank_account_bic'; |
||
24 | public const FIELD_BUNK_ACCOUNT_IBAN = 'bank_account_iban'; |
||
25 | |||
26 | /** |
||
27 | * @param \Symfony\Component\OptionsResolver\OptionsResolver $resolver |
||
28 | * |
||
29 | * @return void |
||
30 | */ |
||
31 | public function configureOptions(OptionsResolver $resolver) |
||
32 | { |
||
33 | $resolver->setDefaults([ |
||
34 | 'data_class' => RatepayPaymentElvTransfer::class, |
||
35 | SubFormInterface::OPTIONS_FIELD_NAME => [], |
||
36 | ]); |
||
37 | } |
||
38 | |||
39 | /** |
||
40 | * @deprecated Use `configureOptions()` instead. |
||
41 | * |
||
42 | * @param \Symfony\Component\OptionsResolver\OptionsResolverInterface $resolver |
||
43 | * |
||
44 | * @return void |
||
45 | */ |
||
46 | public function setDefaultOptions(OptionsResolverInterface $resolver) |
||
47 | { |
||
48 | $this->configureOptions($resolver); |
||
49 | } |
||
50 | |||
51 | /** |
||
52 | * @return string |
||
53 | */ |
||
54 | public function getPropertyPath() |
||
55 | { |
||
56 | return RatepayConfig::PAYMENT_METHOD_ELV; |
||
57 | } |
||
58 | |||
59 | /** |
||
60 | * @return string |
||
61 | */ |
||
62 | public function getName() |
||
63 | { |
||
64 | return RatepayConfig::PAYMENT_METHOD_ELV; |
||
65 | } |
||
66 | |||
67 | /** |
||
68 | * @return string |
||
69 | */ |
||
70 | public function getTemplatePath() |
||
71 | { |
||
72 | return RatepayConfig::PROVIDER_NAME . '/' . static::PAYMENT_METHOD; |
||
73 | } |
||
74 | |||
75 | /** |
||
76 | * @param \Symfony\Component\Form\FormBuilderInterface $builder |
||
77 | * @param array $options |
||
78 | * |
||
79 | * @return void |
||
80 | */ |
||
81 | public function buildForm(FormBuilderInterface $builder, array $options) |
||
82 | { |
||
83 | parent::buildForm($builder, $options); |
||
84 | $this |
||
85 | ->addBankAccountBic($builder) |
||
86 | ->addBankAccountIban($builder); |
||
87 | } |
||
88 | |||
89 | /** |
||
90 | * @param \Symfony\Component\Form\FormBuilderInterface $builder |
||
91 | * |
||
92 | * @return $this |
||
93 | */ |
||
94 | public function addBankAccountHolder($builder) |
||
95 | { |
||
96 | $builder->add( |
||
97 | self::FIELD_BUNK_ACCOUNT_HOLDER, |
||
98 | TextType::class, |
||
99 | [ |
||
100 | 'label' => false, |
||
101 | 'required' => true, |
||
102 | 'constraints' => [ |
||
103 | $this->createNotBlankConstraint(), |
||
104 | ], |
||
105 | ] |
||
106 | ); |
||
107 | |||
108 | return $this; |
||
109 | } |
||
110 | |||
111 | /** |
||
112 | * @param \Symfony\Component\Form\FormBuilderInterface $builder |
||
113 | * |
||
114 | * @return $this |
||
115 | */ |
||
116 | public function addBankAccountBic($builder) |
||
117 | { |
||
118 | $builder->add( |
||
119 | self::FIELD_BUNK_ACCOUNT_BIC, |
||
120 | TextType::class, |
||
121 | [ |
||
122 | 'label' => false, |
||
123 | 'required' => true, |
||
124 | 'constraints' => [ |
||
125 | $this->createNotBlankConstraint(), |
||
126 | ], |
||
127 | ] |
||
128 | ); |
||
129 | |||
130 | return $this; |
||
131 | } |
||
132 | |||
133 | /** |
||
134 | * @param \Symfony\Component\Form\FormBuilderInterface $builder |
||
135 | * |
||
136 | * @return $this |
||
137 | */ |
||
138 | public function addBankAccountIban($builder) |
||
139 | { |
||
140 | $builder->add( |
||
141 | self::FIELD_BUNK_ACCOUNT_IBAN, |
||
142 | TextType::class, |
||
143 | [ |
||
144 | 'label' => false, |
||
145 | 'required' => true, |
||
146 | 'constraints' => [ |
||
147 | $this->createNotBlankConstraint(), |
||
148 | ], |
||
149 | ] |
||
150 | ); |
||
151 | |||
152 | return $this; |
||
153 | } |
||
154 | } |
||
155 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths