-
Notifications
You must be signed in to change notification settings - Fork 50
Improved:Renamed the Ecomstore to productstore(#375) #650
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
base: bopis-2.0
Are you sure you want to change the base?
Improved:Renamed the Ecomstore to productstore(#375) #650
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Summary of Changes
Hello @SuyashSingh01, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
This pull request implements a significant refactoring effort aimed at standardizing the terminology used for store-related entities within the application. By consistently renaming "Ecomstore" to "ProductStore" across various layers, the change enhances code readability, maintainability, and aligns the codebase with a more precise domain language. This ensures that all references to product-related store configurations are uniformly represented, reducing potential confusion and improving future development.
Highlights
- Core Renaming: All instances of
Ecomstorehave been systematically renamed toProductStoreacross the application's codebase to enhance clarity and consistency in terminology. - State Management Update: The Vuex store module for
userhas been comprehensively updated to reflect the newcurrentProductStorenaming convention in its state properties, getters, actions, and mutations. - Service Layer Refactor: The
UserServicenow exposes agetCurrentProductStorefunction, replacing the previousgetCurrentEComStore, to align with the standardized naming. - Component-Level Adaptations: Various Vue components, including
App.vue,OrderDetailUpdated.vue,ProductDetail.vue, andSettings.vue, have been updated to correctly utilize the newcurrentProductStoregetter and property.
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in pull request comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request correctly renames Ecomstore to productstore across various files, which improves consistency and clarity. The changes are mostly straightforward refactoring. I've found one area in the Vuex actions where the implementation can be improved for better consistency by using the local state instead of an external library call. Also, there's a minor typo in the pull request title (Improved:Renamed should be Improved: Renamed). Overall, good work on this refactoring task.
| const previousEComStore = await useUserStore().getCurrentEComStore as any | ||
| // fetching the eComStore for updated facility | ||
| const eComStore = await UserService.getCurrentEComStore(token, facilityId); | ||
| const previousProductStore = await useUserStore().getCurrentEComStore as any |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For consistency and to rely on the local state as the source of truth, it's better to get the previous product store from the Vuex state directly. This avoids calling an external library with a now-inconsistent name (getCurrentEComStore) and also removes a potentially unnecessary await. The local state this.state.user.currentProductStore holds the correct value before the facility is updated.
const previousProductStore = this.state.user.currentProductStore;
Related Issues
Issue:dxp-component/375
Issue Link; hotwax/dxp-components#375
Improved:Replaced the Ecomstore to ProductStore at app level
Short Description and Why It's Useful
Screenshots of Visual Changes before/after (If There Are Any)
Contribution and Currently Important Rules Acceptance