Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
ChangedItem
is similar to TimestampItem
and CreatedItem
, but their default formatter is not available to ChangedItem.
I have classed this is a bug, because currently there is no way to display ChangedItem
values when viewing entities.
Proposed resolution
Alter TimestampFormatter
's plugin definition to allow it to be used with ChangedItem
too.
Remaining tasks
None.
User interface changes
None.
API changes
None.
Comment | File | Size | Author |
---|---|---|---|
#11 | drupal_2415937_11.patch | 4.27 KB | Xano |
#7 | changed-date.png | 9.91 KB | tstoeckler |
#7 | changed-ago.png | 13.1 KB | tstoeckler |
Comments
Comment #1
XanoComment #2
XanoLet's do the same for
TimestampAgoFormatter
and fix a bug there while we're at it.Comment #5
tstoecklerTested this out by adding some display options to node and it works beautifully. Nice!
I found two nice bugs along the way, will open in a minute.
Comment #6
tstoecklerHere we go:
#2427195: The output of TimestampAgoFormatter should never be render cached
#2427203: $options in setDisplayOptions() should be optional
Comment #7
tstoecklerWell, why not share some screenshots, if I had to jump through all those hoops already :-)
Comment #8
alexpottGiven that we had to make this change I think we should include some tests.
Comment #9
XanoComment #11
XanoI added pass asserts and modules are now enabled more selectively.
Comment #14
tstoecklerWow, impressive test!
Comment #15
alexpottThis issue is a normal bug fix, and doesn't include any disruptive changes, so it is allowed per https://www.drupal.org/core/beta-changes. Committed 1fadbc0 and pushed to 8.0.x. Thanks!