Commit Graph

160 Commits

Author SHA1 Message Date
Riqwan Thamir f129415650 feat(medusa,core-flows): complete cart [part-1] (#7201)
what:

- adds a very basic complete cart endpoint that creates an order
- the complete cart workflow currently does the following:
  - create tax lines
  - create order
2024-05-02 22:24:50 +00:00
Carlos R. L. Rodrigues 9d3f495314 feat(fulfillment): shipping options context field (#7169) 2024-05-02 09:59:14 -03:00
github-actions[bot] 2c807df99d chore: Version Packages (#6839)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-01 09:48:24 +02:00
Adrien de Peretti e26cda4b6a feat(medusa, core-flows, types): Allow to update the rules from a shipping options (#7175)
**What**
Add support for the following operations
- update rules from the update shipping options end point
- update rules from the batch update end point

Also added some improvements, that can be revisited later
- Add a rule value normalizer, jsonb will transform the input value to a [primitive](https://www.postgresql.org/docs/current/datatype-json.html#JSON-TYPE-MAPPING-TABLE) when possible meaning that passing `"true"` will result in storing `true` and not the string. The normalizer takes care of that
2024-04-30 16:45:17 +00:00
Stevche Radevski 32c2a9d76b feat: Add missing endpoints and normalize customer and currency endpoints for storefront (#7160) 2024-04-29 16:15:05 +02:00
Riqwan Thamir d2393f004e feat(core-flows, medusa): add shipping methods to cart API (#7150)
* feat(core-flows, medusa): add shipping methods to cart API

* chore: change id to option_id

* chore: use list listShippingOptionsForContext instead of validateShippingOption

* chore: remove comment

* chore: add refresh shipping methods step

* chore: set cart step

* chore: update all workflows to refresh shipping methods

* chore: add tests + cleanup
2024-04-29 09:25:23 +02:00
Carlos R. L. Rodrigues 4b57c5d286 feat(modules-sdk): remote query context filter (#7153)
What:

- Remote query now handles `context` keywork in the arguments to forward it as a filter to the method `list`
- Pricing module `list` method returning `calculated_price` if requested as a field
2024-04-26 10:20:42 +00:00
Stevche Radevski 614d659a59 feat: Add local file provider and wire everything up in the file module (#7134) 2024-04-24 10:59:58 +02:00
Frane Polić fe68b5c0f2 refactor(dashboard): refresh domains (#7087) 2024-04-24 10:38:52 +02:00
Oli Juhl 10e120062b feat: V2 batch update products in categories (#7125)
* wip

* wip

* fix: batch category update

* update tet

* fix type

---------

Co-authored-by: Stevche Radevski <sradevski@live.com>
2024-04-23 17:17:25 +02:00
Stevche Radevski 9e3556686b fix: Standardize remaining batch methods and update FE calls (#7122) 2024-04-23 09:12:38 +00:00
Riqwan Thamir 18f3aacee6 feat(core-flows,medusa,types): fulfillment API: create (#7101)
what:

- adds fulfillment create API

RESOLVES CORE-1962
2024-04-23 08:35:44 +00:00
Stevche Radevski 0df523594f feat: Convert several batch methods to the standardized format (#7116) 2024-04-22 16:35:10 +02:00
Oli Juhl 67a21c3e45 feat: Update product category (#7092)
* feat: Update product category

* Disable V2 FF in product category tes

* clean up
2024-04-22 12:30:27 +02:00
Stevche Radevski 89143e1032 feat: Add batch method to collection and clean up some batch implementations (#7102) 2024-04-22 08:36:22 +00:00
Riqwan Thamir 62b9dcc6c1 feat(core-flows,medusa,types): cancel fulfillments API (#7095)
what:

- adds POST cancel fulfillments endpoint

RESOLVES CORE-1972
2024-04-18 11:00:01 +00:00
Riqwan Thamir 8d356217bd feat(medusa,core-flows,types): adds batch operations to price list prices (#7077)
what:

- adds batch operations to price list prices

RESOLVES CORE-1969
RESOLVES CORE-1970
2024-04-17 15:36:09 +00:00
Frane Polić 0a9b9b073d feat(dashboard): shipping management (#6995)
**What**
- shipping flow
- shipping profile pages
- delete fulfillment set endpoint
- delete shipping profile endpoint
2024-04-16 13:42:56 +00:00
Oli Juhl bc081a7777 feat: Create product category flow (#7034)
* feat: Create product category

* address PR comments
2024-04-15 17:11:42 +02:00
Stevche Radevski fd83e75e4b feat: Add support for batch method for products and product variants (#7038)
* feat(products): Add batch methods for product and variants

* chore: Rename batch validator and minor changes based on PR review
2024-04-15 16:48:29 +02:00
Adrien de Peretti c78915c7c5 feat: Add support for shipping options prices update (#7028) 2024-04-11 18:34:55 +02:00
Philip Korsholm ab7ff64c4a Feat(admin-next, core-flows, link-modules, medusa, types): Inventory end to end flows (#7020)
* add reservation endpoints

* add changeset

* initial

* add reservations table

* add edit-item modal

* udpate inventory item attributes

* manage locations skeleton

* add combi batch endpoint

* cleanup

* fix manage locations

* add adjust inventory

* prep for pr

* update versions

* fix for pr

* fix for pr

* cleanup

* Update packages/core-flows/src/inventory/workflows/bulk-create-delete-levels.ts

Co-authored-by: Carlos R. L. Rodrigues <37986729+carlos-r-l-rodrigues@users.noreply.github.com>

* Update packages/core-flows/src/inventory/steps/delete-levels-by-item-and-location.ts

Co-authored-by: Carlos R. L. Rodrigues <37986729+carlos-r-l-rodrigues@users.noreply.github.com>

* rm wack import

* fix build

---------

Co-authored-by: Carlos R. L. Rodrigues <37986729+carlos-r-l-rodrigues@users.noreply.github.com>
2024-04-10 15:17:54 +02:00
Philip Korsholm f175cac4af Feat(medusa, core-flows, types): add reservation endpoints (#7018)
* add reservation endpoints

* add changeset
2024-04-09 18:40:00 +02:00
Adrien de Peretti e1a0960e20 feat: delete shipping options (#6993) 2024-04-09 15:30:22 +02:00
Oli Juhl dbddfc12ed feat: Admin Shipping Profiles API (#7019) 2024-04-09 11:03:37 +02:00
Oli Juhl c03216efbf fix: Delete service zone (#7017) 2024-04-08 20:24:59 +02:00
Riqwan Thamir 5e953f8cf3 chore: add batch update prices for price lists (#6999) 2024-04-08 09:23:23 +02:00
Oli Juhl 4f88743591 feat: Admin V2 Customers (#6998) 2024-04-07 21:38:50 +02:00
Adrien de Peretti f132929c7e feat(*): shipping options update API (#6987)
**What**
- Update the `updateShippingOptions` module service API to follow the newest convention
- Add upsert support for shipping options
- update shipping options workflow
- update shipping options api end point and validation
- update shipping options all integration tests

FIXES CORE-1926
2024-04-07 16:28:59 +00:00
Oli Juhl a24d6e6c97 feat: Update service zone (#6990) 2024-04-07 17:30:55 +02:00
Carlos R. L. Rodrigues b6879f017a feat: Totals calculation (#6980) 2024-04-07 16:50:40 +02:00
Stevche Radevski 44bcde92c8 feat: Add support for setting sales channel when creating a product (#6986) 2024-04-07 13:45:47 +02:00
Oli Juhl d1728990e9 feat: Delete service zone (#6984) 2024-04-07 10:59:08 +02:00
Oli Juhl 81ea044f31 feat(medusa, core-flows): Create service zones (#6979) 2024-04-06 21:31:23 +02:00
Carlos R. L. Rodrigues df0751f122 Feat: draft order api (#6797) 2024-04-06 16:35:10 +02:00
Stevche Radevski 883a75c4f3 feat: Switch to zod for the product API and implement missing primitives (#6978) 2024-04-06 13:45:52 +00:00
Adrien de Peretti 65794f4bb5 feat: Create shipping options workflow (#6962)
**What**

- Create main workflow
- Update create pricing rule types step to be idempotent
- update remote joiner to support granular isList confguration on field aliases
- Add full workflow integration tests
2024-04-06 11:51:48 +00:00
Stevche Radevski 07fb058d96 feat: Add product routes and components to v2 in admin-next (#6958) 2024-04-06 11:59:52 +02:00
Oli Juhl 626aa09497 feat: Add create location fulfillment set flow + API (#6945) 2024-04-05 19:27:38 +02:00
Adrien de Peretti ee73031d0e feat: Shipping options API (#6957)
**What**
Add support for shipping options management API

PARTIALLY FIXES CORE-1918
2024-04-05 14:23:45 +00:00
Stevche Radevski 9ccd88d025 feat: Add boilerplate for the file module (#6956) 2024-04-05 14:46:02 +02:00
Adrien de Peretti e944a627f0 feat: region payment providers management workflows/api (#6864) 2024-04-04 20:41:34 +02:00
Philip Korsholm edafe7db47 Feat(link-module, core-flows, medusa): Add sales channel location management (#6905)
* add locations with sales channels

* init, not working location based management

* working adding sales channel stock locations

* remote sales channels from location

* remove console log

* rm allowedFields

* redo errorhandler

* make validation take an array

* add changeset

* fix build

* Update packages/core-flows/src/sales-channel/workflows/remove-locations-from-sales-channel.ts

Co-authored-by: Oli Juhl <59018053+olivermrbl@users.noreply.github.com>

* add default cases to return early

* cleanup

* add sc test and remove associations

---------

Co-authored-by: Oli Juhl <59018053+olivermrbl@users.noreply.github.com>
2024-04-03 08:38:53 +02:00
Oli Juhl 7895ff3849 feat: add sales channel management (#6761)
Add V2 sales channel management to admin

`@medusajs/medusa`
- Add `POST /admin/sales-channels/:id/products/batch/remove`
- Refactor cross-module filter middleware to comply with the latest convention

`@medusajs/admin-next`
- Add all sales channel routes
- Moves the following sales channel UI to shared components in `modules/sales-channel`:
  - sales-channel-list
  - sales-channel-edit
  - sales-channel-details
    - sales-channel-general-section
  - sales-channel-create

The sales-channel-product-section is not shared because the API in V2 will change.
The sales-channel-add-products component is not shared because the API in V2 will change.

`@medusajs/core-flows`
- Add `detachProductsFromSalesChannelsStep`
- Add `removeProductsFromSalesChannelsWorkflow`
2024-04-02 13:38:33 +00:00
Stevche Radevski b3ce13d61e fix: Fixes to product module and improving tests (#6898) 2024-04-02 07:13:46 +00:00
Stevche Radevski 585818eaf8 feat: Pricing update and refactor product API tests to not rely on internals (#6892)
This PR achieves the following
- Remove dependency on internals for seeding the tests (more work left, but major work done)
- Adds the workflow for updating variant's price

I will do a follow-up PR to further clean up the tests and remove all internal dependencies
2024-04-01 09:33:52 +00:00
Stevche Radevski 1a48fe0282 feat: Add v2 product types endpoints (#6880)
Also adjusts the product type module APIs to follow the conventions
2024-03-29 19:27:10 +00:00
Oli Juhl 1bcb13f892 feat: Remove sales channels from pub keys (#6876)
**What**
- Add workflow + step for detaching sales channels from pub API keys
- Tweak linking error message to be more helpful
- Add `removeRemoteLink` step to delete API key workflow
2024-03-29 15:01:10 +00:00
Stevche Radevski 86f499de2f feat: Implemented price set update with prices and aligned pricing API (#6872) 2024-03-29 10:23:24 +00:00
Stevche Radevski cbb5e6bd99 feat: Refactor the product module definitions and implementation (#6866)
There are several things done in this PR, namely:

Unify the service endpoints API to always work with a model rather than allowing to pass both ID and model (eg. both type_id and type being available in the request to create).
Start using upsertWithReplace to simplify the code and fix some deassociation bugs
Apply some changes to tests to deal with the pricing breaking changes
Correctly define the model relationships (with both ID and entity fields available)
All tests for the product are passing, which should bring us back to a great baseline.
2024-03-29 09:03:41 +00:00