Commit Graph

3011 Commits

Author SHA1 Message Date
Shahed Nasser
8d453d35a9 docs: added details about expand, fields, and parameter types (#3325) 2023-02-23 17:12:51 +02:00
github-actions[bot]
8e5ebc9a1d chore(docs): Generated Docs Announcement Bar (automated) (#3310)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-02-22 14:45:49 +02:00
github-actions[bot]
e3305188bd chore(docs): Generated API Reference (#3308)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-02-22 14:45:23 +02:00
github-actions[bot]
3f5b7fbe7e chore(docs): Generated Services Reference (automated) (#3309)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-02-22 14:44:52 +02:00
olivermrbl
fefc248a41 chore(release): v1.7.8 2023-02-22 13:13:48 +01:00
Adrien de Peretti
5301a1e9d6 chore(medusa): Revert AbstractPaymentService deprecation (#3298) 2023-02-21 20:40:40 +01:00
Shahed Nasser
3084de0c02 chore: changed trigger for docs generation actions (#3304) 2023-02-21 18:11:32 +02:00
Adrien de Peretti
d11ab924b8 feat(medusa): Configurable returnable_items on order decorate totals (#3276) 2023-02-21 14:48:49 +01:00
github-actions[bot]
b393d74a10 chore(docs): Removed Docs Announcement Bar (automated) (#3292)
Co-authored-by: shahednasser <shahednasser@users.noreply.github.com>
2023-02-20 09:54:13 +02:00
Shahed Nasser
d8dcc4ce9a docs: added CORS common examples (#3284)
* docs: added CORS common examples

* fix lint errors
2023-02-17 15:42:46 +02:00
Shahed Nasser
d1abe7cd85 chore(docs): manually generated API reference to fix load issue (#3286) 2023-02-17 15:23:20 +02:00
Patrick
9690f07bc0 fix(oas): patch circular references in docs (#3285)
## What

Patch OAS circular references that causes the documentation to crash

## Test

* Run `yarn openapi:generate`
* Run `yarn redocly preview-docs docs/api/admin/openapi.yaml --config=./docs-util/redocly/config.yaml`
* Open preview docs url in a browser
* Expect the page to not crash

* Repeat with `yarn redocly preview-docs docs/api/store/openapi.yaml --config=./docs-util/redocly/config.yaml`
2023-02-17 12:42:11 +00:00
Oliver Windall Juhl
f88af0c28d fix(medusa): Received quantity on return lines (#3267) 2023-02-17 10:13:50 +00:00
Kasper Fabricius Kristensen
3a911091f1 hotfix(medusa-js): Export resources classes and make client public (#3271)
* export all ressource classes and make client public

* add changeset
2023-02-16 09:03:49 +01:00
github-actions[bot]
ef148cb9f4 chore(docs): Generated Services Reference (automated) (#3261)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-02-14 20:32:42 +02:00
github-actions[bot]
4fb22e8ba5 chore(docs): Generated API Reference (#3262)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-02-14 20:32:28 +02:00
github-actions[bot]
67f9429293 chore(docs): Generated Docs Announcement Bar (automated) (#3263) 2023-02-14 17:38:21 +01:00
olivermrbl
1bfbe27b9b chore(release): Publish 2023-02-14 17:30:40 +01:00
olivermrbl
da9fb4aaa8 chore: Lint package.json 2023-02-14 17:27:43 +01:00
Oliver Windall Juhl
968eb8fc6b fix(medusa): Refund amount on returns in claim flow (#3237) 2023-02-14 12:47:06 +01:00
olivermrbl
d48606d5dd Merge branch 'master' into develop 2023-02-14 11:28:02 +01:00
Adrien de Peretti
5e0273a370 chore(medusa): New totals calc. in Swap creation (#3191)
* feat(medusa): Cleanup swap creation flow

* revert test and package

* fix unit tests

* fix swap seeder that does not include the tax lines on the return line item

---------

Co-authored-by: Oliver Windall Juhl <59018053+olivermrbl@users.noreply.github.com>
2023-02-14 10:52:45 +01:00
Carlos R. L. Rodrigues
80452332d8 fix(medusa): Default sales channel on product create (#3249)
What:
Assign the default sales channel if none is provided while creating a new product.


FIXES: CORE-1114

Co-authored-by: Oliver Windall Juhl <59018053+olivermrbl@users.noreply.github.com>
2023-02-14 08:46:14 +00:00
josetr
10ff72c30a fix(medusa): Add missing scoped transaction on update currency endpoint (#3254) 2023-02-14 09:24:39 +01:00
github-actions[bot]
a2c3ba2c2c chore(docs): Removed Docs Announcement Bar (automated) (#3255)
Co-authored-by: shahednasser <shahednasser@users.noreply.github.com>
2023-02-14 09:55:40 +02:00
olivermrbl
66e7a384e3 Merge branch 'master' into develop 2023-02-13 18:53:54 +01:00
Patrick
cac13a88da feat(oas) - accurate model OAS representation - R to U (#3250)
### Scope

Models R to U

### What

Refactor OAS for models to accurately represent their shape in API responses.

### Why

About 33% of model fields are not accurately represented in the OAS. Most of the issues are:
- fields that can not be omitted in the response are not declared as `required`
- fields that could return `null` as their value are not declared as `nullable: true`

When using a code generator, these OAS issues would lead to inaccurate response shapes in the generated client.

### How

#### nullable
Fields meeting at least one of the following condition will be represented as `nullable: true` in OAS:
* The field is decorated with `@Column({ nullable: true })`
* The field is decorated with `@OneToOne`, `@ManyToOne`
* The field is decorated with `@DeleteDateColumn`

#### optional
Fields meeting at least one of the following conditions will never be listed as `required` in OAS and will be considered optional and could be omitted in the response:
* The field is decorated with `@OneToOne`, `@ManyToOne`, `@OneToMany`, `@ManyToMany`
* The field is decorated with `@FeatureFlagColumn`
* The field is decorated with `@Column({select: false})`
* The field is representing dynamic values not persisted in the database

Fields not meeting any of the conditions above will be declared as `required` and are expected to be present in the response.

### Test
* Ran OAS validator.
* Ran docs build script.

Expect OAS changes to be reflected in the API documentation.
2023-02-13 16:59:36 +00:00
Adrien de Peretti
4cb44a3a2e fix(medusa): Discount allocation precision issues (#3244) 2023-02-13 17:22:18 +01:00
Adrien de Peretti
bbbb3d8882 fix(medusa): Missing withTransaction on update in get-cart.ts (#3246) 2023-02-13 16:30:46 +01:00
Adrien de Peretti
a2cc084db8 fix(medusa): Missing withTransaction on calculateDiscountForLineItem (#3247) 2023-02-13 16:29:11 +01:00
github-actions[bot]
312b05ea5a chore(docs): Generated Services Reference (automated) (#3242)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-02-13 09:56:49 +02:00
Oliver Windall Juhl
8194d19b0e fix(medusa-plugin-sendgrid): Undefined order in method to build GiftCard data (#3238) 2023-02-12 19:18:36 +01:00
olivermrbl
4d2dc3c3a1 Merge branch 'master' into develop 2023-02-12 12:29:26 +01:00
Patrick
a59bd84e41 feat(oas) - accurate model OAS representation - PA to PU (#3223)
### Scope

Models PA to PU

### What

Refactor OAS for models to accurately represent their shape in API responses.

### Why

About 33% of model fields are not accurately represented in the OAS. Most of the issues are:
- fields that can not be omitted in the response are not declared as `required`
- fields that could return `null` as their value are not declared as `nullable: true`

When using a code generator, these OAS issues would lead to inaccurate response shapes in the generated client.

### How

#### nullable
Fields meeting at least one of the following condition will be represented as `nullable: true` in OAS:
* The field is decorated with `@Column({ nullable: true })`
* The field is decorated with `@OneToOne`, `@ManyToOne`
* The field is decorated with `@DeleteDateColumn`

#### optional
Fields meeting at least one of the following conditions will never be listed as `required` in OAS and will be considered optional and could be omitted in the response:
* The field is decorated with `@OneToOne`, `@ManyToOne`, `@OneToMany`, `@ManyToMany`
* The field is decorated with `@FeatureFlagColumn`
* The field is decorated with `@Column({select: false})`
* The field is representing dynamic values not persisted in the database

Fields not meeting any of the conditions above will be declared as `required` and are expected to be present in the response.

### Test
* Ran OAS validator.
* Ran docs build script.

Expect OAS changes to be reflected in the API documentation.
2023-02-10 15:35:24 +00:00
Oliver Windall Juhl
f0ab7fda80 chore: Update bug issue template 2023-02-10 10:13:48 +01:00
olivermrbl
4e4da52e8c Merge branch 'master' into develop 2023-02-10 09:27:19 +01:00
Oliver Windall Juhl
472f96d7fb fix(medusa): Missing refund amount when creating claim (#3224) 2023-02-10 09:26:54 +01:00
github-actions[bot]
91234c14b5 chore(docs): Generated Services Reference (automated) (#3227)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-02-09 19:55:08 +02:00
Adrien de Peretti
eee9283818 feat(medusa): Allow empty fields/expand (#3220) 2023-02-09 18:05:56 +01:00
olivermrbl
d3feb62b85 Merge branch 'master' into develop 2023-02-09 17:52:41 +01:00
Frane Polić
61b0b2f3aa fix(medusa): Pass query transformer config in storefront controllers (#3219) 2023-02-09 17:52:04 +01:00
Adrien de Peretti
8c5219a31e chore: Update ignored files for npm (#3217) 2023-02-09 17:25:14 +01:00
Adrien de Peretti
6e443dc708 feat(medusa): Improve addShippingMethod on store cart route (#3222) 2023-02-09 16:55:40 +01:00
Patrick
507ad00bec feat(oas) - accurate model OAS representation - F to O (#3210)
### Scope

Models F to O

### What

Refactor OAS for models to accurately represent their shape in API responses.

### Why

About 33% of model fields are not accurately represented in the OAS. Most of the issues are:
- fields that can not be omitted in the response are not declared as `required`
- fields that could return `null` as their value are not declared as `nullable: true`

When using a code generator, these OAS issues would lead to inaccurate response shapes in the generated client.

### How

#### nullable
Fields meeting at least one of the following condition will be represented as `nullable: true` in OAS:
* The field is decorated with `@Column({ nullable: true })`
* The field is decorated with `@OneToOne`, `@ManyToOne`
* The field is decorated with `@DeleteDateColumn`

#### optional
Fields meeting at least one of the following conditions will never be listed as `required` in OAS and will be considered optional and could be omitted in the response:
* The field is decorated with `@OneToOne`, `@ManyToOne`, `@OneToMany`, `@ManyToMany`
* The field is decorated with `@FeatureFlagColumn`
* The field is decorated with `@Column({select: false})`
* The field is representing dynamic values not persisted in the database

Fields not meeting any of the conditions above will be declared as `required` and are expected to be present in the response.

### Test
* Ran OAS validator.
* Ran docs build script.

Expect OAS changes to be reflected in the API documentation.
2023-02-09 15:03:11 +00:00
github-actions[bot]
14b2de94e2 chore(docs): Generated API Reference (#3211)
Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
2023-02-09 09:50:55 +02:00
Carlos R. L. Rodrigues
d859ccf551 Feat(medusa) - delete cascade modules associations (#3190)
* delete cascade sales channel x locations, variant x inventory item
2023-02-08 17:23:47 -03:00
github-actions[bot]
9997485c55 chore(docs): Generated Docs Announcement Bar (automated) (#3212) 2023-02-08 20:04:13 +01:00
Shahed Nasser
cf946b26fa docs: added upgrade guide for v1.7.6 (#3207) 2023-02-08 19:51:47 +01:00
olivermrbl
3b474ec35c chore(release): Publish 2023-02-08 19:35:44 +01:00
Adrien de Peretti
bfa33f444c fix(medusa): Applying Discounts (with Conditions) on DraftOrders and Carts (#3197) 2023-02-08 19:01:23 +01:00