feat: Completely revamp the pricing module (#7852)
* feat: Completely revamp the pricing module * chore: Update all places to the new pricing interfaces * fix: Remove unnecessary join to itself * chore: Add data migration for existing users * fix: Apply the correct index to price rule
This commit is contained in:
@@ -4,15 +4,14 @@ import {
|
||||
MapToConfig,
|
||||
Modules,
|
||||
} from "@medusajs/utils"
|
||||
import { Price, PriceList, PriceSet, RuleType } from "@models"
|
||||
import { Price, PriceList, PriceSet } from "@models"
|
||||
|
||||
export const joinerConfig = defineJoinerConfig(Modules.PRICING, {
|
||||
entityQueryingConfig: [PriceSet, PriceList, Price, RuleType],
|
||||
entityQueryingConfig: [PriceSet, PriceList, Price],
|
||||
linkableKeys: {
|
||||
price_set_id: PriceSet.name,
|
||||
price_list_id: PriceList.name,
|
||||
price_id: Price.name,
|
||||
rule_type_id: RuleType.name,
|
||||
},
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user