Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add paused property for incentives [WIP] #631

Closed
wants to merge 3 commits into from

Conversation

veekas
Copy link
Member

@veekas veekas commented Dec 19, 2024

Description

  • Builds on top of Owen's end date PR
  • Filters out incentives that have yet to start (i.e. Connecticut)
  • Adds an active attribute for incentives and status-to-include to the endpoint attributes

Next steps

  • hide active === false ("inactive") incentives on RA's site
  • add functionality in the embed to filter out inactive incentives
  • add editable active field to HERO

oyamauchi and others added 3 commits December 19, 2024 08:44
## Description

Because of the more-than-just-a-day date formats we support, this is a
little bit subtle.

Note that this does not filter on incentive status, which we are not
exporting from HERO yet.

Note also that this uses @js-joda, a competent date/time library;
Javascript's native Date is a nightmare.

## Test Plan

Unit test of the new date logic. Snapshot tests reveal a bunch of
expired incentives that don't get returned anymore!
@veekas veekas requested a review from oyamauchi December 19, 2024 14:24
Base automatically changed from owen.end-date to main December 19, 2024 15:34
@oyamauchi
Copy link
Member

BTW, I know this PR is still open, but I'm holding off on reviewing it until we figure out the full story for incentive lifecycle, both here and in HERO.

@oyamauchi
Copy link
Member

Going to add WIP to the title to suppress the stale-PR notification in Slack.

@oyamauchi oyamauchi changed the title Filter incentives with start date in the future or are marked inactive Filter incentives with start date in the future or are marked inactive [WIP] Jan 28, 2025
@veekas veekas changed the title Filter incentives with start date in the future or are marked inactive [WIP] Add paused property for incentives [WIP] Feb 4, 2025
@veekas veekas closed this Feb 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants