@ikas/storefront 1.0.17 → 1.0.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/index.es.js +10 -1
- package/build/index.js +10 -1
- package/package.json +1 -1
package/build/index.es.js
CHANGED
|
@@ -37010,12 +37010,19 @@ var IkasProductDetail = /** @class */ (function () {
|
|
|
37010
37010
|
return variant.variantValues.some(function (vvv) { return vvv.id === vv.id; });
|
|
37011
37011
|
});
|
|
37012
37012
|
});
|
|
37013
|
+
var variantWithStock = _this.product.variants.find(function (variant) {
|
|
37014
|
+
return variant.isActive &&
|
|
37015
|
+
variant.hasStock &&
|
|
37016
|
+
variantValues.every(function (vv) {
|
|
37017
|
+
return variant.variantValues.some(function (vvv) { return vvv.id === vv.id; });
|
|
37018
|
+
});
|
|
37019
|
+
});
|
|
37013
37020
|
var isSelected = _this.selectedVariant.variantValues.some(function (vv) { return vv.id === variantValue.id; });
|
|
37014
37021
|
if (variant) {
|
|
37015
37022
|
displayedVariantValues.push({
|
|
37016
37023
|
variant: variant,
|
|
37017
37024
|
variantValue: variantValue,
|
|
37018
|
-
hasStock:
|
|
37025
|
+
hasStock: !!variantWithStock,
|
|
37019
37026
|
isSelected: isSelected,
|
|
37020
37027
|
});
|
|
37021
37028
|
}
|
|
@@ -47329,6 +47336,8 @@ var IkasPageEditorViewModel = /** @class */ (function () {
|
|
|
47329
47336
|
IkasStorefrontConfig.salesChannelId = _storefront.salesChannelId;
|
|
47330
47337
|
if (routing === null || routing === void 0 ? void 0 : routing.priceListId)
|
|
47331
47338
|
IkasStorefrontConfig.priceListId = routing.priceListId;
|
|
47339
|
+
else
|
|
47340
|
+
IkasStorefrontConfig.priceListId = undefined;
|
|
47332
47341
|
IkasStorefrontConfig.routings = _storefront.routings;
|
|
47333
47342
|
IkasStorefrontConfig.stockPreference = this.theme.settings.stockPreference;
|
|
47334
47343
|
}
|
package/build/index.js
CHANGED
|
@@ -36990,12 +36990,19 @@ var IkasProductDetail = /** @class */ (function () {
|
|
|
36990
36990
|
return variant.variantValues.some(function (vvv) { return vvv.id === vv.id; });
|
|
36991
36991
|
});
|
|
36992
36992
|
});
|
|
36993
|
+
var variantWithStock = _this.product.variants.find(function (variant) {
|
|
36994
|
+
return variant.isActive &&
|
|
36995
|
+
variant.hasStock &&
|
|
36996
|
+
variantValues.every(function (vv) {
|
|
36997
|
+
return variant.variantValues.some(function (vvv) { return vvv.id === vv.id; });
|
|
36998
|
+
});
|
|
36999
|
+
});
|
|
36993
37000
|
var isSelected = _this.selectedVariant.variantValues.some(function (vv) { return vv.id === variantValue.id; });
|
|
36994
37001
|
if (variant) {
|
|
36995
37002
|
displayedVariantValues.push({
|
|
36996
37003
|
variant: variant,
|
|
36997
37004
|
variantValue: variantValue,
|
|
36998
|
-
hasStock:
|
|
37005
|
+
hasStock: !!variantWithStock,
|
|
36999
37006
|
isSelected: isSelected,
|
|
37000
37007
|
});
|
|
37001
37008
|
}
|
|
@@ -47306,6 +47313,8 @@ var IkasPageEditorViewModel = /** @class */ (function () {
|
|
|
47306
47313
|
IkasStorefrontConfig.salesChannelId = _storefront.salesChannelId;
|
|
47307
47314
|
if (routing === null || routing === void 0 ? void 0 : routing.priceListId)
|
|
47308
47315
|
IkasStorefrontConfig.priceListId = routing.priceListId;
|
|
47316
|
+
else
|
|
47317
|
+
IkasStorefrontConfig.priceListId = undefined;
|
|
47309
47318
|
IkasStorefrontConfig.routings = _storefront.routings;
|
|
47310
47319
|
IkasStorefrontConfig.stockPreference = this.theme.settings.stockPreference;
|
|
47311
47320
|
}
|