0

Using Drupal 8 I've got a custom content type application and a ConfigEntityType application_type for bundles of it. I need each bundle to store a list of strings when newly created/edited. E.g. application type 'General application' needs to have a list of string values (cardinality unlimited).

As far as I know I should use the sequence type in application_type.schema.yml and tried the following (focus is on sender_group_type)

applications.application_type.*:
  type: config_entity
  label: 'Application type config'
  mapping:
    id:
    type: string
    label: 'ID'
  label:
    type: label
    label: 'Label'
  uuid:
    type: string
  sender_group_type:
    type: 'sequence'
    label: 'Allowed sender group types'
    sequence:
      type: 'string'

Would this allow me to store multiple strings when creating editing a new bundle? And how does this get stored? How do I add getters and setters or delete/add functionality in ApplicationType.php and ApplicationTypeForm.php ?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.