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

feat: Add filter, group and sorting for created date #1744

Merged

Conversation

vanadium23
Copy link
Contributor

Description

Provide new query commands:

  • group by created date
  • sort by created date
  • filter with created date

Motivation and Context

I don't move group functionality from Grouper to DateField files, because it was not straightforward approach with current code. I think refactoring needs to be done via separated task.

Closes #1741 for filtering, grouping and sorting with created date field.

How has this been tested?

With unit tests, based on issue description.

Screenshots (if appropriate)

Types of changes

Changes visible to users:

  • Bug fix (prefix: fix - non-breaking change which fixes an issue)
  • New feature (prefix: feat - non-breaking change which adds functionality)
  • Breaking change (prefix: feat!! or fix!! - fix or feature that would cause existing functionality to not work as expected)
  • Documentation (prefix: docs - improvements to any documentation content)
  • Sample vault (prefix: vault - improvements to the Tasks-Demo sample vault)

Internal changes:

  • Refactor (prefix: refactor - non-breaking change which only improves the design or structure of existing code, and making no changes to its external behaviour)
  • Tests (prefix: test - additions and improvements to unit tests and the smoke tests)
  • Infrastructure (prefix: chore - examples include GitHub Actions, issue templates)

Checklist

Terms

Copy link
Collaborator

@claremacrae claremacrae left a comment

Choose a reason for hiding this comment

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

Great stuff. Thank you very much.

Comment on lines +180 to +182
When filtering queries by [start date]({{ site.baseurl }}{% link getting-started/dates.md %}#-start),
the result will include tasks without a start date.
This way, you can use the start date as a filter to filter out any tasks that you cannot yet work on.
Copy link
Collaborator

Choose a reason for hiding this comment

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

This bit looks like it is left over from text copied in.
I need to press on with some merging, and will need to edit the Created description anyway, as some more search features were added whilst you were working on this.
So, just to let you know that I will fix this.

@claremacrae
Copy link
Collaborator

It looks like this branch was created directly off your previous branch - feature-task-created-date.

As a general tip for the future, it's always best when creating a new branch for a new PR in any project, to get the latest on main, and create a new branch from there.

Luckily this time there were no extra conflicts, but that is not always the case, and it really helps those reviewing and merging if PRs come from the newest code at the point when work on the PR was started.

# Conflicts:
#	docs/quick-reference/index.md
@claremacrae claremacrae added scope: filters Additions and modifications to the search filters scope: task dates and times Requests for enhancements to types and formats of dates and times associated with tasks labels Mar 9, 2023
@claremacrae claremacrae merged commit 5dc5755 into obsidian-tasks-group:main Mar 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: filters Additions and modifications to the search filters scope: task dates and times Requests for enhancements to types and formats of dates and times associated with tasks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add filtering, sorting and grouping for created date
2 participants