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

Move timestamps to ISO strings in lists #1401

Merged
merged 2 commits into from
Aug 31, 2023
Merged

Conversation

joanagmaia
Copy link
Contributor

@joanagmaia joanagmaia commented Aug 30, 2023

Changes proposed ✍️

  • Updated requests for "View more" in Members and Organizations dashboard to be between 2 dates. Exactly the same dates we apply on the dashboard's widgets
  • Updated date.filter.renderer.ts to properly parse values according to the operator. gt and between operators were using "YYYY-MM-DD" format which was requesting for the wrong periods. Currently we always send in ISO to backend and display in "YYYY-MM-DD" for frontend

What

🤖 Generated by Copilot at e8c17bd

The pull request updates the dashboard components and the date filter renderer to support more flexible and accurate filtering of data by date ranges. It uses a computed property periodRange and a new operator between to create and apply date filters for the allMembers and allOrganizations queries. It also modifies the dateApiFilterRenderer function to handle different date operators.

🤖 Generated by Copilot at e8c17bd

Sing, O Muse, of the skillful coder who refined the dashboard view
With cunning logic and periodRange, he filtered data anew
By joinedDate and lastActivityDate, he sorted members and organizations
Like Zeus who rules the seasons and the years, he wielded the between operator

Why

How

🤖 Generated by Copilot at e8c17bd

  • Changed the filters for the joinedDate and lastActivityDate properties of the allMembers and allOrganizations queries to use the between operator and the periodRange value instead of the greater than operator and the periodStartDate value. This allows the dashboard to show the members and organizations who joined or were active within the selected period, instead of only those who joined or were active after the start of the period. (link, link, link, link)
  • Replaced the computed property periodStartDate by the computed property periodRange, which returns an array of two dates: the start and the end of the selected period. This provides the periodRange value for the filters that use the between operator. (link, link)
  • Modified the dateApiFilterRenderer function to handle the between and not between operators for the date filters. The function now creates a filter object with an array of two dates: the start and the end of the day for each value in the input array. This allows the filters to use the between and not between operators for the date properties. (link)

Checklist ✅

  • Label appropriately with Feature, Improvement, or Bug.
  • Add screehshots to the PR description for relevant FE changes
  • New backend functionality has been unit-tested.
  • API documentation has been updated (if necessary) (see docs on API documentation).
  • Quality standards are met.

@joanagmaia joanagmaia added the Improvement Created by Linear-GitHub Sync label Aug 30, 2023
@joanagmaia joanagmaia self-assigned this Aug 30, 2023
Copy link
Member

@yeganathan18 yeganathan18 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀

@joanagmaia joanagmaia merged commit 63cdfb4 into main Aug 31, 2023
6 checks passed
@joanagmaia joanagmaia deleted the improvement/lists-timestamps branch August 31, 2023 09:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Improvement Created by Linear-GitHub Sync
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants