Commit Graph

4264 Commits

Author SHA1 Message Date
Philip Korsholm
3bcf08c0cb fix(admin-ui): inventory item deletion when removing product (#5727) 2023-11-27 13:42:55 +00:00
Riqwan Thamir
2e6b110316 fix(medusa,pricing): Fix migrations for existing databases (#5730) 2023-11-27 13:36:56 +00:00
Kasper Fabricius Kristensen
5f6751a61f fix(admin-ui): Fix Y-axis scroll in bulk editor (#5726) 2023-11-27 11:13:11 +00:00
Philip Korsholm
18afe0b9ad Fix(medusa, inventory, stock-location, types, utils): Modules sdk build query (#5713)
* remove defaults

* take 2

* works now

* add changeset

* pricing module and pricing service list take null updates

* update handlers

* update product module service with take:null where relevant

* no spread

* note to self:default offset should be 0, not 15
2023-11-27 10:17:42 +00:00
github-actions[bot]
faa528159d chore(docs): Removed Docs Announcement Bar (automated) (#5721)
Automated changes by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

Co-authored-by: Shahed Nasser <27354907+shahednasser@users.noreply.github.com>
2023-11-27 09:34:34 +00:00
olivermrbl
a982e60a0e chore: Bump lock-file 2023-11-27 08:28:09 +00:00
olivermrbl
285fa92876 chore(workflows-sdk): Change version for release 2023-11-27 08:10:57 +00:00
Philip Korsholm
aa6c4cbac5 fix(medusa): pricing module list prices return type (#5715) 2023-11-26 16:30:21 +00:00
Philip Korsholm
0df1c7d427 fix(pricing, types): update calculatePrices return type to match actual type (#5709)
* initial type fix

* add changeset

* update changeset

* update tsdocs

---------

Co-authored-by: Oli Juhl <59018053+olivermrbl@users.noreply.github.com>
Co-authored-by: Riqwan Thamir <rmthamir@gmail.com>
2023-11-24 17:12:34 +00:00
Carlos R. L. Rodrigues
ffb0c7b4cd feat(workflows-sdk): get name method (#5714) 2023-11-24 16:39:27 +00:00
olivermrbl
74117ad48b chore(changesets): Change workflows -> workflows-sdk 2023-11-24 14:03:51 +00:00
Adrien de Peretti
ddbeed4ea6 chore(workflows, core-flows): Split workflows tooling and definitions (#5705) 2023-11-24 13:55:48 +00:00
Riqwan Thamir
fc1ef29ed9 fix(medusa,pricing,types): rules only gets updated/deleted upon passing an explicit object (#5711) 2023-11-24 13:54:23 +00:00
Kasper Fabricius Kristensen
07934cdaac fix(admin-ui): Edit prices requires at least one product (#5710) 2023-11-24 13:54:07 +00:00
Kasper Fabricius Kristensen
f4c489fb85 fix(admin-ui): Fix issue with null product categories (#5707)
* fix(admin-ui): If categories is null on a product the details page should not crash

* cleanup variant warning to reflect pricing changes
2023-11-24 12:51:32 +00:00
Philip Korsholm
712c4496ce fix(medusa): Update default relations in admin for list-product from module 2023-11-24 12:50:42 +00:00
olivermrbl
f2fd51f969 chore(changesets): include @medusajs/admin 2023-11-24 09:22:09 +00:00
Shahed Nasser
a2f42d1d1c docs: update Next.js starter main image (#5702) 2023-11-23 18:28:36 +00:00
Kasper Fabricius Kristensen
22bea2724d fix(medusa): Normalize subscriber paths (#5703) 2023-11-23 17:33:51 +00:00
Shahed Nasser
f3e20379b0 chore: added TSDoc for workflow utility functions (#5674)
* feat(translation): Init plugin

* Create migration and entity

* Start service implementation

* fix typo

* typings

* config

* lang -> locale

* chnge config

* link

* update link

* update export

* workflow composer (wip)

* workflow step/workflow

* simplify api

* Add structured tests

* Add step name onto the step function for future usage

* new abstraction level of exported workflow

* cleanup

* rm step 4

* Add parallelize support to workflow composition

* add Symbols and support primitive types as input

* rem .only

* eslint

* cleanup + test

* resultFrom

* prevent undefined from crashing

* finalise tests

* chore: transform

* chore: tests and transform type

* move translation to my dummy

* chore: copy before transform

* yarn.lock

* chore: shortcut to property access

* Add type safety

* WIP typesafety

* WIP

* finalise typings

* remove extends unknown

* WIP

* finalise transform typings

* finalise transform typings

* workflow typs

* More typings in invoke and compensate

* rm comment

* Context as the last args

* fix step function type

* types

* fixes

* fixes compose

* chore: transform

* chore: fix tests and transform Proxy

* chore: args length

* uncomment

* chore: array fill

* WIP fix filler

* WIP fix filler

* chore: remove only

* apply gap filler to create step invoke

* context first

* fixes

* wofkrlow ts documentation

* wofkrlow ts documentation

* wofkrlow ts documentation

* wofkrlow ts documentation

* wofkrlow ts documentation

* chore: hook

* hook types

* update types

* don't loose previous iteration

* update implementation

* fix some tests part 1

* finalise typings

* rm new lines

* fixes

* wip

* fixes

* fix tests

* simplify types

* simplify types

* update export

* improve types exclusion compensateInput

* allow a workflow to return plain object composed of stepReturn properties

* only allow one handler for the hook registration

* only allow one handler for the hook registration

* workflow loading

* lint

* lint

* lint

* finalise tests

* try to fix ci

* try to fix ci

* remove corepack step

* cleanup

* cleanup

* cleanup

* chore: context as 2nd argumentq

* added tsdoc for some workflow functions

* Add support for StepResponse and re work the typings

* changeset

* chore: invoke output as default compensate input

* copy data

* copy data

* fix createWorkflow result

* added tsdoc to remaining utility functions

* rm test file

* proxify input and transformer as well

* transformer should re run + type update

* rework step response

* allow void return from steps

* updates to the TSDocs

* address comments

* address PR feedback

* add await for API Route examples

* ignore documenting hooks

---------

Co-authored-by: adrien2p <adrien.deperetti@gmail.com>
Co-authored-by: Carlos R. L. Rodrigues <rodrigolr@gmail.com>
Co-authored-by: Carlos R. L. Rodrigues <37986729+carlos-r-l-rodrigues@users.noreply.github.com>
2023-11-23 16:38:43 +00:00
Riqwan Thamir
1e39a95f8a fix(pricing, medusa): resolve minor pricing-module bugs (#5685)
* fix region price updates

* pricing migration: include title/name field value migration

* update migration scripts for pricing module

* move file to script utils

* rename file

* rename file

* add changeset

* remove redundant maps

* update migration script

* nit

* remove unnecessary variable

* filter before map

* array function naming cleanup

* chore: address pr reviews

---------

Co-authored-by: Philip Korsholm <philip.korsholm@hotmail.com>
Co-authored-by: Philip Korsholm <88927411+pKorsholm@users.noreply.github.com>
2023-11-23 17:11:47 +01:00
Philip Korsholm
02ea9ac3ac feat(admin-ui): Delete pricing forms from edit + create variant modals (#5676) 2023-11-23 15:31:32 +00:00
Philip Korsholm
a39ce125cc fix(product, types, workflows): Update product variant workflow (#5668)
**What**
- Fix issues with update-variant workflow: 
  - other variants than the updated variant are no longer removed 
  - options are updated properly


Co-authored-by: Riqwan Thamir <5105988+riqwan@users.noreply.github.com>
2023-11-23 14:35:01 +00:00
Kasper Fabricius Kristensen
b25b29fe7b fix(ui): code block styles (#5692)
**What**
- Improves the styling of CodeBlock prism theme
2023-11-23 11:59:17 +00:00
Shahed Nasser
180b595afb docs: added a new document for available languages (#5667)
- Add a new documentation page for available languages.
- Refer to the new page from other pages.
2023-11-23 10:54:17 +00:00
Omar Hawwash
4fbe02b299 docs: updated medusa develop command (#5698) 2023-11-23 09:52:45 +00:00
Adrien de Peretti
010560fd2a fix(workflows): compensation handling (#5691) 2023-11-23 09:11:03 +00:00
Riqwan Thamir
6025c702f3 fix(pricing,types): remove is_dynamic from model + types (#5664)
what:

Removing this until we introduce dynamic pricing. 

Co-authored-by: Shahed Nasser <27354907+shahednasser@users.noreply.github.com>
2023-11-22 19:28:48 +00:00
Carlos R. L. Rodrigues
9f9db39698 feat(workflows): Workflow DX (#5607) 2023-11-22 17:23:39 +00:00
Shahed Nasser
2850e9a772 docs: redesigned admonitions (#5689) 2023-11-22 17:07:29 +00:00
Shahed Nasser
00d59e28e9 docs: redesign tabs (#5687)
* redesigned tabs

* design fixes
2023-11-22 16:01:51 +00:00
Philip Korsholm
dc5750dd66 feat(medusa,types,workflows,utils,product): PricingModule Integration of PriceLists into Core (#5536) 2023-11-21 17:42:37 +00:00
Shahed Nasser
9c7ac7332a docs: added migration action to upgrade guide (#5669) 2023-11-21 14:46:22 +00:00
github-actions[bot]
2b9e8bda5e chore(docs): Generated References (#5666)
Generated the following references:
- `entities`
- `js-client`
- `pricing`
- `services`

Co-authored-by: Shahed Nasser <27354907+shahednasser@users.noreply.github.com>
2023-11-21 12:36:09 +00:00
Nicklas Gellner
4774b8ff3a Add missing link to admin-guide on translations (#5665)
Added missing link. @shahednasser can see you often use markdown references for other links, let me know if you prefer my submissions to be in similar format.
2023-11-21 11:56:48 +00:00
Shahed Nasser
fd27bc0daa chore: update tsdocs of pricing module (#5648)
* chore: update tsdocs of pricing module

* Update money-amount.ts

---------

Co-authored-by: Riqwan Thamir <rmthamir@gmail.com>
2023-11-21 11:26:07 +00:00
github-actions[bot]
73799d4e9e chore(docs): Generated API Reference (#5662)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-11-21 10:45:38 +00:00
github-actions[bot]
d3e8efd573 chore(docs): Generated Docs Announcement Bar (automated) (#5661)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-11-21 09:18:07 +00:00
Shahed Nasser
9c7f95c3d5 docs: documentation for v1.18 (#5652)
* docs: documentation for v.17.5

* fix links

* updated version number
2023-11-21 08:57:11 +00:00
olivermrbl
adc60e519c chore: Release 2023-11-21 08:52:26 +00:00
github-actions[bot]
f4085dbede chore: Version Packages (#5622)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-21 08:46:09 +00:00
olivermrbl
7935c27b33 chore(changesets): Correct version bump 2023-11-21 08:25:30 +00:00
olivermrbl
b53ab22a7c chore(changesets): Minor-bump @medusajs/medusa 2023-11-20 18:27:40 +00:00
olivermrbl
ebf63dffc4 chore(medusa-oas-cli,medusa-source-shopify): Remove workspace versions 2023-11-20 18:24:30 +00:00
Riqwan Thamir
c4722715cd fix(product): when running migrations, prevent exploding on isolated case (#5643)
* fix(product): when running migrations, prevent exploding on isolated case

* chore: remove try catch block

* chore: added variant test fixes

* chore: update name of var
2023-11-20 18:08:28 +01:00
Shahed Nasser
c51dce164d docs: general fixes to references (#5653)
* fixed typedoc plugin's escape strategy

* move props comments to the associated property

* regenerate references
2023-11-17 19:36:58 +02:00
Bastien
b3093c3e3d feat(medusa): Add metadata to Product Category (#5599)
*  feat(migrations): add metadata column to product_category table in database to store additional information about each product category

*  feat(product-category.ts): add metadata field to ProductCategory model to store additional details
📝 docs(product-category.ts): add documentation for new metadata field in ProductCategory model

*  feat(product-category.ts): add metadata field to ProductCategoryInput type to support additional data

*  feat(ProductCategory.ts): add optional metadata field to ProductCategory model to store additional details

*  feat(product-categories): add metadata field to product categories for additional information storage
📝 docs(product-categories): add documentation for new metadata field in product categories

*  feat(product-categories): add 'metadata' field to default and allowed product category fields for enhanced data tracking

*  feat(product-category.ts): add metadata support to product categories
🔧 refactor(product-category.ts): import setMetadata from utils to handle metadata setting in a more efficient way

*  feat(models): add metadata field to AdminPostProductCategoriesCategoryReq and AdminPostProductCategoriesReq models to store additional information

* 📝 docs(api-reference): add metadata field to ProductCategory schema in both admin and store specs
🔧 fix(api-reference): make metadata field required in ProductCategory schema to ensure data consistency

* Create nine-fishes-matter.md

---------

Co-authored-by: Oli Juhl <59018053+olivermrbl@users.noreply.github.com>
2023-11-16 20:37:02 +01:00
Kasper Fabricius Kristensen
57573ed4d7 feat(medusa): Alternative Subscriber API and new ScheduledJobs API (#5624)
* workking subscribers API

* progress

* update registrar args

* cleanup

* progress

* progress

* tests

* rename to loaders

* rm build artifacts

* improve validation and change jobs args to object

* spread context on subscribe

* add changeset

* address comments

* fix spelling of warning and add warning on Redis not enabled for Scheduled Jobs

* fix tests

---------

Co-authored-by: Oli Juhl <59018053+olivermrbl@users.noreply.github.com>
2023-11-16 20:36:02 +01:00
Riqwan Thamir
4f0bea4909 fix(pricing): add missing migrations for pricing module (#5646) 2023-11-16 14:26:00 +00:00
Kasper Fabricius Kristensen
a67a8e7e90 fix(ui): Fixed CodeBlock line number width (#5640)
**What**
- Fixes the width of lineNumbers in the CodeBlock component according to the widest number.
- Introduces a new prop on snippets that allows users to hide the copy button. Also updated docs to reflect this.

Before:
![image](https://github.com/medusajs/medusa/assets/45367945/07852c2e-434c-44df-93b7-4078148cb74f)

After:
<img width="742" alt="image" src="https://github.com/medusajs/medusa/assets/45367945/5ce845f7-b8c7-411c-abfb-fa03448aeb1a">

Closes #5639
2023-11-16 10:50:04 +00:00