fix(index): logical operators (#13137)
This commit is contained in:
@@ -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
|
||||
Reference in New Issue
Block a user