Skip to content

Sorting of PDS members by date created#2707

Merged
zFernand0 merged 8 commits into
zowe:mainfrom
SanthoshiBoyina:feat/sort-datecreated
Feb 15, 2024
Merged

Sorting of PDS members by date created#2707
zFernand0 merged 8 commits into
zowe:mainfrom
SanthoshiBoyina:feat/sort-datecreated

Conversation

@SanthoshiBoyina

Copy link
Copy Markdown
Contributor

Proposed changes

To add an additional PDS member sorting option that allows users to sort by Date Created.

Release Notes

Milestone:

Changelog:

Types of changes

What types of changes does your code introduce to Zowe Explorer?
Put an x in the boxes that apply

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Updates to Documentation or Tests (if none of the other choices apply)

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This checklist will be used as reference for both the contributor and the reviewer

  • I have read the CONTRIBUTOR GUIDANCE wiki
  • PR title follows Conventional Commits Guidelines
  • PR Description is included
  • gif or screenshot is included if visual changes are made
  • yarn workspace vscode-extension-for-zowe vscode:prepublish has been executed
  • All checks have passed (DCO, Jenkins and Code Coverage)
  • I have added unit test and it is passing
  • I have added integration test and it is passing
  • There is coverage for the code that I have added
  • I have tested it manually and there are no regressions found
  • I have added necessary documentation (if appropriate)
  • Any PR dependencies have been merged and published (if appropriate)

Further comments

Signed-off-by: Santhoshi Boyina <Santhoshi.Boyina1@ibm.com>
@codecov

codecov Bot commented Feb 8, 2024

Copy link
Copy Markdown

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (ef82a0e) 93.26% compared to head (7bba6e0) 93.24%.

Files Patch % Lines
...kages/zowe-explorer/src/dataset/ZoweDatasetNode.ts 92.50% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2707      +/-   ##
==========================================
- Coverage   93.26%   93.24%   -0.02%     
==========================================
  Files         102      102              
  Lines       10544    10562      +18     
  Branches     2260     2286      +26     
==========================================
+ Hits         9834     9849      +15     
- Misses        709      712       +3     
  Partials        1        1              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: Santhoshi Boyina <Santhoshi.Boyina1@ibm.com>
JillieBeanSim
JillieBeanSim previously approved these changes Feb 8, 2024

@JillieBeanSim JillieBeanSim left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM, did leave a comment regarding clean code if we want to go that route but good approving in it's state. Thanks @SanthoshiBoyina for the new Functionality.

}

if (sort.method === DatasetSortOpts.LastModified) {
if (sort.method === DatasetSortOpts.DateCreated) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

with the list growing for ways of sorting should we consider a switch/case in place of the continued if/else if's?

@JillieBeanSim JillieBeanSim added this to the v2.15.0 milestone Feb 8, 2024
Signed-off-by: Santhoshi Boyina <Santhoshi.Boyina1@ibm.com>
@JillieBeanSim JillieBeanSim self-requested a review February 13, 2024 15:32
JillieBeanSim
JillieBeanSim previously approved these changes Feb 13, 2024

@JillieBeanSim JillieBeanSim left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM! thanks @SanthoshiBoyina

adam-wolfe
adam-wolfe previously approved these changes Feb 13, 2024

@adam-wolfe adam-wolfe left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, thanks @SanthoshiBoyina

@traeok traeok left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, thanks @SanthoshiBoyina - I left a comment regarding the changelog entry and had a small question about handling the "created date" (c4date) property.

Comment thread packages/zowe-explorer/CHANGELOG.md Outdated
Comment thread packages/zowe-explorer/src/dataset/ZoweDatasetNode.ts Outdated
zFernand0 and others added 2 commits February 13, 2024 15:48
Signed-off-by: Santhoshi Boyina <Santhoshi.Boyina1@ibm.com>
@traeok traeok self-requested a review February 14, 2024 18:04

@traeok traeok left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM! Thanks for the enhancement and for addressing my feedback @SanthoshiBoyina 🙂

@sonarqubecloud

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
16.8% Duplication on New Code (required ≤ 3%)

See analysis details on SonarCloud

@zFernand0 zFernand0 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM! 😋
I'm curious what should we do about the member that don't have a c4date and/or m4date. Right now we fallback to sorting by name (which makes sense). The interesting part was that we use the same sort direction (descending). 🤔
I'm not suggesting we change it, it just surprised me to see a bunch of them without dates 😋

image

@JillieBeanSim

Copy link
Copy Markdown
Contributor

@SanthoshiBoyina make sure these changes are ported to the next branch, thanks 😄

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.

6 participants