Problem/Motivation

The current day formatter is returning nothing if times are configured for the current day, but the hours are being viewed outside of the open hours configured for that day.

Steps to reproduce

1. Create a display that uses the 'current day' formatter.
2. Configure a node with hours set for the current day, but not covering the current time. (Ex, if it's Thursday at 3pm, configure the hours field to be open on Thursdays from 4pm-5pm).
3. View the display - no values are displayed for the current day formatter. If you change the hours field to cover the current time, then the hours will be displayed by the current day formatter.

Proposed resolution

The current day formatter should show all hours for the current day, regardless of the time that the user is viewing the display. It should also show any comments that are configured for days that don't have hours. For example, if 'Closed' is set as the comment for the current day, that should be displayed by the formatter.

Comments

flitt1 created an issue. See original summary.

  • johnv committed 3f842a39 on 8.x-1.x
    Issue #3421744: 'Current day' formatter is empty when viewed outside of...
johnv’s picture

Status: Active » Fixed

This should work now in dev version .

The function keepCurrentDay() is refactored.

flitt1’s picture

Thank you for fixing this so quickly, it's working well in the latest release!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.