2017 © Pedro Peláez
 

symfony-bundle translation-form-bundle

Provides widget to manage entity's translations

image

uerka/translation-form-bundle

Provides widget to manage entity's translations

  • Saturday, March 31, 2018
  • by uerka
  • Repository
  • 2 Watchers
  • 3 Stars
  • 294 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 17 Versions
  • 9 % Grown

The README.md

UerkaTranslationFormBundle

Simplified version of https://github.com/a2lix/TranslationFormBundle. Supports only https://github.com/KnpLabs/DoctrineBehaviors. Supports symfony4, (*1)

Installation

composer require uerka/translation-form-bundle

Add to bundles:, (*2)

Symfony4 - bundles.php, (*3)

return [
    ...
    Uerka\TranslationFormBundle\UerkaTranslationFormBundle::class => ['all' => true],

Symfony3 - AppKernel.php, (*4)

public function registerBundles()
{
    $bundles = [
    ...
    new Uerka\TranslationFormBundle\UerkaTranslationFormBundle(),
}

Configuration

uerka_translation_form: 
    locales: ["ru", "en"]

Add theme to twig settings:, (*5)

twig:
    ...
    form_themes: 
        ...
        - '@UerkaTranslationForm/form/fields.html.twig'

Using form

...
use Uerka\TranslationFormBundle\Form\Type\TranslationsType;

class ExampleFormType extends AbstractType
{
    /**
     * {@inheritdoc}
     */
    public function buildForm(FormBuilderInterface $builder, array $options)
    {
        $builder
            ->add('translations', TranslationsType::class, [
                'locales' => ['ru', 'en', 'fr'], // optional, defaults to bundle's config
                'required_locales' => ['en'], // optional, defaults to bundle's config (equals to locale option)
                'fields' => [
                    'name' => [
                        'widget_class' => TextType::class, // optional, default TextType::class
                        'options' => [ // will be passed to field's options
                            'label' => 'form.label.name',
                        ],
                    ],
                    'shortDescription' => [
                        'widget_class' => TextareaType::class,
                        'options' => [
                            'label' => 'form.label.short_description',
                            'required' => false,
                        ]
                    ],
                ],
            ]);
            ...
       }
    ...
}

The Versions

31/03 2018

dev-master

9999999-dev https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

31/03 2018

0.4.3

0.4.3.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

31/03 2018

dev-fx-submit-listener

dev-fx-submit-listener https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

31/03 2018

0.4.2

0.4.2.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

31/03 2018

dev-fx-embedded-forms

dev-fx-embedded-forms https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

30/03 2018

0.4.1

0.4.1.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

23/01 2018

0.4.0

0.4.0.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

23/01 2018

dev-ft-made-all-locales-required-by-default

dev-ft-made-all-locales-required-by-default https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

13/01 2018

0.3.1

0.3.1.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

13/01 2018

dev-fx-add-classes

dev-fx-add-classes https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

13/01 2018

0.3.0

0.3.0.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

13/01 2018

dev-fx-form-widget-display

dev-fx-form-widget-display https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

12/01 2018

dev-ft-form-id

dev-ft-form-id https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

12/01 2018

0.2.2

0.2.2.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

12/01 2018

0.2.1

0.2.1.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

12/01 2018

0.2

0.2.0.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony3 translation doctrine2 i18n translatable internationalization symfony4 knplabs-behaviors

12/01 2018

0.1

0.1.0.0 https://github.com/Uerka/TranslationFormBundle

Provides widget to manage entity's translations

  Sources   Download

MIT

The Requires

 

by Avatar uerka

form symfony2 translation doctrine2 i18n translatable internationalization knplabs-behaviors