예제 #1
0
 /**
  * {@inheritdoc}
  */
 public function buildForm(FormBuilderInterface $builder, array $options)
 {
     $builder->add('sharing', 'choice', array('choices' => array('everyone' => 'Everyone', 'course' => 'Course', 'user' => 'User', 'group' => 'Group'), 'attr' => array('class' => 'sharing_options')))->add('search', 'hidden', array('attr' => array('class' => 'extra_hidden')))->add('role', 'choice', array('choices' => ToolResourceRights::getDefaultRoles()))->add('mask', 'choice', array('choices' => ToolResourceRights::getMaskList()));
 }
예제 #2
0
 /**
  * {@inheritdoc}
  */
 public function buildForm(FormBuilderInterface $builder, array $options)
 {
     $builder->add('role', 'choice', array('choices' => ToolResourceRights::getDefaultRoles()))->add('mask', 'choice', array('choices' => ToolResourceRights::getMaskList()));
 }
 /**
  * @inheritdoc
  */
 protected function configureFormFields(FormMapper $formMapper)
 {
     $formMapper->add('tool')->add('role', 'choice', array('choices' => ToolResourceRights::getDefaultRoles()))->add('mask', 'choice', array('choices' => ToolResourceRights::getMaskList()));
 }