fix(index): logical operators (#13137)

This commit is contained in:
Carlos R. L. Rodrigues
2025-08-07 07:34:50 -03:00
committed by GitHub
parent a52708769d
commit 9725bff25d
11 changed files with 373 additions and 125 deletions
@@ -0,0 +1,21 @@
import ProductModule from "@medusajs/medusa/product"
import { defineLink } from "@medusajs/utils"
import BrandModule from "../modules/brand"
const link =
process.env.ENABLE_INDEX_MODULE === "true"
? defineLink(
{
linkable: ProductModule.linkable.product.id,
filterable: ["description", "material"],
isList: true,
},
{
linkable: BrandModule.linkable.brand.id,
filterable: ["id", "name"],
isList: false,
}
)
: {}
export default link