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(cost-analysis-l-n-b-store): create cost-analysis-l-n-b-store #1702

Conversation

piggggggggy
Copy link
Member

To Reviewers

  • Skip (style, chore, ci ONLY)
  • Not that difficult

Type of Change

  • New feature
  • Bug fixes
  • Feature improvement
  • Refactor
  • Others (performance improvement, CI/CD, etc.)

Affects to

  • Packages

    • core-lib
    • mirinae
    • etc
  • Apps

    • storybook
    • web

Checklist

  • Did you check the lint and type?
  • Did you document the changes?
    • Changes in mirinae should be reflected in storybook.
  • Did you test the app after the package changes?

Description

SSIA

  • Create cost-analysis-l-n-b-store. Add Data-Source state
  • Separate Cost-Query logic from cost-analysis-page-store. (to cost-analysis-l-n-b-store)

@vercel
Copy link

vercel bot commented Aug 29, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
console ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 29, 2023 8:29am

Comment on lines 21 to 25
dataSourceList: [
'aws',
'azure',
'gcp',
],
Copy link
Member

Choose a reason for hiding this comment

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

question: this is mock data, right?

Copy link
Member Author

Choose a reason for hiding this comment

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

oh.. yes... I forgot that.. I'll remove them.

Copy link
Member

@WANZARGEN WANZARGEN left a comment

Choose a reason for hiding this comment

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

LGTM~ Nice refactoring!
It seems that the $reset() and $dispose() functions of this store are not being called at all in the code. It might be worth considering whether these functions should be executed during the creation or unmounting of the LNB, if that hasn't been reviewed already.

Comment on lines 21 to 25
dataSourceList: [
'aws',
'azure',
'gcp',
],
Copy link
Member

Choose a reason for hiding this comment

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

nitpick: Please add TODO comment not to miss updating it and to notify reviewers that this is not the mistake. :)

@@ -178,15 +158,15 @@ export const useCostAnalysisPageStore = defineStore('cost-analysis-page', {
name,
options,
});
this.selectedQueryId = createdData.cost_query_set_id;
costAnalysisLNBStore.$patch({ selectedQueryId: createdData.cost_query_set_id });
Copy link
Member

Choose a reason for hiding this comment

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

praise: Oh, I didn't know that we can use pinia store inside the other pinia store. 😮
Thank you for introducing me to a new way of using it.

Copy link
Member

@yuda110 yuda110 left a comment

Choose a reason for hiding this comment

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

LGTM!!!

@piggggggggy piggggggggy merged commit 7c886d3 into cloudforet-io:feature-cost-analysis-enhancement Aug 29, 2023
@piggggggggy piggggggggy deleted the feature-cost-analysis-enhancement branch August 29, 2023 09:23
sulmoJ pushed a commit to sulmoJ/console that referenced this pull request Oct 4, 2023
sulmoJ pushed a commit to sulmoJ/console that referenced this pull request Oct 4, 2023
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.

3 participants