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

Remove quotation marks from url #345

Merged
merged 2 commits into from
Apr 3, 2024

Conversation

Arif-Khalid
Copy link
Contributor

Summary:

Fixes #340

Type of change:

  • ✨ New Feature/ Enhancement

Changes Made:

  • Refactor code away from JSON.parse and JSON.stringify for filters in url where possible
  • Delete empty filters from url with intended behaviour to reset to default

Screenshots:

Default view URL before change

https://catcher-org.github.io/WATcher/issuesViewer?repo=catcher-org%2FCATcher
&title=""
&type="all"
&sort=%7B"active":"status","direction":"asc"%7D
&status=%5B"open%20pullrequest","merged%20pullrequest","open%20issue","closed%20issue"%5D
&milestones=%5B"V3.3.6","V3.3.7","V3.3.8"%5D&hiddenLabels=%5B%5D&deselectedLabels=%5B%5D
&labels=%5B%5D
&presetview=currentlyActive

Default view URL after change

http://localhost:4200/issuesViewer?repo=CATcher-org%2FCATcher
&type=all
&sort=%7B"active":"status","direction":"asc"%7D
&status=open%20pullrequest&status=merged%20pullrequest&status=open%20issue&status=closed%20issue
&milestones=V3.3.6&milestones=V3.3.7&milestones=V3.3.8
&presetview=currentlyActive&

Proposed Commit Message:

Quotation marks and null parameters are present for
filters saved in url.

Quotation marks are unnecessary and empty filters
can be removed from the URL in order to make it
more readable and editable by advanced users.

Let's remove null params and remove quotation marks
from the url.

Checklist:

  • I have tested my changes thoroughly.
  • I have created tests for any new code files created in this PR or provided a link to a issue/PR that addresses this.
  • I have added or modified code comments to improve code readability where necessary.
  • I have updated the project's documentation as necessary.

@Arif-Khalid Arif-Khalid added the category.Enhancement an enhancement to an existing feature label Apr 1, 2024
@Arif-Khalid Arif-Khalid self-assigned this Apr 1, 2024
Copy link
Contributor

@NereusWB922 NereusWB922 left a comment

Choose a reason for hiding this comment

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

LGTM!

@Arif-Khalid Arif-Khalid merged commit 99d2c72 into CATcher-org:main Apr 3, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category.Enhancement an enhancement to an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove quotation from filters in url
2 participants