-2
現在、symfony 2.7プロジェクトを3. *に更新しています。2.8バージョンで廃止予定をクリアしています。Symfonyカスタムタイプ廃止通知
だから私はChoiceNVTypeたちはこれまでのように使用私たちのカスタム型で廃止通知に
Passing type instances to FormBuilder::add(), Form::add() or the FormFactory is deprecated since version 2.8 and will not be supported in 3.0. Use the fully-qualified type class name instead (******\AutoBundle\Form\Type\ChoiceNVType)
を得続けるました:
$form->add('model', new ChoiceNVType(), array(
'choices' => array(),
'required' => false,
'placeholder' => 'Something',
));
は、今、私たちはすべて廃止通知を修正したいが、私は持っていますどのようにカスタムタイプでそれを行うか分かりません。何か案は?
ええ、それはそれだった、最悪の事態は私が先に試してみたが、それが実際に動作しませんでした。ありがとう! :) – Pitchwaiz
あなたは 'ChoiceNVType :: class' =>と書くこともできます。 – mblaettermann