@param \Symfony\Component\Form\FormBuilderInterface $builder

@return $this
3723
protected function addHiddenInputs(FormBuilderInterface $builder)
    {
        $formData = $this->getClient()->getCreditCardCheckRequest();
        $builder->add(
            self::FIELD_CLIENT_API_CONFIG,
            HiddenType::class,
            [
                'label' => false,
                'data' => $formData->toJson(),
            ]
        );

        return $this;
    }
1263309
protected function applyTableFilters(ModelQueryBuilder $builder): self
    {
        if ($this->hasFilters() === true) {
            $filters = $this->getFilters();
            $this->areFiltersWithAnd() === true ?
                $builder->addFiltersWithAndToTable($filters) : $builder->addFiltersWithOrToTable($filters);
        }

        return $this;
    }
19243
public function setBuilder(IlluminateEloquentBuilder $builder = null)
    {
        // If no builder was provided,
        // we'll use the one from this repositorys model
        if (empty($builder)) {
            $builder = $this->getModel()->newQuery();
        }

        // Set repository builder
        $this->builder = $builder;

        return $this;
    }
400125
public function buildForm(FormBuilderInterface $builder, array $options)
    {
        $this->getFormFieldsExtended($builder, $options, 'extendedField');
        $this->getFormFieldsExtended($builder, $options, 'extendedFieldSecure');
    }
1094441
public function apply(Builder $builder)
    {
        $this->builder = $builder;

        foreach (array_filter($this->filters()) as $name => $value) {
            if (method_exists($this, $name)) {
                call_user_func_array([$this, $name], [$value]);
            }
        }

        return $this->builder;
    }
644659
public function addCardType(FormBuilderInterface $builder, array $options)
    {
        $builder->add(
            self::FIELD_CARD_TYPE,
            ChoiceType::class,
            [
                'choices' => $options[self::OPTIONS_FIELD_NAME][self::OPTION_CARD_TYPES],
                'label' => false,
                'required' => true,
                'expanded' => false,
                'multiple' => false,
                'placeholder' => false,
                'constraints' => [
                    $this->createNotBlankConstraint(),
                ],
            ]
        );

        return $this;
    }
610578
public function buildForm(FormBuilderInterface $builder, array $options)
	{
		$builder->add('name', TextType::class, array(
			'label' => 'Config name',
			'required' => true
		))
		->add('alias', TextType::class, array(
			'label' => 'Alias (interal use)',
			'required' => true 
		))
		->add('parameters', BaseCollectionType::class, array(
			'entry_type' => ParameterType::class,
			'label' => 'List of parameters',
			'allow_add' => true,
			'allow_delete' => true,
			'prototype' => true,
			'containerId' => 'parameters-collection'
		))
		->add('isDefault', CheckboxType::class, array(
			'label' => 'Configuration par défaut'
		));
	}
259529
public function addOnlineBankTransferType(FormBuilderInterface $builder, array $options)
    {
        $builder->add(
            static::FIELD_ONLINE_BANK_TRANSFER_TYPE,
            HiddenType::class,
            [
                'label' => false,
                'data' => PayoneApiConstants::ONLINE_BANK_TRANSFER_TYPE_EPS_ONLINE_BANK_TRANSFER,
            ]
        );

        return $this;
    }
980984
protected function addBankCheckDigit(FormBuilderInterface $builder)
    {
        $builder->add(
            static::FIELD_BANK_CHECK_DIGIT,
            TextType::class,
            [
                'label' => false,
                'required' => true,
                'constraints' => [
                ],
            ]
        );

        return $this;
    }
42490
public function buildForm(FormBuilderInterface $builder, array $options)
    {
        if (null !== $options['class']){
            $this->transformer->setClass($options['class']);
            $builder->addModelTransformer($this->transformer);
        }   
    }
461513
public function run(Builder $builder) : Builder
    {
        return $builder->whereHas('roles', function (Builder $query) {
            $query->where('slug', $this->request->get('role'));
        });
    }
1000239
protected function addWithInactive(Builder $builder)
    {
        $builder->macro('withInactive', function (Builder $builder) {

            $this->remove($builder, $builder->getModel());
            return $builder;
        });
    }
108728
public static function builder($builder = null)
    {
        if (is_object($builder)) {
            self::$builder = $builder;
        }

        return isset(self::$builder) ? self::$builder : self::$builder = new Builder;
    }
970083
public function run(Builder $builder): Builder
    {
        return $builder->where('created_at', '>', $this->request->input('created_at.start'))
            ->where('created_at', '<', $this->request->input('created_at.end'));
    }
963924
public function defineFormBuilder(FormBuilderInterface $formBuilder)
    {
        /** @var AbstractAdmin $admin */
        $admin = $this;

        $mapper = new \Compo\Sonata\AdminBundle\Form\FormMapper($admin->getFormContractor(), $formBuilder, $admin);

        $this->configureFormFields($mapper);

        foreach ($admin->getExtensions() as $extension) {
            $extension->configureFormFields($mapper);
        }

        $this->attachInlineValidator();
    }
439466
public function buildForm(FormBuilderInterface $builder, array $options)
    {
        foreach ($options['button_groups'] as $name => $config) {
            $builder->add($name, ButtonGroupType::class, $config);
        }
    }
672364
protected function addBankCode(FormBuilderInterface $builder)
    {
        $builder->add(
            static::FIELD_BANK_CODE,
            TextType::class,
            [
                'label' => false,
                'required' => true,
                'constraints' => [
                ],
            ]
        );

        return $this;
    }