idosell 0.3.11 → 0.3.15
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/changelog.md +24 -1
- package/dist/app.d.ts +2 -2
- package/dist/enums.d.ts +227 -11
- package/dist/enums.js +228 -10
- package/dist/gateways.d.ts +75 -16
- package/dist/helpers.js +76 -11
- package/dist/methods/getOrdersAuctionDetails.js +3 -3
- package/dist/methods/getProductsAuctions.js +2 -2
- package/dist/methods/getProductsDescriptions.js +3 -0
- package/dist/methods/getReturns.js +1 -0
- package/dist/methods/getVouchers.js +1 -0
- package/dist/methods/postEntries.js +1 -1
- package/dist/methods/postOrders.js +1 -1
- package/dist/methods/postOrdersDocuments.js +4 -1
- package/dist/methods/postOrdersImages.js +1 -1
- package/dist/methods/postProducts.js +0 -1
- package/dist/methods/putClients.js +1 -1
- package/dist/methods/putProductsAttachments.js +4 -0
- package/dist/methods/putProductsDescriptions.js +3 -2
- package/dist/methods/putProductsGroupsMainProduct.js +4 -0
- package/dist/methods/putProductsGroupsSettings.js +4 -0
- package/dist/methods/putProductsOmnibusPrices.js +6 -0
- package/dist/methods/putProductsQuestions.js +4 -0
- package/dist/methods/putProductsStrikethroughPrices.js +8 -1
- package/dist/methods/searchOrders.js +2 -2
- package/dist/methods/searchOrdersUnfinished.js +2 -2
- package/dist/methods/searchPackages.js +2 -1
- package/dist/methods/searchProducts.js +2 -2
- package/dist/methods/searchProductsDeliveryTime.js +1 -1
- package/dist/params.js +2 -1
- package/dist/request.js +31 -6
- package/dist/responses.d.ts +192 -10
- package/package.json +1 -1
- package/tests/deleteClients.test.js +1 -1
- package/tests/deleteClientsDeliveryAddress.test.js +1 -1
- package/tests/deleteClientsGiftcards.test.js +1 -1
- package/tests/deleteClientsPayerAddress.test.js +1 -1
- package/tests/deleteClientsPricelists.test.js +1 -1
- package/tests/deleteClientsTags.test.js +1 -1
- package/tests/deleteClientsTagsClear.test.js +1 -1
- package/tests/deleteConfigVariables.test.js +1 -1
- package/tests/deleteCouriersPickupPoints.test.js +1 -1
- package/tests/deleteCpa.test.js +1 -1
- package/tests/deleteCpaCampaign.test.js +1 -1
- package/tests/deleteDiscountsGroups.test.js +1 -1
- package/tests/deleteDiscountsGroupsProducts.test.js +1 -1
- package/tests/deleteDiscountsRebatesCard.test.js +1 -1
- package/tests/deleteDiscountsRebatesCode.test.js +1 -1
- package/tests/deleteEntries.test.js +1 -1
- package/tests/deleteMenu.test.js +1 -1
- package/tests/deleteOrdersDocuments.test.js +1 -1
- package/tests/deleteOrdersImages.test.js +1 -1
- package/tests/deleteProducts.test.js +1 -1
- package/tests/deleteProductsBrands.test.js +1 -1
- package/tests/deleteProductsCollectionsProducts.test.js +1 -1
- package/tests/deleteProductsImages.test.js +1 -1
- package/tests/deleteProductsOpinions.test.js +1 -1
- package/tests/deleteProductsParameters.test.js +1 -1
- package/tests/deleteProductsProductsToFacebookCatalog.test.js +1 -1
- package/tests/deleteProductsProductsToPromotion.test.js +1 -1
- package/tests/deleteProductsSeries.test.js +1 -1
- package/tests/deleteProductsSizes.test.js +1 -1
- package/tests/deleteResponsibilityEntities.test.js +1 -1
- package/tests/deleteSizecharts.test.js +1 -1
- package/tests/deleteSnippets.test.js +1 -1
- package/tests/deleteSnippetsCampaign.test.js +1 -1
- package/tests/deleteSnippetsCookies.test.js +1 -1
- package/tests/deleteVouchers.test.js +1 -1
- package/tests/deleteWarranties.test.js +1 -1
- package/tests/deleteWmsStocksdocumentsDocuments.test.js +1 -1
- package/tests/deleteWmsStocksdocumentsProducts.test.js +2 -2
- package/tests/deleteWmsSuppliers.test.js +1 -1
- package/tests/getClients.test.js +4 -4
- package/tests/getClientsBalance.test.js +4 -4
- package/tests/getClientsDeliveryAddress.test.js +1 -1
- package/tests/getClientsGiftcardsTypes.test.js +1 -1
- package/tests/getClientsMembershipCards.test.js +1 -1
- package/tests/getClientsPayerAddress.test.js +3 -3
- package/tests/getClientsPricelists.test.js +2 -2
- package/tests/getClientsPricelistsClients.test.js +1 -1
- package/tests/getClientsPricelistsProducts.test.js +3 -3
- package/tests/getClientsPricesDiscountGroups.test.js +2 -2
- package/tests/getClientsPricesDiscounts.test.js +5 -5
- package/tests/getClientsProfitPoints.test.js +3 -3
- package/tests/getClientsProvinceList.test.js +1 -1
- package/tests/getClientsTags.test.js +1 -1
- package/tests/getConfigVariables.test.js +1 -1
- package/tests/getCouriers.test.js +4 -3
- package/tests/getCouriersPickupPoints.test.js +5 -5
- package/tests/getCpa.test.js +2 -2
- package/tests/getCpaCampaign.test.js +2 -2
- package/tests/getDeliveriesProfiles.test.js +1 -1
- package/tests/getDeliveriesRegions.test.js +1 -1
- package/tests/getDiscountsGroups.test.js +2 -2
- package/tests/getDiscountsGroupsClients.test.js +1 -1
- package/tests/getEntries.test.js +2 -2
- package/tests/getEntriesPagesToDisplay.test.js +1 -1
- package/tests/getEntriesSources.test.js +1 -1
- package/tests/getMenu.test.js +4 -4
- package/tests/getMenuFilter.test.js +3 -3
- package/tests/getOrders.test.js +1 -1
- package/tests/getOrdersAnalytics.test.js +1 -1
- package/tests/getOrdersAuctionDetails.test.js +13 -3
- package/tests/getOrdersDocuments.test.js +1 -1
- package/tests/getOrdersExportdocumentsEPP.test.js +6 -16
- package/tests/getOrdersExportdocumentsJPK.test.js +4 -4
- package/tests/getOrdersHandler.test.js +1 -1
- package/tests/getOrdersHistory.test.js +1 -1
- package/tests/getOrdersImages.test.js +1 -1
- package/tests/getOrdersLabels.test.js +1 -1
- package/tests/getOrdersOpinionsRate.test.js +3 -3
- package/tests/getOrdersPackages.test.js +7 -7
- package/tests/getOrdersProfitability.test.js +1 -1
- package/tests/getOrdersWarehouse.test.js +1 -1
- package/tests/getPackagesLabels.test.js +1 -1
- package/tests/getPayments.test.js +4 -9
- package/tests/getPaymentsForms.test.js +1 -1
- package/tests/getPaymentsProfiles.test.js +1 -1
- package/tests/getProducts.test.js +1 -1
- package/tests/getProductsAuctions.test.js +9 -3
- package/tests/getProductsBrands.test.js +1 -1
- package/tests/getProductsBrandsFilter.test.js +4 -3
- package/tests/getProductsCategories.test.js +3 -3
- package/tests/getProductsCodeExistence.test.js +2 -2
- package/tests/getProductsDescriptions.test.js +6 -1
- package/tests/getProductsIdBySizecode.test.js +1 -1
- package/tests/getProductsMarketingAllFacebookCatalogIds.test.js +1 -1
- package/tests/getProductsMarketingPromotion.test.js +2 -2
- package/tests/getProductsMarketingZones.test.js +2 -2
- package/tests/getProductsOmnibusPrices.test.js +2 -2
- package/tests/getProductsOpinions.test.js +3 -3
- package/tests/getProductsOpinionsRate.test.js +2 -2
- package/tests/getProductsProductsToFacebookCatalog.test.js +4 -3
- package/tests/getProductsQuestions.test.js +2 -2
- package/tests/getProductsReservations.test.js +2 -2
- package/tests/getProductsSKUbyBarcode.test.js +1 -1
- package/tests/getProductsSeries.test.js +4 -4
- package/tests/getProductsSeriesFilter.test.js +3 -2
- package/tests/getProductsSizes.test.js +2 -2
- package/tests/getProductsStocks.test.js +2 -2
- package/tests/getProductsStrikethroughPrices.test.js +2 -2
- package/tests/getRefundsGetPossibleAutoRefunds.test.js +1 -1
- package/tests/getRefundsGetRefundStatus.test.js +1 -1
- package/tests/getRefundsRetrieveRefundsList.test.js +1 -1
- package/tests/getResponsibilityEntities.test.js +1 -1
- package/tests/getReturns.test.js +6 -6
- package/tests/getRma.test.js +3 -3
- package/tests/getSizecharts.test.js +3 -3
- package/tests/getSizes.test.js +1 -1
- package/tests/getSnippets.test.js +1 -1
- package/tests/getSnippetsCampaign.test.js +1 -1
- package/tests/getSnippetsCookies.test.js +1 -1
- package/tests/getSystemCurrencies.test.js +2 -2
- package/tests/getSystemProcessesAutomation.test.js +1 -1
- package/tests/getSystemUnits.test.js +1 -1
- package/tests/getSystemUsers.test.js +1 -1
- package/tests/getVouchers.test.js +5 -5
- package/tests/getVouchersTypes.test.js +1 -1
- package/tests/getWarranties.test.js +2 -2
- package/tests/getWarrantiesCountTotal.test.js +1 -1
- package/tests/getWmsLocations.test.js +3 -3
- package/tests/getWmsStocksdocumentsDocuments.test.js +10 -10
- package/tests/getWmsStocksdocumentsOpenedDocuments.test.js +4 -4
- package/tests/getWmsStocksdocumentsProducts.test.js +2 -7
- package/tests/getWmsSuppliers.test.js +3 -3
- package/tests/postClients.test.js +1 -1
- package/tests/postClientsBalance.test.js +3 -3
- package/tests/postClientsDeliveryAddress.test.js +1 -1
- package/tests/postClientsGiftcards.test.js +1 -1
- package/tests/postClientsPayerAddress.test.js +1 -1
- package/tests/postClientsPricelists.test.js +2 -2
- package/tests/postClientsProfitPoints.test.js +1 -1
- package/tests/postClientsTags.test.js +1 -1
- package/tests/postCouriersPickupPoints.test.js +1 -1
- package/tests/postCpa.test.js +1 -1
- package/tests/postCpaCampaign.test.js +1 -1
- package/tests/postDeliveriesRegions.test.js +1 -1
- package/tests/postDiscountsGroups.test.js +1 -1
- package/tests/postDiscountsRebatesCard.test.js +1 -1
- package/tests/postDiscountsRebatesCode.test.js +1 -1
- package/tests/postEntries.test.js +5 -5
- package/tests/postMenu.test.js +1 -1
- package/tests/postOrders.test.js +2 -2
- package/tests/postOrdersDocuments.test.js +6 -1
- package/tests/postOrdersDocumentsCreate.test.js +1 -1
- package/tests/postOrdersImages.test.js +2 -2
- package/tests/postOrdersPackages.test.js +1 -1
- package/tests/postPackages.test.js +1 -1
- package/tests/postPackagesLabels.test.js +1 -1
- package/tests/postPayments.test.js +1 -1
- package/tests/postPaymentsCancel.test.js +1 -1
- package/tests/postPaymentsCashback.test.js +1 -1
- package/tests/postPaymentsRepayment.test.js +1 -1
- package/tests/postProducts.test.js +5 -5
- package/tests/postProductsBrands.test.js +1 -1
- package/tests/postProductsCollections.test.js +1 -1
- package/tests/postProductsCollectionsProducts.test.js +1 -1
- package/tests/postProductsMarketingPromotion.test.js +1 -1
- package/tests/postProductsOpinions.test.js +1 -1
- package/tests/postProductsProductsToFacebookCatalog.test.js +1 -1
- package/tests/postProductsProductsToPromotion.test.js +1 -1
- package/tests/postProductsRestore.test.js +1 -1
- package/tests/postRefundsAddAutomaticRefund.test.js +1 -1
- package/tests/postRefundsAddAutomaticRefundForOrder.test.js +1 -1
- package/tests/postRefundsAddManualRefund.test.js +1 -1
- package/tests/postResponsibilityEntities.test.js +1 -1
- package/tests/postReturns.test.js +2 -2
- package/tests/postSnippets.test.js +1 -1
- package/tests/postSnippetsCampaign.test.js +1 -1
- package/tests/postSnippetsCookies.test.js +1 -1
- package/tests/postVouchers.test.js +1 -1
- package/tests/postWarranties.test.js +1 -1
- package/tests/postWmsStocksdocumentsDocuments.test.js +1 -1
- package/tests/postWmsStocksdocumentsProducts.test.js +1 -1
- package/tests/putClients.test.js +2 -2
- package/tests/putClientsDeliveryAddress.test.js +1 -1
- package/tests/putClientsExternalCode.test.js +1 -1
- package/tests/putClientsGiftcards.test.js +3 -3
- package/tests/putClientsGiftcardsBlock.test.js +1 -1
- package/tests/putClientsGiftcardsUnblock.test.js +1 -1
- package/tests/putClientsMembershipCards.test.js +1 -1
- package/tests/putClientsPayerAddress.test.js +1 -1
- package/tests/putClientsPricelists.test.js +1 -1
- package/tests/putClientsPricelistsClients.test.js +1 -1
- package/tests/putClientsPricelistsProducts.test.js +1 -1
- package/tests/putClientsPricelistsRename.test.js +1 -1
- package/tests/putClientsPricesDiscounts.test.js +1 -1
- package/tests/putClientsTags.test.js +1 -1
- package/tests/putConfigVariables.test.js +1 -1
- package/tests/putCouriersPickupPoints.test.js +1 -1
- package/tests/putCpa.test.js +1 -1
- package/tests/putCpaCampaign.test.js +1 -1
- package/tests/putDeliveriesDefaultProfiles.test.js +1 -1
- package/tests/putDiscountsGroups.test.js +1 -1
- package/tests/putDiscountsGroupsProducts.test.js +1 -1
- package/tests/putDiscountsRebatesBlockCard.test.js +1 -1
- package/tests/putDiscountsRebatesUnblockCard.test.js +1 -1
- package/tests/putEntries.test.js +1 -1
- package/tests/putMenu.test.js +1 -1
- package/tests/putMenuFilter.test.js +2 -2
- package/tests/putMenuSort.test.js +1 -1
- package/tests/putOrders.test.js +1 -1
- package/tests/putOrdersCourier.test.js +1 -1
- package/tests/putOrdersDeliveryAddress.test.js +1 -1
- package/tests/putOrdersDevide.test.js +3 -3
- package/tests/putOrdersHandler.test.js +1 -1
- package/tests/putOrdersPackages.test.js +1 -1
- package/tests/putOrdersPickupPoint.test.js +1 -1
- package/tests/putOrdersProductsSerialNumbers.test.js +1 -1
- package/tests/putOrdersProfitMargin.test.js +1 -1
- package/tests/putOrdersShippingCosts.test.js +1 -1
- package/tests/putOrdersWarehouse.test.js +1 -1
- package/tests/putPackages.test.js +1 -1
- package/tests/putPayments.test.js +1 -1
- package/tests/putPaymentsConfirm.test.js +1 -1
- package/tests/putProducts.test.js +7 -7
- package/tests/putProductsAttachments.test.js +6 -1
- package/tests/putProductsBrands.test.js +1 -1
- package/tests/putProductsBrandsFilter.test.js +1 -1
- package/tests/putProductsCategories.test.js +1 -1
- package/tests/putProductsCollectionsProducts.test.js +1 -1
- package/tests/putProductsCollectionsRenew.test.js +1 -1
- package/tests/putProductsDescriptions.test.js +7 -2
- package/tests/putProductsGroupsMainProduct.test.js +6 -1
- package/tests/putProductsGroupsOrder.test.js +2 -2
- package/tests/putProductsGroupsSettings.test.js +6 -1
- package/tests/putProductsImages.test.js +5 -5
- package/tests/putProductsMarketingPromotion.test.js +1 -1
- package/tests/putProductsMarketingZones.test.js +1 -1
- package/tests/putProductsOmnibusPrices.test.js +16 -1
- package/tests/putProductsOpinions.test.js +1 -1
- package/tests/putProductsParameters.test.js +1 -1
- package/tests/putProductsQuestions.test.js +1 -1
- package/tests/putProductsSeries.test.js +1 -1
- package/tests/putProductsSeriesFilter.test.js +2 -2
- package/tests/putProductsSizes.test.js +1 -1
- package/tests/putProductsStockQuantity.test.js +1 -1
- package/tests/putProductsStocks.test.js +1 -1
- package/tests/putProductsStrikethroughPrices.test.js +17 -2
- package/tests/putProductsSupplierCode.test.js +1 -1
- package/tests/putProductsSupplierProductData.test.js +1 -1
- package/tests/putRefundsCancelRefund.test.js +1 -1
- package/tests/putRefundsConfirmRefund.test.js +1 -1
- package/tests/putRefundsUpdateRefund.test.js +1 -1
- package/tests/putResponsibilityEntities.test.js +1 -1
- package/tests/putReturns.test.js +1 -1
- package/tests/putReturnsSerialNumber.test.js +1 -1
- package/tests/putRma.test.js +1 -1
- package/tests/putSizecharts.test.js +1 -1
- package/tests/putSizes.test.js +3 -3
- package/tests/putSnippets.test.js +1 -1
- package/tests/putSnippetsCampaign.test.js +1 -1
- package/tests/putSnippetsCookies.test.js +1 -1
- package/tests/putSystemConfig.test.js +1 -1
- package/tests/putSystemCurrencies.test.js +1 -1
- package/tests/putSystemProcessesAutomation.test.js +1 -1
- package/tests/putSystemUnits.test.js +1 -1
- package/tests/putVouchers.test.js +1 -1
- package/tests/putVouchersBlock.test.js +1 -1
- package/tests/putVouchersUnblock.test.js +1 -1
- package/tests/putWarranties.test.js +1 -1
- package/tests/putWarrantiesLanguageData.test.js +1 -1
- package/tests/putWmsStocksdocumentsAcceptMM.test.js +1 -1
- package/tests/putWmsStocksdocumentsClose.test.js +1 -1
- package/tests/putWmsStocksdocumentsDocuments.test.js +1 -1
- package/tests/putWmsStocksdocumentsProducts.test.js +1 -1
- package/tests/putWmsStocksdocumentsRejectMM.test.js +1 -1
- package/tests/putWmsSuppliers.test.js +1 -1
- package/tests/searchClientsCrm.test.js +4 -4
- package/tests/searchClientsGiftcards.test.js +1 -1
- package/tests/searchClientsNewsletterEmail.test.js +2 -2
- package/tests/searchClientsNewsletterSms.test.js +3 -3
- package/tests/searchOrders.test.js +12 -12
- package/tests/searchOrdersOpinions.test.js +6 -6
- package/tests/searchOrdersUnfinished.test.js +6 -6
- package/tests/searchPackages.test.js +4 -4
- package/tests/searchProducts.test.js +16 -16
- package/tests/searchProductsCategoriesIdosell.test.js +1 -1
- package/tests/searchProductsDeliveryTime.test.js +3 -3
- package/tests/searchProductsParameters.test.js +3 -3
- package/tests/url.test.js +2 -2
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteProductsSizesSizes", () => {
|
|
5
|
-
const params = idosell().deleteProductsSizes.mode("delete_by_size").productId(49).sizes([{"sizeId": "2"}]).
|
|
5
|
+
const params = idosell().deleteProductsSizes.mode("delete_by_size").productId(49).sizes([{"sizeId": "2"}]).checkParams();
|
|
6
6
|
expect(params).toEqual({"mode":"delete_by_size","params":[{"productId":49,"sizes":[{"sizeId":"2"}]}]});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteResponsibilityEntitiesType", () => {
|
|
5
|
-
const params = idosell().deleteResponsibilityEntities.code("XO").type("producer").
|
|
5
|
+
const params = idosell().deleteResponsibilityEntities.code("XO").type("producer").checkParams();
|
|
6
6
|
expect(params).toEqual({"code":"XO","type":"producer"});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteSizechartsIds", () => {
|
|
5
|
-
const params = idosell().deleteSizecharts.ids([6]).
|
|
5
|
+
const params = idosell().deleteSizecharts.ids([6]).checkParams();
|
|
6
6
|
expect(params).toEqual({"ids":[6]});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteSnippetsId", () => {
|
|
5
|
-
const params = idosell().deleteSnippets.id(1).
|
|
5
|
+
const params = idosell().deleteSnippets.id(1).checkParams();
|
|
6
6
|
expect(params).toEqual({"id":1});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteSnippetsCampaignId", () => {
|
|
5
|
-
const params = idosell().deleteSnippetsCampaign.id(1).
|
|
5
|
+
const params = idosell().deleteSnippetsCampaign.id(1).checkParams();
|
|
6
6
|
expect(params).toEqual({"id":1});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteSnippetsCookiesId", () => {
|
|
5
|
-
const params = idosell().deleteSnippetsCookies.id(1).
|
|
5
|
+
const params = idosell().deleteSnippetsCookies.id(1).checkParams();
|
|
6
6
|
expect(params).toEqual({"id":1});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteVouchersId", () => {
|
|
5
|
-
const params = idosell().deleteVouchers.id(1).
|
|
5
|
+
const params = idosell().deleteVouchers.id(1).checkParams();
|
|
6
6
|
expect(params).toEqual({"vouchers":[{"id":1}]});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteWarrantiesWarranty_ids", () => {
|
|
5
|
-
const params = idosell().deleteWarranties.warranty_ids([6]).
|
|
5
|
+
const params = idosell().deleteWarranties.warranty_ids([6]).checkParams();
|
|
6
6
|
expect(params).toEqual({"warranty_ids":[6]});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteWmsStocksdocumentsDocumentsId", () => {
|
|
5
|
-
const params = idosell().deleteWmsStocksdocumentsDocuments.type("pz").id(2).
|
|
5
|
+
const params = idosell().deleteWmsStocksdocumentsDocuments.type("pz").id(2).checkParams();
|
|
6
6
|
expect(params).toEqual({"type":"pz","id":2});
|
|
7
7
|
})
|
|
@@ -2,11 +2,11 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteWmsStocksdocumentsProductsProduct", () => {
|
|
5
|
-
const params = idosell().deleteWmsStocksdocumentsProducts.type("pz").id(1).product(33).
|
|
5
|
+
const params = idosell().deleteWmsStocksdocumentsProducts.type("pz").id(1).product(33).checkParams();
|
|
6
6
|
expect(params).toEqual({"type":"pz","id":1,"products":[{"product":33}]});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("deleteWmsStocksdocumentsProductsSize", () => {
|
|
10
|
-
const params = idosell().deleteWmsStocksdocumentsProducts.type("pz").id(1).product(33).size("uniw").
|
|
10
|
+
const params = idosell().deleteWmsStocksdocumentsProducts.type("pz").id(1).product(33).size("uniw").checkParams();
|
|
11
11
|
expect(params).toEqual({"type":"pz","id":1,"products":[{"product":33,"size":"uniw"}]});
|
|
12
12
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("deleteWmsSuppliersIds", () => {
|
|
5
|
-
const params = idosell().deleteWmsSuppliers.ids([2]).
|
|
5
|
+
const params = idosell().deleteWmsSuppliers.ids([2]).checkParams();
|
|
6
6
|
expect(params).toEqual({"ids":[2]});
|
|
7
7
|
})
|
package/tests/getClients.test.js
CHANGED
|
@@ -2,21 +2,21 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsClientsIds", () => {
|
|
5
|
-
const params = idosell().getClients.clientsIds([123,456,789]).
|
|
5
|
+
const params = idosell().getClients.clientsIds([123,456,789]).checkParams();
|
|
6
6
|
expect(params).toEqual({"clientsIds":[123,456,789]});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getClientsClientHasTradeCredit", () => {
|
|
10
|
-
const params = idosell().getClients.clientHasTradeCredit("nonzero").
|
|
10
|
+
const params = idosell().getClients.clientHasTradeCredit("nonzero").checkParams();
|
|
11
11
|
expect(params).toEqual({"clientHasTradeCredit":"nonzero"});
|
|
12
12
|
})
|
|
13
13
|
|
|
14
14
|
test("getClientsLastPurchased", () => {
|
|
15
|
-
const params = idosell().getClients.lastPurchased("2023-01-01", 1672704000000).
|
|
15
|
+
const params = idosell().getClients.lastPurchased("2023-01-01", 1672704000000).checkParams();
|
|
16
16
|
expect(params).toEqual({"clientLastPurchaseDate":{"clientLastPurchaseDateBegin":"2023-01-01","clientLastPurchaseDateEnd":"2023-01-03"}});
|
|
17
17
|
})
|
|
18
18
|
|
|
19
19
|
test("getClientsPage", () => {
|
|
20
|
-
const params = idosell().getClients.page(2,10).
|
|
20
|
+
const params = idosell().getClients.page(2,10).checkParams();
|
|
21
21
|
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
22
22
|
})
|
|
@@ -2,21 +2,21 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsBalanceActive", () => {
|
|
5
|
-
const params = idosell().getClientsBalance.active("yes").
|
|
5
|
+
const params = idosell().getClientsBalance.active("yes").checkParams();
|
|
6
6
|
expect(params).toEqual({ "active": "yes" });
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getClientsBalancePage", () => {
|
|
10
|
-
const params = idosell().getClientsBalance.page(2,10).
|
|
10
|
+
const params = idosell().getClientsBalance.page(2,10).checkParams();
|
|
11
11
|
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
12
12
|
})
|
|
13
13
|
|
|
14
14
|
test("getClientsBalanceClient_numbers", () => {
|
|
15
|
-
const params = idosell().getClientsBalance.client_numbers([123,456,678]).
|
|
15
|
+
const params = idosell().getClientsBalance.client_numbers([123,456,678]).checkParams();
|
|
16
16
|
expect(params).toEqual({"client_numbers":[123,456,678]});
|
|
17
17
|
})
|
|
18
18
|
|
|
19
19
|
test("getClientsBalanceLastPurchased", () => {
|
|
20
|
-
const params = idosell().getClientsBalance.lastPurchased("2023-01-01", 1672704000000).
|
|
20
|
+
const params = idosell().getClientsBalance.lastPurchased("2023-01-01", 1672704000000).checkParams();
|
|
21
21
|
expect(params).toEqual({"lastPurchaseDate":{"from":"2023-01-01","to":"2023-01-03"}});
|
|
22
22
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsDeliveryAddressClientLogins", () => {
|
|
5
|
-
const params = idosell().getClientsDeliveryAddress.clientLogins(["abc", "def", "ghi"]).
|
|
5
|
+
const params = idosell().getClientsDeliveryAddress.clientLogins(["abc", "def", "ghi"]).checkParams();
|
|
6
6
|
expect(params).toEqual({"clientLogins":["abc","def","ghi"]});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsGiftcardsTypesPage", () => {
|
|
5
|
-
const params = idosell().getClientsGiftcardsTypes.page(2,10).
|
|
5
|
+
const params = idosell().getClientsGiftcardsTypes.page(2,10).checkParams();
|
|
6
6
|
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsMembershipCardsId", () => {
|
|
5
|
-
const params = idosell().getClientsMembershipCards.id(123).
|
|
5
|
+
const params = idosell().getClientsMembershipCards.id(123).checkParams();
|
|
6
6
|
expect(params).toEqual({"id":123});
|
|
7
7
|
})
|
|
@@ -2,11 +2,11 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsPayerAddressClientId", () => {
|
|
5
|
-
const params = idosell().getClientsPayerAddress.clientId("iaisystem").
|
|
5
|
+
const params = idosell().getClientsPayerAddress.clientId("iaisystem").checkParams();
|
|
6
6
|
expect(params).toEqual({"clientId":"iaisystem"});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getClientsPayerAddressPage", () => {
|
|
10
|
-
const params = idosell().getClientsPayerAddress.page(2,10).
|
|
11
|
-
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
10
|
+
const params = idosell().getClientsPayerAddress.clientId("iaisystem").page(2,10).checkParams();
|
|
11
|
+
expect(params).toEqual({"resultsPage":2,"resultsLimit":10,"clientId":"iaisystem"});
|
|
12
12
|
})
|
|
@@ -2,11 +2,11 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsPricelistsPriceListIds", () => {
|
|
5
|
-
const params = idosell().getClientsPricelists.priceListIds([4]).
|
|
5
|
+
const params = idosell().getClientsPricelists.priceListIds([4]).checkParams();
|
|
6
6
|
expect(params).toEqual({"priceListIds":[4]});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getClientsPricelistsPage", () => {
|
|
10
|
-
const params = idosell().getClientsPricelists.page(2,10).
|
|
10
|
+
const params = idosell().getClientsPricelists.page(2,10).checkParams();
|
|
11
11
|
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
12
12
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsPricelistsClientsPriceListId", () => {
|
|
5
|
-
const params = idosell().getClientsPricelistsClients.priceListId(4).
|
|
5
|
+
const params = idosell().getClientsPricelistsClients.priceListId(4).checkParams();
|
|
6
6
|
expect(params).toEqual({"priceListId":4});
|
|
7
7
|
})
|
|
@@ -2,11 +2,11 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsPricelistsProductsPriceListId", () => {
|
|
5
|
-
const params = idosell().getClientsPricelistsProducts.priceListId(4).
|
|
5
|
+
const params = idosell().getClientsPricelistsProducts.priceListId(4).checkParams();
|
|
6
6
|
expect(params).toEqual({"priceListId":4});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getClientsPricelistsProductsPage", () => {
|
|
10
|
-
const params = idosell().getClientsPricelistsProducts.page(2,10).
|
|
11
|
-
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
10
|
+
const params = idosell().getClientsPricelistsProducts.priceListId(4).page(2,10).checkParams();
|
|
11
|
+
expect(params).toEqual({"resultsPage":2,"resultsLimit":10,"priceListId":4});
|
|
12
12
|
})
|
|
@@ -2,11 +2,11 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsPricesDiscountGroupsClientDiscountGroupsNumbers", () => {
|
|
5
|
-
const params = idosell().getClientsPricesDiscountGroups.clientDiscountGroupsNumbers([97]).
|
|
5
|
+
const params = idosell().getClientsPricesDiscountGroups.clientDiscountGroupsNumbers([97]).checkParams();
|
|
6
6
|
expect(params).toEqual({"clientDiscountGroupsNumbers":[97]});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getClientsPricesDiscountGroupsPage", () => {
|
|
10
|
-
const params = idosell().getClientsPricesDiscountGroups.page(2,10).
|
|
10
|
+
const params = idosell().getClientsPricesDiscountGroups.page(2,10).checkParams();
|
|
11
11
|
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
12
12
|
})
|
|
@@ -2,26 +2,26 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsPricesDiscountsClientIsActive", () => {
|
|
5
|
-
const params = idosell().getClientsPricesDiscounts.clientIsActive("yes").
|
|
5
|
+
const params = idosell().getClientsPricesDiscounts.clientIsActive("yes").checkParams();
|
|
6
6
|
expect(params).toEqual({"clientIsActive":"yes"});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getClientsPricesDiscountsLastPurchased", () => {
|
|
10
|
-
const params = idosell().getClientsPricesDiscounts.lastPurchased("2023-01-01", 1672704000000).
|
|
10
|
+
const params = idosell().getClientsPricesDiscounts.lastPurchased("2023-01-01", 1672704000000).checkParams();
|
|
11
11
|
expect(params).toEqual({"clientLastPurchaseDate":{"clientLastPurchaseDateBegin":"2023-01-01","clientLastPurchaseDateEnd":"2023-01-03"}});
|
|
12
12
|
})
|
|
13
13
|
|
|
14
14
|
test("getClientsPricesDiscountsPage", () => {
|
|
15
|
-
const params = idosell().getClientsPricesDiscounts.page(2,10).
|
|
15
|
+
const params = idosell().getClientsPricesDiscounts.page(2,10).checkParams();
|
|
16
16
|
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
17
17
|
})
|
|
18
18
|
|
|
19
19
|
test("getClientsPricesDiscountsClientHasTradeCredit", () => {
|
|
20
|
-
const params = idosell().getClientsPricesDiscounts.clientHasTradeCredit("positive").
|
|
20
|
+
const params = idosell().getClientsPricesDiscounts.clientHasTradeCredit("positive").checkParams();
|
|
21
21
|
expect(params).toEqual({"clientHasTradeCredit":"positive"});
|
|
22
22
|
})
|
|
23
23
|
|
|
24
24
|
test("getClientsPricesDiscountsClientsIds", () => {
|
|
25
|
-
const params = idosell().getClientsPricesDiscounts.clientsIds([1,3]).
|
|
25
|
+
const params = idosell().getClientsPricesDiscounts.clientsIds([1,3]).checkParams();
|
|
26
26
|
expect(params).toEqual({"clientsIds":[1,3]});
|
|
27
27
|
})
|
|
@@ -2,16 +2,16 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsProfitPointsClientsIds", () => {
|
|
5
|
-
const params = idosell().getClientsProfitPoints.clientsIds([1,3,4]).
|
|
5
|
+
const params = idosell().getClientsProfitPoints.clientsIds([1,3,4]).checkParams();
|
|
6
6
|
expect(params).toEqual({"clientsIds":[1,3,4]});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getClientsProfitPointsClientIsActive", () => {
|
|
10
|
-
const params = idosell().getClientsProfitPoints.clientIsActive("yes").
|
|
10
|
+
const params = idosell().getClientsProfitPoints.clientIsActive("yes").checkParams();
|
|
11
11
|
expect(params).toEqual({"clientIsActive":"yes"});
|
|
12
12
|
})
|
|
13
13
|
|
|
14
14
|
test("getClientsProfitPointsPage", () => {
|
|
15
|
-
const params = idosell().getClientsProfitPoints.page(2,10).
|
|
15
|
+
const params = idosell().getClientsProfitPoints.page(2,10).checkParams();
|
|
16
16
|
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
17
17
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsProvinceListCountry_code", () => {
|
|
5
|
-
const params = idosell().getClientsProvinceList.country_code("UA").
|
|
5
|
+
const params = idosell().getClientsProvinceList.country_code("UA").checkParams();
|
|
6
6
|
expect(params).toEqual({"country_code":"UA"});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getClientsTagsClientId", () => {
|
|
5
|
-
const params = idosell().getClientsTags.clientId(3).
|
|
5
|
+
const params = idosell().getClientsTags.clientId(3).checkParams();
|
|
6
6
|
expect(params).toEqual({"clientId":3});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getConfigVariables", () => {
|
|
5
|
-
const params = idosell().getConfigVariables.type("snippets_campaign").
|
|
5
|
+
const params = idosell().getConfigVariables.type("snippets_campaign").checkParams()
|
|
6
6
|
expect(params).toEqual({"type":'snippets_campaign'});
|
|
7
7
|
})
|
|
@@ -2,11 +2,12 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getCouriersCountryCode", () => {
|
|
5
|
-
const params = idosell().getCouriers.countryCode("PL").
|
|
5
|
+
const params = idosell().getCouriers.countryCode("PL").checkParams();
|
|
6
6
|
expect(params).toEqual({"countryCode":"PL"});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
|
+
|
|
9
10
|
test("getCouriersPage", () => {
|
|
10
|
-
const params = idosell().getCouriers.page(2,10).
|
|
11
|
-
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
11
|
+
const params = idosell().getCouriers.countryCode("PL").page(2,10).checkParams();
|
|
12
|
+
expect(params).toEqual({"countryCode":"PL","resultsPage":2,"resultsLimit":10});
|
|
12
13
|
})
|
|
@@ -2,16 +2,16 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getCouriersPickupPointsCourierId", () => {
|
|
5
|
-
const params = idosell().getCouriersPickupPoints.courierId(2270020).
|
|
5
|
+
const params = idosell().getCouriersPickupPoints.courierId(2270020).checkParams();
|
|
6
6
|
expect(params).toEqual({"courierId":2270020});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getCouriersPickupPointsPickupPointExternalId", () => {
|
|
10
|
-
const params = idosell().getCouriersPickupPoints.pickupPointExternalId("101293B").
|
|
11
|
-
expect(params).toEqual({"pickupPointExternalId":"101293B"});
|
|
10
|
+
const params = idosell().getCouriersPickupPoints.courierId(2270020).pickupPointExternalId("101293B").checkParams();
|
|
11
|
+
expect(params).toEqual({"pickupPointExternalId":"101293B","courierId":2270020});
|
|
12
12
|
})
|
|
13
13
|
|
|
14
14
|
test("getCouriersPickupPointsPage", () => {
|
|
15
|
-
const params = idosell().getCouriersPickupPoints.page(2,10).
|
|
16
|
-
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
15
|
+
const params = idosell().getCouriersPickupPoints.courierId(2270020).page(2,10).checkParams();
|
|
16
|
+
expect(params).toEqual({"resultsPage":2,"resultsLimit":10,"courierId":2270020});
|
|
17
17
|
})
|
package/tests/getCpa.test.js
CHANGED
|
@@ -2,11 +2,11 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getCpaId", () => {
|
|
5
|
-
const params = idosell().getCpa.id(2).
|
|
5
|
+
const params = idosell().getCpa.id(2).checkParams();
|
|
6
6
|
expect(params).toEqual({"id":2});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getCpaPage", () => {
|
|
10
|
-
const params = idosell().getCpa.page(1,2).
|
|
10
|
+
const params = idosell().getCpa.page(1,2).checkParams();
|
|
11
11
|
expect(params).toEqual({"resultsPage":1,"resultsLimit":2});
|
|
12
12
|
})
|
|
@@ -2,11 +2,11 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getCpaCampaignId", () => {
|
|
5
|
-
const params = idosell().getCpaCampaign.campaign(2).
|
|
5
|
+
const params = idosell().getCpaCampaign.campaign(2).checkParams();
|
|
6
6
|
expect(params).toEqual({"campaign":2});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getCpaCampaignPage", () => {
|
|
10
|
-
const params = idosell().getCpaCampaign.page(1,2).
|
|
10
|
+
const params = idosell().getCpaCampaign.page(1,2).checkParams();
|
|
11
11
|
expect(params).toEqual({"resultsPage":1,"resultsLimit":2});
|
|
12
12
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getDeliveriesProfilesPage", () => {
|
|
5
|
-
const params = idosell().getDeliveriesProfiles.page(0,3).
|
|
5
|
+
const params = idosell().getDeliveriesProfiles.page(0,3).checkParams();
|
|
6
6
|
expect(params).toEqual({"resultsPage":0,"resultsLimit":3});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getDeliveriesRegionsShopId", () => {
|
|
5
|
-
const params = idosell().getDeliveriesRegions.shopId(1).
|
|
5
|
+
const params = idosell().getDeliveriesRegions.shopId(1).checkParams();
|
|
6
6
|
expect(params).toEqual({"shopId":1});
|
|
7
7
|
})
|
|
@@ -2,11 +2,11 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getDiscountsGroupsGroup_numbers", () => {
|
|
5
|
-
const params = idosell().getDiscountsGroups.group_numbers([97]).
|
|
5
|
+
const params = idosell().getDiscountsGroups.group_numbers([97]).checkParams();
|
|
6
6
|
expect(params).toEqual({"group_numbers":[97]});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getDiscountsGroupsPage", () => {
|
|
10
|
-
const params = idosell().getDiscountsGroups.page(2,10).
|
|
10
|
+
const params = idosell().getDiscountsGroups.page(2,10).checkParams();
|
|
11
11
|
expect(params).toEqual({"resultsPage":2,"resultsLimit":10});
|
|
12
12
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getDiscountsGroupsClientsDiscountGroupId", () => {
|
|
5
|
-
const params = idosell().getDiscountsGroupsClients.discountGroupId(3).
|
|
5
|
+
const params = idosell().getDiscountsGroupsClients.discountGroupId(3).checkParams();
|
|
6
6
|
expect(params).toEqual({"discountGroupId":3});
|
|
7
7
|
})
|
package/tests/getEntries.test.js
CHANGED
|
@@ -2,11 +2,11 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getEntriesLangId", () => {
|
|
5
|
-
const params = idosell().getEntries.langId("pol").
|
|
5
|
+
const params = idosell().getEntries.langId("pol").checkParams();
|
|
6
6
|
expect(params).toEqual({"langId":"pol"});
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
test("getEntriesEntryId", () => {
|
|
10
|
-
const params = idosell().getEntries.entryId(1308134131).
|
|
10
|
+
const params = idosell().getEntries.entryId(1308134131).checkParams();
|
|
11
11
|
expect(params).toEqual({"entryId":1308134131});
|
|
12
12
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getEntriesPagesToDisplayLangId", () => {
|
|
5
|
-
const params = idosell().getEntriesPagesToDisplay.langId("pol").
|
|
5
|
+
const params = idosell().getEntriesPagesToDisplay.langId("pol").checkParams();
|
|
6
6
|
expect(params).toEqual({"langId":"pol"});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getEntriesSourcesType", () => {
|
|
5
|
-
const params = idosell().getEntriesSources.type("search").
|
|
5
|
+
const params = idosell().getEntriesSources.type("search").checkParams();
|
|
6
6
|
expect(params).toEqual({"type":"search"});
|
|
7
7
|
})
|
package/tests/getMenu.test.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import idosell from "./dist/index"
|
|
1
|
+
import idosell from "./dist/index.ts"
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
|
-
test("
|
|
5
|
-
const params = idosell().getMenu.lang_id("pol").
|
|
6
|
-
expect(params).toEqual({"lang_id":"pol"});
|
|
4
|
+
test("getMenu", () => {
|
|
5
|
+
const params = idosell().getMenu.shop_id(1).menu_id(1).lang_id("pol").checkParams();
|
|
6
|
+
expect(params).toEqual({"shop_id":1,"menu_id":1,"lang_id":"pol"});
|
|
7
7
|
})
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import idosell from "./dist/index"
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
|
-
test("
|
|
5
|
-
const params = idosell().getMenuFilter.languageId("pol").
|
|
6
|
-
expect(params).toEqual({"languageId":"pol"});
|
|
4
|
+
test("getMenuFilterProductMenu", () => {
|
|
5
|
+
const params = idosell().getMenuFilter.shopId(1).languageId("pol").productMenuTreeId(1).productMenuNodeId(161).checkParams();
|
|
6
|
+
expect(params).toEqual({"shopId":1,"languageId":"pol","productMenuTreeId":1,"productMenuNodeId":161});
|
|
7
7
|
})
|
package/tests/getOrders.test.js
CHANGED
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getOrdersOrdersSerialNumbers", () => {
|
|
5
|
-
const params = idosell().getOrders.ordersSerialNumbers([123,456,789]).
|
|
5
|
+
const params = idosell().getOrders.ordersSerialNumbers([123,456,789]).checkParams();
|
|
6
6
|
expect(params).toEqual({"ordersSerialNumbers":[123,456,789]});
|
|
7
7
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getOrdersAnalyticsSerialNumbers", () => {
|
|
5
|
-
const params = idosell().getOrdersAnalytics.orderSerialNumber([123,456,789]).
|
|
5
|
+
const params = idosell().getOrdersAnalytics.orderSerialNumber([123,456,789]).checkParams();
|
|
6
6
|
expect(params).toEqual({"orderSerialNumber":[123,456,789]});
|
|
7
7
|
})
|
|
@@ -1,7 +1,17 @@
|
|
|
1
|
-
import idosell from "./dist/index"
|
|
1
|
+
import idosell from "./dist/index.ts"
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getOrdersAuctionDetailsSerialNumbers", () => {
|
|
5
|
-
const params = idosell().getOrdersAuctionDetails.serialNumbers([
|
|
6
|
-
expect(params).toEqual({"
|
|
5
|
+
const params = idosell().getOrdersAuctionDetails.serialNumbers([1706995,1706991]).checkParams();
|
|
6
|
+
expect(params).toEqual({"identType":"order_sn","orders":[1706995,1706991]});
|
|
7
|
+
})
|
|
8
|
+
|
|
9
|
+
test("getOrdersAuctionDetailsOrders", () => {
|
|
10
|
+
const params = idosell().getOrdersAuctionDetails.identType("orders_sn").orders([1706995]).checkParams();
|
|
11
|
+
expect(params).toEqual({"identType":"orders_sn","orders":[1706995]});
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
test("getOrdersAuctionDetailsIds", () => {
|
|
15
|
+
const params = idosell().getOrdersAuctionDetails.ids("client-1").checkParams();
|
|
16
|
+
expect(params).toEqual({"identType":"order_id","orders":["client-1"]});
|
|
7
17
|
})
|
|
@@ -2,6 +2,6 @@ import idosell from "./dist/index"
|
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
4
|
test("getOrdersDocumentsDocumentType", () => {
|
|
5
|
-
const params = idosell().getOrdersDocuments.orderSerialNumber(["9"]).documentType("sales_confirmation").
|
|
5
|
+
const params = idosell().getOrdersDocuments.orderSerialNumber(["9"]).documentType("sales_confirmation").checkParams();
|
|
6
6
|
expect(params).toEqual({"orderSerialNumber":["9"],"documentType":"sales_confirmation"});
|
|
7
7
|
})
|
|
@@ -1,22 +1,12 @@
|
|
|
1
|
-
import idosell from "./dist/index"
|
|
1
|
+
import idosell from "./dist/index.ts"
|
|
2
2
|
import { expect, test } from "vitest"
|
|
3
3
|
|
|
4
|
-
test("
|
|
5
|
-
const params = idosell().getOrdersExportdocumentsEPP.
|
|
6
|
-
expect(params).toEqual({"
|
|
7
|
-
})
|
|
8
|
-
|
|
9
|
-
test("getOrdersExportdocumentsEPPApplicationType", () => {
|
|
10
|
-
const params = idosell().getOrdersExportdocumentsEPP.applicationType("SubiektGT").getParams();
|
|
11
|
-
expect(params).toEqual({"applicationType":"SubiektGT"});
|
|
12
|
-
})
|
|
13
|
-
|
|
14
|
-
test("getOrdersExportdocumentsEPPDocumentType", () => {
|
|
15
|
-
const params = idosell().getOrdersExportdocumentsEPP.documentType("all").getParams();
|
|
16
|
-
expect(params).toEqual({"documentType":"all"});
|
|
4
|
+
test("getOrdersExportdocuments", () => {
|
|
5
|
+
const params = idosell().getOrdersExportdocumentsEPP.dateBegin("2025-01-01").dateEnd("2025-01-31").applicationType("SubiektGT").documentType("all").checkParams();
|
|
6
|
+
expect(params).toEqual({"dateBegin":"2025-01-01","dateEnd":"2025-01-31","applicationType":"SubiektGT","documentType":"all"});
|
|
17
7
|
})
|
|
18
8
|
|
|
19
9
|
test("getOrdersExportdocumentsEPPDates", () => {
|
|
20
|
-
const params = idosell().getOrdersExportdocumentsEPP.dates("2023-01-01", 1672704000000).
|
|
21
|
-
expect(params).toEqual({"dateBegin":"2023-01-01","dateEnd":"2023-01-03"});
|
|
10
|
+
const params = idosell().getOrdersExportdocumentsEPP.applicationType("SubiektGT").documentType("all").dates("2023-01-01", 1672704000000).checkParams();
|
|
11
|
+
expect(params).toEqual({"applicationType":"SubiektGT","documentType":"all","dateBegin":"2023-01-01","dateEnd":"2023-01-03"});
|
|
22
12
|
})
|