Taxonomy term description field format not takes in account

Created on 14 January 2020, over 4 years ago
Updated 5 October 2023, 9 months ago

I added taxonomy term with HTML description.
I created view with taxonomy terms.
Added description field to view.
Use aggregation: yes.
Result: HTML tags are escaped:

<p>thickness ≀&nbsp;4 mm.</p>

If I in "Aggregation settings" \ "Group columns (additional)" I'll check "Format" - problem will be resolved.
But it is very unintuitive.

Problem in

  protected function createEntityForGroupBy(EntityInterface $entity, ResultRow $row) {
      ...
      foreach ($this->group_fields as $field_name => $column) {
        if (property_exists($row, $this->aliases[$column])) {
          $base_value[$field_name] = $row->{$this->aliases[$column]}; <-- Here is problem.

          if (isset($base_value[$field_name])) {
            $data = TRUE;
          }
        }
      }
      ...
  }

For description field $this->group_fields == ['value' => 'description__value']. There is no 'format' by default.
Therefore the description text renders as plain text.

I think "Format" checkbox should be checked by default.

πŸ› Bug report
Status

Active

Version

11.0 πŸ”₯

Component
ViewsΒ  β†’

Last updated 42 minutes ago

Created by

πŸ‡ΊπŸ‡¦Ukraine super_romeo Kiev

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡§πŸ‡ͺBelgium DieterHolvoet Brussels

    I just encountered the same issue with a smart_date field. If a field column is not checked in Group columns (additional), its value will not be loaded into the entity and will return NULL. In my case that broke date rendering, because only the start date of a date range was loaded.

Production build 0.69.0 2024