@smartico/public-api 0.0.345 → 0.0.346
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/dist/WSAPI/WSAPITypes.d.ts +2 -0
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +4 -2
- package/dist/index.modern.mjs.map +1 -1
- package/docs/api/interfaces/TStoreItem.md +8 -0
- package/package.json +1 -1
- package/src/Store/StoreItem.ts +1 -0
- package/src/WSAPI/WSAPITypes.ts +2 -0
|
@@ -521,6 +521,8 @@ export interface TStoreItem {
|
|
|
521
521
|
only_in_custom_section?: boolean;
|
|
522
522
|
/** ID of specific Custom Section type */
|
|
523
523
|
custom_section_type_id?: number;
|
|
524
|
+
/** The message that should be shown to the user if they are not eligible to buy it. This message can be used to explain the reason why user cannot buy the item, e.g. 'You should be VIP to buy this item'. */
|
|
525
|
+
cant_buy_message?: string;
|
|
524
526
|
}
|
|
525
527
|
/**
|
|
526
528
|
* TAchCategory describes the badge category item. Each badge item can be assigned to 1 or more categories
|
package/dist/index.js
CHANGED
|
@@ -1026,7 +1026,7 @@ var StoreItemTransform = function StoreItemTransform(items) {
|
|
|
1026
1026
|
return r.id >= 1;
|
|
1027
1027
|
}).map(function (r) {
|
|
1028
1028
|
var _r$itemPublicMeta$pri, _r$categoryIds;
|
|
1029
|
-
var x = {
|
|
1029
|
+
var x = _extends({
|
|
1030
1030
|
id: r.id,
|
|
1031
1031
|
name: r.itemPublicMeta.name,
|
|
1032
1032
|
purchase_type: mapPurchaseType$1(r.itemPublicMeta.purchase_type),
|
|
@@ -1051,7 +1051,9 @@ var StoreItemTransform = function StoreItemTransform(items) {
|
|
|
1051
1051
|
custom_section_id: r.itemPublicMeta.custom_section_id,
|
|
1052
1052
|
only_in_custom_section: r.itemPublicMeta.only_in_custom_section,
|
|
1053
1053
|
custom_section_type_id: r.itemPublicMeta.custom_section_type_id
|
|
1054
|
-
}
|
|
1054
|
+
}, r.itemPublicMeta.cant_buy_message ? {
|
|
1055
|
+
cant_buy_message: r.itemPublicMeta.cant_buy_message
|
|
1056
|
+
} : {});
|
|
1055
1057
|
return x;
|
|
1056
1058
|
});
|
|
1057
1059
|
};
|