Chore/rm main entity concept (#7709)

**What**
Update the `MedusaService` class, factory and types to remove the concept of main modules. The idea being that all method will be explicitly named and suffixes to represent the object you are trying to manipulate.
This pr also includes various fixes in different modules

Co-authored-by: Stevche Radevski <4820812+sradevski@users.noreply.github.com>
Co-authored-by: Oli Juhl <59018053+olivermrbl@users.noreply.github.com>
This commit is contained in:
authored and GitHub committed 2024-06-19 13:02:16 +00:00
1 parent 2895ccfba8
commit 48963f55ef
533 files changed
+6469 -9769

No files matched your search

@@ -31,7 +31,7 @@ medusaIntegrationTestRunner({
const region = await service.createTaxRegions({
country_code: "us",
})
const rate = await service.create({
const rate = await service.createTaxRates({
tax_region_id: region.id,
code: "test",
rate: 2.5,
@@ -69,14 +69,14 @@ medusaIntegrationTestRunner({
country_code: "us",
})
await service.create({
await service.createTaxRates({
tax_region_id: region.id,
code: "low",
rate: 2.5,
name: "low rate",
})
await service.create({
await service.createTaxRates({
tax_region_id: region.id,
code: "high",
rate: 5,
@@ -384,7 +384,7 @@ medusaIntegrationTestRunner({
deleted: true,
})
const rates = await service.list(
const rates = await service.listTaxRates(
{ id: rateRes.data.tax_rate.id },
{ withDeleted: true }
)
@@ -397,7 +397,7 @@ medusaIntegrationTestRunner({
country_code: "us",
})
const rate = await service.create({
const rate = await service.createTaxRates({
tax_region_id: region.id,
code: "test",
rate: 2.5,