Table of Contents

Dynamic form - localization

The aim of this tutorial is show the way, how to add localization for dynamic form.

What do you need before you start

01 Create new dynamic form

We will create new dynamic form for identity. From will be shown on identity detail on 'More information' tab.

Go to menu 'Settings' → 'Form definitions' and add new definition:

Define form attributes as bellow (required is code and name only, other attribute properties are optional for this tutorial):

02 Add localization

On form definition detail new tab 'Form localization' was added:

Copy form definition section from how-to, then go to core module frontend localization files (src/locales/…) and paste it under eav.eu-bcvsolutions-idm-core-model-entity-idmidentity section (or create her, if doesn't exist). Then localization values (attribute labels, helps, placeholders) can be edited:

"myform": {
  "label": "My awesome form",
  "help": "This is my new awesome form",
  "attributes": {
    "phone": {
      "label": "My phone",
      "help": "Enter your phone",
      "placeholder": "Enter your favorite phone"
    },
    "email": {
      "label": "My email",
      "help": "Enter your email",
      "placeholder": "Enter your favorite email"
    }
  }
}

03 Test

Go to identity detail and More information tab, you can see: