Skip to content
Snippets Groups Projects

Replace file

1 unresolved thread

Closes #2648816

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
97 97 // Add support to link to the entity itself.
98 98 if ($this->getSetting('link_to_file')) {
99 99 $url = $this->fileUrlGenerator->generate($items->getEntity()->getFileUri());
100 $url->setOptions(['query' => ['changed' => $items->getEntity()->getChangedTime()]]);
  • Is this change documented somewhere? I can see some potential issues with this, we'll definitely want it mentioned in the CR at least

  • This was done to fix the caching issue reported in #93

  • I understand that, but still don't know if it is a good idea.

  • This only covers the base field formatter, which is used when the file entity itself is rendered. It doesn't work when for example displaying the file download link through a media entity. For that we'd need to update those formatters too.

    It's a similar solution as used by crop module for possibly changing crop/focal point settings on an image style and makes sense. I wonder if we could do this only if created and changed time is different?

  • Please register or sign in to reply
  • added 1 commit

    Compare with previous version

  • added 1 commit

    Compare with previous version

  • Kalle Vuorjoki added 194 commits

    added 194 commits

    Compare with previous version

  • Please register or sign in to reply
    Loading