**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>
**what:**
- hides different fields depending on the chosen template
- remove operator values API
- fixes to edit promotion rules
- make currency optional for promotion
RESOLVES CORE-2297
**What**
Remove transaction decorator from the base medusa service method, the transaction will always be coming from the shared context. It fixes the issue that when you consume a base method directly it will return a proper tuple from the DB instead of the one from the entity map cc @VariableVic
**NOTE**
This pr also fix some categories issues in the product module which was preventing the tests from working. if @sradevski you could have a look later, in the mean time we can still merge it
FIXES CORE-2342
* feat: Normalize the categories interface to match standards
* feat: Revamp the product category implementation
* fix: Adjustments to code and tests around product categories
* chore: ability to group events on redis event bus
* chore: fix tests
* Update packages/modules/event-bus-redis/src/services/event-bus-redis.ts
Co-authored-by: Adrien de Peretti <adrien.deperetti@gmail.com>
* chore: change shape of input and body data
* chore: fix builds
* chore: address comments
* chore: fix unit test
---------
Co-authored-by: Adrien de Peretti <adrien.deperetti@gmail.com>
**What**
emit product tags events
**note**
Stil does not take into consideration non overriden method, delete and soft delete emits event under the hood and we will have to migrate that at the end
what:
- santizes inputs to prevent reserved_quantity from being updated directly
- inventory items create api can create location levels
- add validation to update quantity of reservation items
- general cleanup
RESOLVES CORE-2254
WIP, not ready to review
**what**
- add events
- integration tests of emitted events
- remove integration tests on auto generated services in favor of module method integration tests
**What**
- Return the updated/deleted/created entities from the upsert with replace according to the configuration
This will help to emit the events from the product module as it rely on this abstraction in many places
* chore: Move publishable api key tests to HTTP
* chore: Move store tests to HTTP folder
* fix: Add tests for store products, fix several bugs around publishable keys
what:
- adds variant inventory link management endpoints:
```
Link inventory item to variant
POST /products/:id/variants/:vid/inventory-items
Update variant's inventory item link
POST /products/:id/variants/:vid/inventory-items/:iid
Unlink variant's inventory item
DELETE /products/:id/variants/:vid/inventory-items/:iid
```
- a batch endpoint that does the above 3 across variants
```
POST /products/:id/variants/inventory-items
```
**What**
Add support for event emitting in the fulfillment module
**NOTE**
It does not include the review of the events for the abstract module factory if the method is not implemented in the module itself and rely on the default implementation