Bundle and display sync¶
Shared attributes between a path's pbpaths entry and the generated Drupal field, form display and view display stay in bidirectional sync:
| Concern | Pathbuilder (pbpaths) |
Drupal |
|---|---|---|
| Field id | field |
field storage / field config name |
| Field type | fieldtype |
field storage type |
| Form widget | displaywidget |
form display component type |
| View formatter | formatterwidget |
view display component type |
| Weight | weight (one value) |
form and view display weight |
| Cardinality | cardinality |
field storage cardinality |
pbpaths stores a single weight.
Saving either Manage form display or Manage display updates that weight (last write wins).
Save and generate then applies it to both displays.
Bundle to pathbuilder write-back runs on every save of a field storage or display, whoever saves it.
It needs no pathbuilder permission: anyone who may edit a bundle's fields or displays also updates the linked pbpaths.
Drush, module install and recipes run as anonymous and sync as well.
A config import (drush cim or the configuration UI) skips the write-back, because the imported pathbuilder config is authoritative.
- Pathbuilder to bundle: Configure Field stores the choice in
pbpaths. Save and generate bundles and fields writes the shared attributes onto Drupal field storage and form and view displays. Form and view use the same merge rule: the pathbuilder owns type and weight, and other component keys (settings, region, and so on) stay as set in the bundle UI. Existing bundles are only connected, so title pattern and menu settings stay. Fields that are hidden in a display stay hidden when generate does not recreate the field config. - Bundle to pathbuilder: saving field storage, form display or view display for
wisski_individualupdates every linked pathbuilderpbpathsentry for that field. After a bundle UI change, Configure Field shows the same widget, formatter, weight and cardinality, and a later generate does not revert them.
Kept in Drupal unless you change them in the pathbuilder: field label and description (help text), formatter and widget settings, and bundle-only data such as title pattern and menus. Path and group names in the pathbuilder stay ontology-oriented labels. Bundle and field labels stay UI labels.