From 98808b6caa963f5b150f26f58c386c4a8a429168 Mon Sep 17 00:00:00 2001 From: Shahed Nasser Date: Fri, 24 May 2024 15:04:44 +0300 Subject: [PATCH] fix(link-modules): remove duplicate fulfillment set location link (#7441) Remove the link defined in `location-fulfillment-set` because it's a duplicate of `fulfillment-set-location`. --- .../definitions/location-fulfillment-set.ts | 60 ------------------- 1 file changed, 60 deletions(-) delete mode 100644 packages/modules/link-modules/src/definitions/location-fulfillment-set.ts diff --git a/packages/modules/link-modules/src/definitions/location-fulfillment-set.ts b/packages/modules/link-modules/src/definitions/location-fulfillment-set.ts deleted file mode 100644 index cc39659544..0000000000 --- a/packages/modules/link-modules/src/definitions/location-fulfillment-set.ts +++ /dev/null @@ -1,60 +0,0 @@ -import { Modules } from "@medusajs/modules-sdk" -import { ModuleJoinerConfig } from "@medusajs/types" -import { LINKS } from "@medusajs/utils" - -export const LocationFulfillmentSet: ModuleJoinerConfig = { - serviceName: LINKS.LocationFulfillmentSet, - isLink: true, - databaseConfig: { - tableName: "location_fulfillment_set", - idPrefix: "locfs", - }, - alias: [ - { - name: ["location_fulfillment_set", "location_fulfillment_sets"], - args: { - entity: "LinkLocationFulfillmentSet", - }, - }, - ], - primaryKeys: ["id", "stock_location_id", "fulfillment_set_id"], - relationships: [ - { - serviceName: Modules.STOCK_LOCATION, - primaryKey: "id", - foreignKey: "stock_location_id", - alias: "location", - }, - { - serviceName: Modules.FULFILLMENT, - primaryKey: "id", - foreignKey: "fulfillment_set_id", - alias: "fulfillment_set", - deleteCascade: true, - }, - ], - extends: [ - { - serviceName: Modules.STOCK_LOCATION, - relationship: { - serviceName: LINKS.LocationFulfillmentSet, - primaryKey: "stock_location_id", - foreignKey: "id", - alias: "fulfillment_set_link", - isList: true, - }, - fieldAlias: { - fulfillment_sets: "fulfillment_set_link.fulfillment_set", - }, - }, - { - serviceName: Modules.FULFILLMENT, - relationship: { - serviceName: LINKS.LocationFulfillmentSet, - primaryKey: "fulfillment_set_id", - foreignKey: "id", - alias: "locations_link", - }, - }, - ], -}