@teko-builder/plugin-teko-product
Advanced tools
Comparing version 0.1.2 to 0.1.3
@@ -68,3 +68,3 @@ import { Api } from '@teko-builder/utils'; | ||
if (Object.keys((menuItem === null || menuItem === void 0 ? void 0 : menuItem.configs) || {}).length) { | ||
const _a = menuItem.configs, { price, providerIds, sellerIds, attributes } = _a, rest = __rest(_a, ["price", "providerIds", "sellerIds", "attributes"]); | ||
const _a = menuItem.configs, { price, providerIds, sellerIds, attributes, hasPromotions } = _a, rest = __rest(_a, ["price", "providerIds", "sellerIds", "attributes", "hasPromotions"]); | ||
searchBody.filter = rest; | ||
@@ -89,2 +89,5 @@ if (providerIds === null || providerIds === void 0 ? void 0 : providerIds.length) { | ||
} | ||
if (hasPromotions) { | ||
searchBody.filter.hasPromotions = !!hasPromotions; | ||
} | ||
} | ||
@@ -91,0 +94,0 @@ return searchBody; |
@@ -72,3 +72,3 @@ 'use strict'; | ||
if (Object.keys((menuItem === null || menuItem === void 0 ? void 0 : menuItem.configs) || {}).length) { | ||
const _a = menuItem.configs, { price, providerIds, sellerIds, attributes } = _a, rest = tslib.__rest(_a, ["price", "providerIds", "sellerIds", "attributes"]); | ||
const _a = menuItem.configs, { price, providerIds, sellerIds, attributes, hasPromotions } = _a, rest = tslib.__rest(_a, ["price", "providerIds", "sellerIds", "attributes", "hasPromotions"]); | ||
searchBody.filter = rest; | ||
@@ -93,2 +93,5 @@ if (providerIds === null || providerIds === void 0 ? void 0 : providerIds.length) { | ||
} | ||
if (hasPromotions) { | ||
searchBody.filter.hasPromotions = !!hasPromotions; | ||
} | ||
} | ||
@@ -95,0 +98,0 @@ return searchBody; |
@@ -169,2 +169,3 @@ /// <reference types="node" /> | ||
}; | ||
hasPromotions?: 0 | 1; | ||
}; | ||
@@ -194,2 +195,3 @@ sorting?: { | ||
priceGte?: string; | ||
hasPromotions?: boolean; | ||
}; | ||
@@ -196,0 +198,0 @@ pagination: { |
{ | ||
"name": "@teko-builder/plugin-teko-product", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"description": "Plugin Teko Product of Landing Builder", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
@@ -182,2 +182,6 @@ import { MenuItem } from '..'; | ||
totalAvailable: null, | ||
status: { | ||
sellable: true, | ||
sellingCode: 'hang_ban', | ||
}, | ||
}; | ||
@@ -184,0 +188,0 @@ |
@@ -204,2 +204,3 @@ import { UrlObject } from 'url'; | ||
}; | ||
hasPromotions?: 0 | 1; | ||
}; | ||
@@ -230,2 +231,3 @@ sorting?: { | ||
priceGte?: string; | ||
hasPromotions?: boolean; | ||
}; | ||
@@ -232,0 +234,0 @@ pagination: { |
@@ -97,4 +97,10 @@ import { | ||
if (Object.keys(menuItem?.configs || {}).length) { | ||
const { price, providerIds, sellerIds, attributes, ...rest } = | ||
menuItem.configs; | ||
const { | ||
price, | ||
providerIds, | ||
sellerIds, | ||
attributes, | ||
hasPromotions, | ||
...rest | ||
} = menuItem.configs; | ||
searchBody.filter = rest; | ||
@@ -119,2 +125,5 @@ if (providerIds?.length) { | ||
} | ||
if (hasPromotions) { | ||
searchBody.filter.hasPromotions = !!hasPromotions; | ||
} | ||
} | ||
@@ -121,0 +130,0 @@ return searchBody; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
54380
1378