|
|
|
|
|
|
|
|
use Lc\PietroBundle\Form\ProjectBoost\ProjectBoostType; |
|
|
use Lc\PietroBundle\Form\ProjectBoost\ProjectBoostType; |
|
|
use Lc\PietroBundle\Form\ProjectInspiring\ProjectInspiringType; |
|
|
use Lc\PietroBundle\Form\ProjectInspiring\ProjectInspiringType; |
|
|
use Lc\PietroBundle\Form\Revolt\RevoltType; |
|
|
use Lc\PietroBundle\Form\Revolt\RevoltType; |
|
|
|
|
|
use Lc\PietroBundle\Repository\Territory\TerritoryStore; |
|
|
use Lc\SovBundle\Definition\Field\AbstractFieldDefinition; |
|
|
use Lc\SovBundle\Definition\Field\AbstractFieldDefinition; |
|
|
use Lc\SovBundle\Field\CollectionField; |
|
|
use Lc\SovBundle\Field\CollectionField; |
|
|
use Lc\SovBundle\Field\StatusField; |
|
|
use Lc\SovBundle\Field\StatusField; |
|
|
|
|
|
|
|
|
{ |
|
|
{ |
|
|
|
|
|
|
|
|
protected AuthorizationCheckerInterface $authorizationChecker; |
|
|
protected AuthorizationCheckerInterface $authorizationChecker; |
|
|
|
|
|
protected TerritoryStore $territoryStore; |
|
|
|
|
|
|
|
|
public function __construct(TranslatorAdmin $translatorAdmin, AuthorizationCheckerInterface $authorizationChecker) |
|
|
|
|
|
|
|
|
public function __construct(TranslatorAdmin $translatorAdmin, AuthorizationCheckerInterface $authorizationChecker, TerritoryStore $territoryStore) |
|
|
{ |
|
|
{ |
|
|
$this->authorizationChecker = $authorizationChecker; |
|
|
$this->authorizationChecker = $authorizationChecker; |
|
|
|
|
|
$this->territoryStore = $territoryStore; |
|
|
|
|
|
|
|
|
parent::__construct($translatorAdmin); |
|
|
parent::__construct($translatorAdmin); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
{ |
|
|
{ |
|
|
$fields = array(); |
|
|
$fields = array(); |
|
|
|
|
|
|
|
|
|
|
|
$territoryArray = $this->territoryStore->get(); |
|
|
|
|
|
|
|
|
$fields['firstname'] = TextField::new('firstname'); |
|
|
$fields['firstname'] = TextField::new('firstname'); |
|
|
$fields['lastname'] = TextField::new('lastname'); |
|
|
$fields['lastname'] = TextField::new('lastname'); |
|
|
$fields['email'] = EmailField::new('email'); |
|
|
$fields['email'] = EmailField::new('email'); |
|
|
$fields['territory'] = AssociationField::new('territory'); |
|
|
|
|
|
|
|
|
$fields['territory'] = AssociationField::new('territory')->setFormTypeOption('choices', $territoryArray); |
|
|
$fields['nbDream'] = TextField::new('nbDream'); |
|
|
$fields['nbDream'] = TextField::new('nbDream'); |
|
|
$fields['nbRevolt'] = TextField::new('nbRevolt'); |
|
|
$fields['nbRevolt'] = TextField::new('nbRevolt'); |
|
|
$fields['nbProjectBoost'] = TextField::new('nbProjectBoost'); |
|
|
$fields['nbProjectBoost'] = TextField::new('nbProjectBoost'); |