- Issue created by @kenorb
- 🇬🇧United Kingdom kenorb
Did access them using different approach, by extending some classes.
Then loading them via{% set civicrm_entity = content.contact_type['#object'] %}
Some code customization which I did: https://www.drupal.org/project/civicrm_entity/issues/3382166#comment-152... ✨ Website URL not exposed Active - 🇺🇸United States markusa
Thanks!! We'll be looking into why these fields are not automatically available in the template as variables
- 🇵🇭Philippines dsdeiz
Yeah, it's supposed to be there. This is what I see on my end:
"custom_1" => array:18 [▼ "#theme" => "field" "#title" => "Test" "#label_display" => "hidden" "#view_mode" => "full" "#language" => "und" "#field_name" => "custom_1" "#field_type" => "string" "#field_translatable" => false "#entity_type" => "civicrm_contact" "#bundle" => "civicrm_contact" "#object" => Drupal\civicrm_entity\Entity\CivicrmEntity {#2727 ▶} "#items" => Drupal\Core\Field\FieldItemList {#2677 ▶} "#formatter" => "string" "#is_multiple" => false "#third_party_settings" => [] 0 => array:3 [▼ "#type" => "inline_template" "#template" => "{{ value|nl2br }}" "#context" => array:1 [▼ "value" => "1234" ] ] "#cache" => array:3 [▶] "#weight" => 0 ]
Maybe check if the the custom fields are enabled on the "Manage display"?
- Status changed to Closed: works as designed
7 months ago 8:44pm 25 April 2024 - 🇺🇸United States markusa
Did a custom template recently and the custom fields were available and showed values when the template was rendered.