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(ui): cache namespace selection. Closes #2439 #2441

Merged
merged 3 commits into from
Mar 13, 2020

Conversation

whynowy
Copy link
Member

@whynowy whynowy commented Mar 13, 2020

Closes #2439

Checklist:

  • Either (a) I've created an enhancement proposal and discussed it with the community, (b) this is a bug fix, or (c) this is a chore.
  • The title of the PR is (a) conventional, (b) states what changed, and (c) suffixes the related issues number. E.g. "fix(controller): Updates such and such. Fixes #1234".
  • I have written unit and/or e2e tests for my change. PRs without these are unlike to be merged.
  • Optional. I've added My organization is added to the USERS.md.
  • I've signed the CLA and required builds are green.

@whynowy whynowy changed the title feat(ui): cache namespace selection. Closes #2439 feat(ui): cache namespace selection. Closes #2439 [WIP][DO NOT MERGE] Mar 13, 2020
@whynowy whynowy changed the title feat(ui): cache namespace selection. Closes #2439 [WIP][DO NOT MERGE] feat(ui): cache namespace selection. Closes #2439 Mar 13, 2020
@@ -120,5 +120,13 @@ export const Utils = {
return false;
}
return wf.status.phase === 'Running';
},

setCachedNamespace(value: string): void {
Copy link
Contributor

Choose a reason for hiding this comment

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

minor - could this be a getter/setting method,

public get cachedNamespace() {..}

Copy link
Contributor

@alexec alexec Mar 13, 2020

Choose a reason for hiding this comment

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

maybe currentNamespace?

Copy link
Member Author

Choose a reason for hiding this comment

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

minor - could this be a getter/setting method,

public get cachedNamespace() {..}

It looks like it is not allowed to wrap them as a getter/setter methods in the block of

export const Utils = {
  // allowed
  functionName(): xxx {
     xxxxxx
  }

  // not allowed
  set xxxx(xxx: string){
    xxxxxxxx
  }
}

Copy link
Member Author

Choose a reason for hiding this comment

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

maybe currentNamespace?

I'm ok with either one. will change it to current.

@codecov
Copy link

codecov bot commented Mar 13, 2020

Codecov Report

❗ No coverage uploaded for pull request base (master@7094433). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #2441   +/-   ##
=========================================
  Coverage          ?   13.13%           
=========================================
  Files             ?       71           
  Lines             ?    25253           
  Branches          ?        0           
=========================================
  Hits              ?     3318           
  Misses            ?    21498           
  Partials          ?      437

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7094433...0b7a34a. Read the comment docs.

@alexec alexec added this to the v2.7 milestone Mar 13, 2020
@whynowy whynowy merged commit 1baa7ee into argoproj:master Mar 13, 2020
@whynowy whynowy deleted the remember_ns branch March 13, 2020 22:29
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.

Remember namespace across UI pages
2 participants