-
Notifications
You must be signed in to change notification settings - Fork 0
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
[pull] develop from medusajs:develop #9
Conversation
…SC (#10661) * fix: add stock location for reservations only if related to correct SC * fix: update spec * fix: wrong SC id get in OE flow * fix: ensure test case has multiple SC and SLs
Reviewer's Guide by SourceryThis pull request updates the cart and order editing workflows to correctly handle inventory reservations when multiple sales channels are used. It also adds tests to verify the correct behavior. Sequence diagram for inventory confirmation with sales channel checksequenceDiagram
participant Cart
participant InventoryConfirmation
participant StockLocation
participant SalesChannel
Cart->>InventoryConfirmation: prepareConfirmInventoryInput()
InventoryConfirmation->>SalesChannel: Check sales_channel.id
alt sales_channel.id matches salesChannelId
InventoryConfirmation->>StockLocation: Add stock_location.id
StockLocation-->>InventoryConfirmation: Return location ID
else No match
InventoryConfirmation-->>Cart: Skip stock location
end
InventoryConfirmation-->>Cart: Return prepared inventory input
Class diagram for order edit workflow changesclassDiagram
class OrderEdit {
+confirmOrderEditRequest()
}
class InventoryConfirmation {
+prepareConfirmInventoryInput(data)
-validateSalesChannel()
}
class OrderItem {
+sales_channel_id
+variants
+items
}
OrderEdit --> InventoryConfirmation: uses
OrderEdit --> OrderItem: manages
note for InventoryConfirmation "Updated to check sales channel ID match"
note for OrderItem "Changed to use direct sales_channel_id"
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Important Review skippedBot user detected. To trigger a single review, invoke the You can disable this status message by setting the 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
See Commits and Changes for more details.
Created by pull[bot] (v2.0.0-alpha.1)
Can you help keep this open source service alive? 💖 Please sponsor : )
Summary by Sourcery
Bug Fixes: