Merge remote-tracking branch 'origin/master' into develop

This commit is contained in:
Sebastian Rindom
2021-11-20 16:00:44 +01:00
76 changed files with 4233 additions and 193 deletions
@@ -51,6 +51,8 @@ For customizations that are more particular to your project you can extend your
## Starting your Medusa server
> Note: For your server to run correctly you should configure your `COOKIE_SECRET` and `JWT_SECRET` environment variables by adding a `.env` file to the root of your Medusa project.
After your project has been set up with `medusa new`, you can run the following commands to start your server:
```shell
@@ -410,6 +410,38 @@ describe("/admin/orders", () => {
)
})
it("creates a claim on order with discount", async () => {
const api = useApi()
const response = await api.post(
"/admin/orders/discount-order/claims",
{
type: "refund",
claim_items: [
{
item_id: "test-item",
quantity: 1,
reason: "production_failure",
tags: ["fluff"],
images: ["https://test.image.com"],
},
],
additional_items: [
{
variant_id: "test-variant",
quantity: 1,
},
],
},
{
headers: {
authorization: "Bearer test_token",
},
}
)
expect(response.status).toEqual(200)
})
it("creates a claim on a claim", async () => {
const api = useApi()
+80 -7
View File
@@ -1,16 +1,17 @@
const {
ShippingProfile,
Customer,
MoneyAmount,
Discount,
DiscountRule,
LineItem,
Country,
ShippingOption,
ShippingMethod,
MoneyAmount,
Order,
Payment,
Product,
ProductVariant,
Region,
Payment,
Order,
ShippingMethod,
ShippingOption,
ShippingProfile,
Swap,
} = require("@medusajs/medusa")
@@ -320,4 +321,76 @@ module.exports = async (connection, data = {}) => {
id: "o-pay4",
...paymentTemplate(),
})
const drule = manager.create(DiscountRule, {
id: "test-rule",
description: "Test Discount",
type: "percentage",
value: 10,
allocation: "total",
})
const discount = manager.create(Discount, {
id: "test-discount-o",
code: "TEST1234",
is_dynamic: false,
rule: drule,
is_disabled: false,
regions: [
{
id: "test-region",
},
],
})
await manager.save(discount)
const payment = manager.create(Payment, {
id: "test-payment-d",
amount: 10000,
currency_code: "usd",
amount_refunded: 0,
provider_id: "test-pay",
captured_at: new Date(),
data: {},
})
const discountedOrder = manager.create(Order, {
id: "discount-order",
customer_id: "test-customer",
email: "test@email.com",
payment_status: "captured",
fulfillment_status: "fulfilled",
discounts: [discount],
billing_address: {
id: "test-billing-address",
first_name: "lebron",
},
shipping_address: {
id: "test-shipping-address",
first_name: "lebron",
country_code: "us",
},
region_id: "test-region",
currency_code: "usd",
tax_rate: 0,
payments: [payment],
items: [],
})
await manager.save(discountedOrder)
const dli = manager.create(LineItem, {
id: "test-item",
fulfilled_quantity: 1,
returned_quantity: 0,
title: "Line Item",
description: "Line Item Desc",
thumbnail: "https://test.js/1234",
unit_price: 8000,
quantity: 1,
variant_id: "test-variant",
order_id: "discount-order",
})
await manager.save(dli)
}
@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.18](https://github.com/medusajs/medusa/compare/babel-preset-medusa-package@1.1.17...babel-preset-medusa-package@1.1.18) (2021-11-11)
**Note:** Version bump only for package babel-preset-medusa-package
## [1.1.17](https://github.com/medusajs/medusa/compare/babel-preset-medusa-package@1.1.15...babel-preset-medusa-package@1.1.17) (2021-10-18)
**Note:** Version bump only for package babel-preset-medusa-package
@@ -1,8 +1,8 @@
const r = require(`./resolver`);
const r = require(`./resolver`)
function preset(context, options = {}) {
const { debug = false, nodeVersion = `10.14.0` } = options;
const { NODE_ENV, BABEL_ENV } = process.env;
const { debug = false, nodeVersion = `10.14.0` } = options
const { NODE_ENV, BABEL_ENV } = process.env
const nodeConfig = {
corejs: 3,
@@ -10,10 +10,10 @@ function preset(context, options = {}) {
targets: {
node: nodeVersion,
},
};
}
return {
presets: [r(`@babel/preset-env`)],
presets: [r(`@babel/preset-env`), r(`@babel/preset-typescript`)],
plugins: [
r(`babel-plugin-transform-typescript-metadata`),
r(`@babel/plugin-proposal-optional-chaining`),
@@ -23,7 +23,7 @@ function preset(context, options = {}) {
r(`@babel/plugin-transform-instanceof`),
r(`@babel/plugin-transform-runtime`),
].filter(Boolean),
};
}
}
module.exports = preset;
module.exports = preset
@@ -1,6 +1,6 @@
{
"name": "babel-preset-medusa-package",
"version": "1.1.17",
"version": "1.1.18",
"author": "Sebastian Rindom <sebastian@mrbltech.com>",
"repository": {
"type": "git",
@@ -15,6 +15,7 @@
"@babel/plugin-transform-instanceof": "^7.12.1",
"@babel/plugin-transform-runtime": "^7.12.1",
"@babel/preset-env": "^7.12.7",
"@babel/preset-typescript": "^7.16.0",
"babel-plugin-transform-typescript-metadata": "^0.3.1",
"core-js": "^3.7.0"
},
+4
View File
@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.23](https://github.com/medusajs/medusa/compare/@medusajs/medusa-cli@1.1.22...@medusajs/medusa-cli@1.1.23) (2021-11-11)
**Note:** Version bump only for package @medusajs/medusa-cli
## [1.1.22](https://github.com/medusajs/medusa/compare/@medusajs/medusa-cli@1.1.21...@medusajs/medusa-cli@1.1.22) (2021-10-18)
**Note:** Version bump only for package @medusajs/medusa-cli
+2 -2
View File
@@ -1,6 +1,6 @@
{
"name": "@medusajs/medusa-cli",
"version": "1.1.22",
"version": "1.1.23",
"description": "Command Line interface for Medusa Commerce",
"main": "dist/index.js",
"bin": {
@@ -52,7 +52,7 @@
"joi-objectid": "^3.0.1",
"meant": "^1.0.1",
"medusa-core-utils": "^0.1.27",
"medusa-telemetry": "^0.0.9",
"medusa-telemetry": "^0.0.10",
"netrc-parser": "^3.1.6",
"open": "^8.0.6",
"ora": "^5.4.1",
+10
View File
@@ -3,6 +3,16 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.28](https://github.com/medusajs/medusa/compare/medusa-core-utils@1.1.27...medusa-core-utils@1.1.28) (2021-11-19)
**Note:** Version bump only for package medusa-core-utils
## [1.1.27](https://github.com/medusajs/medusa/compare/medusa-core-utils@1.1.26...medusa-core-utils@1.1.27) (2021-11-19)
### Features
- Typescript for API layer ([#817](https://github.com/medusajs/medusa/issues/817)) ([373532e](https://github.com/medusajs/medusa/commit/373532ecbc8196f47e71af95a8cf82a14a4b1f9e))
## [1.1.26](https://github.com/medusajs/medusa/compare/medusa-core-utils@1.1.25...medusa-core-utils@1.1.26) (2021-10-18)
**Note:** Version bump only for package medusa-core-utils
+3 -3
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-core-utils",
"version": "1.1.26",
"version": "1.1.28",
"description": "Core utils for Medusa",
"main": "dist/index.js",
"repository": {
@@ -37,5 +37,5 @@
"joi": "^17.3.0",
"joi-objectid": "^3.0.1"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
}
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
+4
View File
@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [0.0.23](https://github.com/medusajs/medusa/compare/medusa-dev-cli@0.0.22...medusa-dev-cli@0.0.23) (2021-11-11)
**Note:** Version bump only for package medusa-dev-cli
## [0.0.22](https://github.com/medusajs/medusa/compare/medusa-dev-cli@0.0.20...medusa-dev-cli@0.0.22) (2021-10-18)
**Note:** Version bump only for package medusa-dev-cli
+2 -2
View File
@@ -1,7 +1,7 @@
{
"name": "medusa-dev-cli",
"description": "CLI helpers for contributors working on Medusa",
"version": "0.0.22",
"version": "0.0.23",
"author": "Sebastian Rindom <skrindom@gmail.com>",
"bin": {
"medusa-dev": "./dist/index.js"
@@ -24,7 +24,7 @@
"devDependencies": {
"@babel/cli": "^7.12.1",
"@babel/core": "^7.12.3",
"babel-preset-medusa-package": "^1.1.17",
"babel-preset-medusa-package": "^1.1.18",
"cross-env": "^7.0.3"
},
"homepage": "https://github.com/medusajs/medusa/tree/master/packages/medusa-dev-cli#readme",
+8
View File
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.0.6](https://github.com/medusajs/medusa/compare/medusa-file-s3@1.0.5...medusa-file-s3@1.0.6) (2021-11-19)
**Note:** Version bump only for package medusa-file-s3
## [1.0.5](https://github.com/medusajs/medusa/compare/medusa-file-s3@1.0.4...medusa-file-s3@1.0.5) (2021-11-19)
**Note:** Version bump only for package medusa-file-s3
## [1.0.4](https://github.com/medusajs/medusa/compare/medusa-file-s3@1.0.3...medusa-file-s3@1.0.4) (2021-10-18)
**Note:** Version bump only for package medusa-file-s3
+5 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-file-s3",
"version": "1.0.4",
"version": "1.0.6",
"description": "AWS s3 file connector for Medusa",
"main": "index.js",
"repository": {
@@ -40,7 +40,8 @@
"aws-sdk": "^2.983.0",
"body-parser": "^1.19.0",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29"
}
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31"
},
"gitHead": "aa460f63591f9625f1fe98749b34172e528bed7f"
}
+8
View File
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-file-spaces@1.1.30...medusa-file-spaces@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-file-spaces
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-file-spaces@1.1.29...medusa-file-spaces@1.1.30) (2021-11-19)
**Note:** Version bump only for package medusa-file-spaces
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-file-spaces@1.1.28...medusa-file-spaces@1.1.29) (2021-10-18)
**Note:** Version bump only for package medusa-file-spaces
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-file-spaces",
"version": "1.1.29",
"version": "1.1.31",
"description": "Digital Ocean Spaces file connector for Medusa",
"main": "index.js",
"repository": {
@@ -40,9 +40,9 @@
"aws-sdk": "^2.710.0",
"body-parser": "^1.19.0",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29",
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31",
"stripe": "^8.50.0"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "aa460f63591f9625f1fe98749b34172e528bed7f"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.28](https://github.com/medusajs/medusa/compare/medusa-fulfillment-manual@1.1.27...medusa-fulfillment-manual@1.1.28) (2021-11-19)
**Note:** Version bump only for package medusa-fulfillment-manual
## [1.1.27](https://github.com/medusajs/medusa/compare/medusa-fulfillment-manual@1.1.26...medusa-fulfillment-manual@1.1.27) (2021-11-19)
**Note:** Version bump only for package medusa-fulfillment-manual
## [1.1.26](https://github.com/medusajs/medusa/compare/medusa-fulfillment-manual@1.1.25...medusa-fulfillment-manual@1.1.26) (2021-10-18)
**Note:** Version bump only for package medusa-fulfillment-manual
@@ -1,6 +1,6 @@
{
"name": "medusa-fulfillment-manual",
"version": "1.1.26",
"version": "1.1.28",
"description": "A manual fulfillment provider for Medusa",
"main": "index.js",
"repository": {
@@ -36,7 +36,7 @@
"@babel/plugin-transform-instanceof": "^7.8.3",
"@babel/runtime": "^7.7.6",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26"
"medusa-core-utils": "^1.1.28"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.32](https://github.com/medusajs/medusa/compare/medusa-fulfillment-webshipper@1.1.31...medusa-fulfillment-webshipper@1.1.32) (2021-11-19)
**Note:** Version bump only for package medusa-fulfillment-webshipper
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-fulfillment-webshipper@1.1.30...medusa-fulfillment-webshipper@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-fulfillment-webshipper
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-fulfillment-webshipper@1.1.29...medusa-fulfillment-webshipper@1.1.30) (2021-10-18)
**Note:** Version bump only for package medusa-fulfillment-webshipper
@@ -1,6 +1,6 @@
{
"name": "medusa-fulfillment-webshipper",
"version": "1.1.30",
"version": "1.1.32",
"description": "Webshipper Fulfillment provider for Medusa",
"main": "index.js",
"repository": {
@@ -37,7 +37,7 @@
"body-parser": "^1.19.0",
"cors": "^2.8.5",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26"
"medusa-core-utils": "^1.1.28"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
+11
View File
@@ -3,6 +3,17 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-interfaces@1.1.28...medusa-interfaces@1.1.29) (2021-11-19)
**Note:** Version bump only for package medusa-interfaces
## [1.1.28](https://github.com/medusajs/medusa/compare/medusa-interfaces@1.1.27...medusa-interfaces@1.1.28) (2021-11-19)
### Features
- Allow retrieval of soft-deleted products ([#723](https://github.com/medusajs/medusa/issues/723)) ([1e50aee](https://github.com/medusajs/medusa/commit/1e50aee4feb55092560dd4a9c51a0671363e8576))
- Typescript for API layer ([#817](https://github.com/medusajs/medusa/issues/817)) ([373532e](https://github.com/medusajs/medusa/commit/373532ecbc8196f47e71af95a8cf82a14a4b1f9e))
## [1.1.27](https://github.com/medusajs/medusa/compare/medusa-interfaces@1.1.26...medusa-interfaces@1.1.27) (2021-10-18)
**Note:** Version bump only for package medusa-interfaces
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-interfaces",
"version": "1.1.27",
"version": "1.1.29",
"description": "Core interfaces for Medusa",
"main": "dist/index.js",
"repository": {
@@ -35,7 +35,7 @@
"typeorm": "0.x"
},
"dependencies": {
"medusa-core-utils": "^1.1.26"
"medusa-core-utils": "^1.1.28"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
}
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
+20
View File
@@ -0,0 +1,20 @@
# Change Log
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.0.3](https://github.com/medusajs/medusa-js/compare/@medusajs/medusa-js@1.0.2...@medusajs/medusa-js@1.0.3) (2021-11-19)
### Bug Fixes
- release ([5fa4848](https://github.com/medusajs/medusa-js/commit/5fa4848b17a9dd432c2361e5d9485950494a2bc6))
## [1.0.2](https://github.com/medusajs/medusa-js/compare/@medusajs/medusa-js@1.0.1...@medusajs/medusa-js@1.0.2) (2021-11-19)
**Note:** Version bump only for package @medusajs/medusa-js
## 1.0.1 (2021-11-19)
### Features
- Typescript for API layer ([#817](https://github.com/medusajs/medusa-js/issues/817)) ([373532e](https://github.com/medusajs/medusa-js/commit/373532ecbc8196f47e71af95a8cf82a14a4b1f9e))
+7 -3
View File
@@ -1,6 +1,6 @@
{
"name": "@medusajs/medusa-js",
"version": "1.0.1-canary.1",
"version": "1.0.3",
"description": "Client for Medusa Commerce Rest API",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",
@@ -8,12 +8,14 @@
"dist/**/*"
],
"scripts": {
"prepare": "cross-env NODE_ENV=production npm run build",
"build": "tsc --build",
"test": "jest --config jestconfig.json"
},
"author": "Oliver Juhl",
"license": "MIT",
"dependencies": {
"@medusajs/medusa": "^1.1.55",
"axios": "^0.21.0",
"retry-axios": "^2.6.0"
},
@@ -26,9 +28,11 @@
},
"devDependencies": {
"@types/jest": "^26.0.19",
"cross-env": "^7.0.3",
"eslint": "^8.2.0",
"jest": "^26.6.3",
"prettier": "^2.2.1",
"typescript": "^4.1.3"
}
}
},
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -1,5 +1,5 @@
import {
StoreCartsCartRes,
StoreCartsRes,
StoreCartsDeleteRes,
StorePostCartsCartLineItemsItemReq,
StorePostCartsCartLineItemsReq,
@@ -17,7 +17,7 @@ class LineItemsResource extends BaseResource {
create(
cart_id: string,
payload: StorePostCartsCartLineItemsReq
): AxiosPromise<StoreCartsCartRes> {
): AxiosPromise<StoreCartsRes> {
const path = `/store/carts/${cart_id}/line-items`
return this.client.request("POST", path, payload)
}
@@ -34,7 +34,7 @@ class LineItemsResource extends BaseResource {
cart_id: string,
line_id: string,
payload: StorePostCartsCartLineItemsItemReq
): AxiosPromise<StoreCartsCartRes> {
): AxiosPromise<StoreCartsRes> {
const path = `/store/carts/${cart_id}/line-items/${line_id}`
return this.client.request("POST", path, payload)
}
+1 -1
View File
@@ -37,7 +37,7 @@ class OrdersResource extends BaseResource {
val = value.join(",")
}
return `${key}=${encodeURIComponent(val)}`
return `${key}=${encodeURIComponent(val as string)}`
})
path = `/store/orders?${queryString.join("&")}`
File diff suppressed because it is too large Load Diff
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.33](https://github.com/medusajs/medusa/compare/medusa-payment-adyen@1.1.32...medusa-payment-adyen@1.1.33) (2021-11-19)
**Note:** Version bump only for package medusa-payment-adyen
## [1.1.32](https://github.com/medusajs/medusa/compare/medusa-payment-adyen@1.1.31...medusa-payment-adyen@1.1.32) (2021-11-19)
**Note:** Version bump only for package medusa-payment-adyen
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-payment-adyen@1.1.30...medusa-payment-adyen@1.1.31) (2021-10-18)
**Note:** Version bump only for package medusa-payment-adyen
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-payment-adyen",
"version": "1.1.31",
"version": "1.1.33",
"description": "Adyen Payment provider for Medusa Commerce",
"main": "index.js",
"repository": {
@@ -24,7 +24,7 @@
"cross-env": "^7.0.2",
"eslint": "^6.8.0",
"jest": "^25.5.2",
"medusa-test-utils": "^1.1.29"
"medusa-test-utils": "^1.1.31"
},
"scripts": {
"build": "babel src -d .",
@@ -42,7 +42,7 @@
"body-parser": "^1.19.0",
"cors": "^2.8.5",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26"
"medusa-core-utils": "^1.1.28"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.33](https://github.com/medusajs/medusa/compare/medusa-payment-klarna@1.1.32...medusa-payment-klarna@1.1.33) (2021-11-19)
**Note:** Version bump only for package medusa-payment-klarna
## [1.1.32](https://github.com/medusajs/medusa/compare/medusa-payment-klarna@1.1.31...medusa-payment-klarna@1.1.32) (2021-11-19)
**Note:** Version bump only for package medusa-payment-klarna
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-payment-klarna@1.1.30...medusa-payment-klarna@1.1.31) (2021-10-18)
**Note:** Version bump only for package medusa-payment-klarna
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-payment-klarna",
"version": "1.1.31",
"version": "1.1.33",
"description": "Klarna Payment provider for Medusa Commerce",
"main": "index.js",
"repository": {
@@ -40,8 +40,8 @@
"axios": "^0.21.0",
"body-parser": "^1.19.0",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29"
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.0.10](https://github.com/medusajs/medusa/compare/medusa-payment-manual@1.0.9...medusa-payment-manual@1.0.10) (2021-11-19)
**Note:** Version bump only for package medusa-payment-manual
## [1.0.9](https://github.com/medusajs/medusa/compare/medusa-payment-manual@1.0.8...medusa-payment-manual@1.0.9) (2021-11-19)
**Note:** Version bump only for package medusa-payment-manual
## [1.0.8](https://github.com/medusajs/medusa/compare/medusa-payment-manual@1.0.7...medusa-payment-manual@1.0.8) (2021-10-18)
**Note:** Version bump only for package medusa-payment-manual
+3 -3
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-payment-manual",
"version": "1.0.8",
"version": "1.0.10",
"description": "A dummy payment provider to be used for testing or manual payments",
"main": "index.js",
"repository": {
@@ -25,7 +25,7 @@
"cross-env": "^5.2.1",
"eslint": "^6.8.0",
"jest": "^25.5.2",
"medusa-test-utils": "^1.1.29"
"medusa-test-utils": "^1.1.31"
},
"scripts": {
"build": "babel src -d . --ignore **/__tests__",
@@ -36,5 +36,5 @@
"peerDependencies": {
"medusa-interfaces": "1.x"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.0.32](https://github.com/medusajs/medusa/compare/medusa-payment-paypal@1.0.30...medusa-payment-paypal@1.0.32) (2021-11-19)
**Note:** Version bump only for package medusa-payment-paypal
## [1.0.31](https://github.com/medusajs/medusa/compare/medusa-payment-paypal@1.0.30...medusa-payment-paypal@1.0.31) (2021-11-19)
**Note:** Version bump only for package medusa-payment-paypal
## [1.0.30](https://github.com/medusajs/medusa/compare/medusa-payment-paypal@1.0.29...medusa-payment-paypal@1.0.30) (2021-10-18)
**Note:** Version bump only for package medusa-payment-paypal
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-payment-paypal",
"version": "1.0.30",
"version": "1.0.32",
"description": "Paypal Payment provider for Meduas Commerce",
"main": "index.js",
"repository": {
@@ -26,8 +26,8 @@
"cross-env": "^5.2.1",
"eslint": "^6.8.0",
"jest": "^25.5.2",
"medusa-interfaces": "^1.1.27",
"medusa-test-utils": "^1.1.29"
"medusa-interfaces": "^1.1.29",
"medusa-test-utils": "^1.1.31"
},
"scripts": {
"build": "babel src -d . --ignore **/__tests__,**/__mocks__",
@@ -42,7 +42,7 @@
"@paypal/checkout-server-sdk": "^1.0.2",
"body-parser": "^1.19.0",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26"
"medusa-core-utils": "^1.1.28"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
}
@@ -1,7 +1,15 @@
import _ from "lodash"
import { humanizeAmount, zeroDecimalCurrencies } from "medusa-core-utils"
import PayPal from "@paypal/checkout-server-sdk"
import { PaymentService } from "medusa-interfaces"
function roundToTwo(num, currency) {
if (zeroDecimalCurrencies.includes(currency.toLowerCase())) {
return `${num}`
}
return num.toFixed(2)
}
class PayPalProviderService extends PaymentService {
static identifier = "paypal"
@@ -101,7 +109,10 @@ class PayPalProviderService extends PaymentService {
custom_id: cart.id,
amount: {
currency_code: currency_code.toUpperCase(),
value: (amount / 100).toFixed(2),
value: roundToTwo(
humanizeAmount(amount, currency_code),
currency_code
),
},
},
],
@@ -193,7 +204,10 @@ class PayPalProviderService extends PaymentService {
value: {
amount: {
currency_code: currency_code.toUpperCase(),
value: (cart.total / 100).toFixed(2),
value: roundToTwo(
humanizeAmount(cart.total, currency_code),
currency_code
),
},
},
},
@@ -254,7 +268,10 @@ class PayPalProviderService extends PaymentService {
request.requestBody({
amount: {
currency_code: payment.currency_code.toUpperCase(),
value: (amountToRefund / 100).toFixed(2),
value: roundToTwo(
humanizeAmount(amountToRefund, payment.currency_code),
payment.currency_code
),
},
})
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.32](https://github.com/medusajs/medusa/compare/medusa-payment-stripe@1.1.31...medusa-payment-stripe@1.1.32) (2021-11-19)
**Note:** Version bump only for package medusa-payment-stripe
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-payment-stripe@1.1.30...medusa-payment-stripe@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-payment-stripe
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-payment-stripe@1.1.29...medusa-payment-stripe@1.1.30) (2021-10-18)
**Note:** Version bump only for package medusa-payment-stripe
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-payment-stripe",
"version": "1.1.30",
"version": "1.1.32",
"description": "Stripe Payment provider for Meduas Commerce",
"main": "index.js",
"repository": {
@@ -26,7 +26,7 @@
"cross-env": "^5.2.1",
"eslint": "^6.8.0",
"jest": "^25.5.2",
"medusa-test-utils": "^1.1.29"
"medusa-test-utils": "^1.1.31"
},
"scripts": {
"build": "babel src -d . --ignore **/__tests__",
@@ -40,8 +40,8 @@
"dependencies": {
"body-parser": "^1.19.0",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-core-utils": "^1.1.28",
"stripe": "^8.50.0"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-plugin-add-ons@1.1.30...medusa-plugin-add-ons@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-add-ons
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-plugin-add-ons@1.1.29...medusa-plugin-add-ons@1.1.30) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-add-ons
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-plugin-add-ons@1.1.28...medusa-plugin-add-ons@1.1.29) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-add-ons
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-add-ons",
"version": "1.1.29",
"version": "1.1.31",
"description": "Add-on plugin for Medusa Commerce",
"main": "index.js",
"repository": {
@@ -25,7 +25,7 @@
"cross-env": "^7.0.2",
"eslint": "^6.8.0",
"jest": "^25.5.2",
"medusa-test-utils": "^1.1.29"
"medusa-test-utils": "^1.1.31"
},
"scripts": {
"build": "babel src -d . --ignore **/__tests__",
@@ -37,8 +37,8 @@
"body-parser": "^1.19.0",
"cors": "^2.8.5",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-core-utils": "^1.1.28",
"redis": "^3.0.2"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -0,0 +1,15 @@
# Change Log
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [0.0.3](https://github.com/medusajs/medusa/compare/medusa-plugin-algolia@0.0.2...medusa-plugin-algolia@0.0.3) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-algolia
## 0.0.2 (2021-11-19)
### Features
- Algolia plugin for medusa ([#718](https://github.com/medusajs/medusa/issues/718)) ([8ce9b20](https://github.com/medusajs/medusa/commit/8ce9b20222e1f4db75f730898549f0ed09eb1574))
- Typescript for API layer ([#817](https://github.com/medusajs/medusa/issues/817)) ([373532e](https://github.com/medusajs/medusa/commit/373532ecbc8196f47e71af95a8cf82a14a4b1f9e))
+5 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-algolia",
"version": "0.0.1",
"version": "0.0.3",
"description": "Search support for algolia",
"main": "index.js",
"repository": {
@@ -24,8 +24,8 @@
"algoliasearch": "^4.10.5",
"body-parser": "^1.19.0",
"lodash": "^4.17.21",
"medusa-core-utils": "^1.1.20",
"medusa-interfaces": "1.x"
"medusa-core-utils": "^1.1.28",
"medusa-interfaces": "^1.1.29"
},
"devDependencies": {
"@babel/cli": "^7.7.5",
@@ -41,5 +41,6 @@
"cross-env": "^5.2.1",
"eslint": "^6.8.0",
"jest": "^25.5.2"
}
},
"gitHead": "aa460f63591f9625f1fe98749b34172e528bed7f"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.37](https://github.com/medusajs/medusa/compare/medusa-plugin-brightpearl@1.1.36...medusa-plugin-brightpearl@1.1.37) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-brightpearl
## [1.1.36](https://github.com/medusajs/medusa/compare/medusa-plugin-brightpearl@1.1.35...medusa-plugin-brightpearl@1.1.36) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-brightpearl
## [1.1.35](https://github.com/medusajs/medusa/compare/medusa-plugin-brightpearl@1.1.34...medusa-plugin-brightpearl@1.1.35) (2021-10-26)
### Bug Fixes
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-brightpearl",
"version": "1.1.35",
"version": "1.1.37",
"description": "Brightpearl plugin for Medusa Commerce",
"main": "index.js",
"repository": {
@@ -27,8 +27,8 @@
"cross-env": "^7.0.2",
"eslint": "^6.8.0",
"jest": "^25.5.2",
"medusa-interfaces": "^1.1.27",
"medusa-test-utils": "^1.1.29",
"medusa-interfaces": "^1.1.29",
"medusa-test-utils": "^1.1.31",
"prettier": "^2.0.5"
},
"scripts": {
@@ -44,8 +44,8 @@
"axios": "^0.19.2",
"axios-rate-limit": "^1.2.1",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-core-utils": "^1.1.28",
"randomatic": "^3.1.1"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,16 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.34](https://github.com/medusajs/medusa/compare/medusa-plugin-contentful@1.1.33...medusa-plugin-contentful@1.1.34) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-contentful
## [1.1.33](https://github.com/medusajs/medusa/compare/medusa-plugin-contentful@1.1.32...medusa-plugin-contentful@1.1.33) (2021-11-19)
### Bug Fixes
- ignore tests in build output ([#579](https://github.com/medusajs/medusa/issues/579)) ([53178cb](https://github.com/medusajs/medusa/commit/53178cbda3b4f5e9ac30829c99b4d4df6616a0cf))
## [1.1.32](https://github.com/medusajs/medusa/compare/medusa-plugin-contentful@1.1.31...medusa-plugin-contentful@1.1.32) (2021-10-25)
### Bug Fixes
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-contentful",
"version": "1.1.32",
"version": "1.1.34",
"description": "Contentful plugin for Medusa Commerce",
"main": "index.js",
"repository": {
@@ -39,9 +39,9 @@
"body-parser": "^1.19.0",
"contentful-management": "^5.27.1",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29",
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31",
"redis": "^3.0.2"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-plugin-economic@1.1.30...medusa-plugin-economic@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-economic
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-plugin-economic@1.1.29...medusa-plugin-economic@1.1.30) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-economic
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-plugin-economic@1.1.28...medusa-plugin-economic@1.1.29) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-economic
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-economic",
"version": "1.1.29",
"version": "1.1.31",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-economic",
"version": "1.1.29",
"version": "1.1.31",
"description": "E-conomic financial reporting",
"main": "index.js",
"repository": {
@@ -39,9 +39,9 @@
"axios": "^0.19.2",
"body-parser": "^1.19.0",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29",
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31",
"moment": "^2.27.0"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-plugin-mailchimp@1.1.30...medusa-plugin-mailchimp@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-mailchimp
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-plugin-mailchimp@1.1.29...medusa-plugin-mailchimp@1.1.30) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-mailchimp
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-plugin-mailchimp@1.1.28...medusa-plugin-mailchimp@1.1.29) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-mailchimp
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-mailchimp",
"version": "1.1.29",
"version": "1.1.31",
"description": "Mailchimp newsletter subscriptions",
"main": "index.js",
"repository": {
@@ -40,8 +40,8 @@
"cors": "^2.8.5",
"express": "^4.17.1",
"mailchimp-api-v3": "^1.14.0",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29"
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [0.0.9](https://github.com/medusajs/medusa/compare/medusa-plugin-meilisearch@0.0.8...medusa-plugin-meilisearch@0.0.9) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-meilisearch
## [0.0.8](https://github.com/medusajs/medusa/compare/medusa-plugin-meilisearch@0.0.7...medusa-plugin-meilisearch@0.0.8) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-meilisearch
## [0.0.7](https://github.com/medusajs/medusa/compare/medusa-plugin-meilisearch@0.0.6...medusa-plugin-meilisearch@0.0.7) (2021-11-03)
### Bug Fixes
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-meilisearch",
"version": "0.0.7",
"version": "0.0.9",
"description": "A starter for Medusa projects.",
"main": "index.js",
"repository": {
@@ -23,8 +23,8 @@
"dependencies": {
"body-parser": "^1.19.0",
"lodash": "^4.17.21",
"medusa-core-utils": "^1.1.26",
"medusa-interfaces": "^1.1.27",
"medusa-core-utils": "^1.1.28",
"medusa-interfaces": "^1.1.29",
"meilisearch": "^0.20.0"
},
"devDependencies": {
@@ -41,5 +41,6 @@
"cross-env": "^5.2.1",
"eslint": "^6.8.0",
"jest": "^25.5.2"
}
},
"gitHead": "aa460f63591f9625f1fe98749b34172e528bed7f"
}
@@ -3,6 +3,16 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-plugin-permissions@1.1.30...medusa-plugin-permissions@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-permissions
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-plugin-permissions@1.1.29...medusa-plugin-permissions@1.1.30) (2021-11-19)
### Features
- Typescript for API layer ([#817](https://github.com/medusajs/medusa/issues/817)) ([373532e](https://github.com/medusajs/medusa/commit/373532ecbc8196f47e71af95a8cf82a14a4b1f9e))
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-plugin-permissions@1.1.28...medusa-plugin-permissions@1.1.29) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-permissions
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-permissions",
"version": "1.1.29",
"version": "1.1.31",
"description": "Role permission for Medusa core",
"main": "dist/index.js",
"repository": {
@@ -32,9 +32,9 @@
"medusa-interfaces": "1.x"
},
"dependencies": {
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29",
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31",
"mongoose": "^5.8.0"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "aa460f63591f9625f1fe98749b34172e528bed7f"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [0.0.24](https://github.com/medusajs/medusa/compare/medusa-plugin-restock-notification@0.0.22...medusa-plugin-restock-notification@0.0.24) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-restock-notification
## [0.0.23](https://github.com/medusajs/medusa/compare/medusa-plugin-restock-notification@0.0.22...medusa-plugin-restock-notification@0.0.23) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-restock-notification
## [0.0.22](https://github.com/medusajs/medusa/compare/medusa-plugin-restock-notification@0.0.21...medusa-plugin-restock-notification@0.0.22) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-restock-notification
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-restock-notification",
"version": "0.0.22",
"version": "0.0.24",
"main": "index.js",
"repository": {
"type": "git",
@@ -14,11 +14,11 @@
"@babel/core": "^7.7.5",
"@babel/plugin-transform-typescript": "^7.13.0",
"@babel/preset-typescript": "^7.12.7",
"babel-preset-medusa-package": "^1.1.17",
"babel-preset-medusa-package": "^1.1.18",
"cross-env": "^5.2.1",
"eslint": "^6.8.0",
"jest": "^25.5.2",
"medusa-test-utils": "^1.1.29",
"medusa-test-utils": "^1.1.31",
"pg": "^8.5.1",
"ulid": "^2.3.0"
},
@@ -36,7 +36,7 @@
"body-parser": "^1.19.0",
"cors": "^2.8.5",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26"
"medusa-core-utils": "^1.1.28"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.34](https://github.com/medusajs/medusa/compare/medusa-plugin-segment@1.1.33...medusa-plugin-segment@1.1.34) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-segment
## [1.1.33](https://github.com/medusajs/medusa/compare/medusa-plugin-segment@1.1.32...medusa-plugin-segment@1.1.33) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-segment
## [1.1.32](https://github.com/medusajs/medusa/compare/medusa-plugin-segment@1.1.31...medusa-plugin-segment@1.1.32) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-segment
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-segment",
"version": "1.1.32",
"version": "1.1.34",
"description": "Segment Analytics",
"main": "index.js",
"repository": {
@@ -39,8 +39,8 @@
"axios": "^0.19.2",
"body-parser": "^1.19.0",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29"
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.32](https://github.com/medusajs/medusa/compare/medusa-plugin-sendgrid@1.1.31...medusa-plugin-sendgrid@1.1.32) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-sendgrid
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-plugin-sendgrid@1.1.30...medusa-plugin-sendgrid@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-sendgrid
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-plugin-sendgrid@1.1.29...medusa-plugin-sendgrid@1.1.30) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-sendgrid
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-sendgrid",
"version": "1.1.30",
"version": "1.1.32",
"description": "SendGrid transactional emails",
"main": "index.js",
"repository": {
@@ -39,8 +39,8 @@
"@sendgrid/mail": "^7.1.1",
"body-parser": "^1.19.0",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29"
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "aa460f63591f9625f1fe98749b34172e528bed7f"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-plugin-slack-notification@1.1.30...medusa-plugin-slack-notification@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-slack-notification
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-plugin-slack-notification@1.1.29...medusa-plugin-slack-notification@1.1.30) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-slack-notification
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-plugin-slack-notification@1.1.28...medusa-plugin-slack-notification@1.1.29) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-slack-notification
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-economic",
"version": "1.1.29",
"version": "1.1.31",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-slack-notification",
"version": "1.1.29",
"version": "1.1.31",
"description": "Slack notifications",
"main": "index.js",
"repository": {
@@ -39,9 +39,9 @@
"axios": "^0.19.2",
"body-parser": "^1.19.0",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29",
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31",
"moment": "^2.27.0"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "aa460f63591f9625f1fe98749b34172e528bed7f"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-plugin-twilio-sms@1.1.30...medusa-plugin-twilio-sms@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-twilio-sms
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-plugin-twilio-sms@1.1.29...medusa-plugin-twilio-sms@1.1.30) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-twilio-sms
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-plugin-twilio-sms@1.1.28...medusa-plugin-twilio-sms@1.1.29) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-twilio-sms
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-twilio-sms",
"version": "1.1.29",
"version": "1.1.31",
"main": "index.js",
"repository": {
"type": "git",
@@ -35,9 +35,9 @@
"dependencies": {
"@babel/plugin-transform-classes": "^7.9.5",
"body-parser": "^1.19.0",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29",
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31",
"twilio": "^3.49.1"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "aa460f63591f9625f1fe98749b34172e528bed7f"
}
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-plugin-wishlist@1.1.30...medusa-plugin-wishlist@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-wishlist
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-plugin-wishlist@1.1.29...medusa-plugin-wishlist@1.1.30) (2021-11-19)
**Note:** Version bump only for package medusa-plugin-wishlist
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-plugin-wishlist@1.1.28...medusa-plugin-wishlist@1.1.29) (2021-10-18)
**Note:** Version bump only for package medusa-plugin-wishlist
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-plugin-wishlist",
"version": "1.1.29",
"version": "1.1.31",
"description": "Provides /customers/:id/wishlist to add items to a customr's wishlist",
"main": "index.js",
"repository": {
@@ -38,8 +38,8 @@
"body-parser": "^1.19.0",
"cors": "^2.8.5",
"express": "^4.17.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29"
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "aa460f63591f9625f1fe98749b34172e528bed7f"
}
+4
View File
@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [0.0.10](https://github.com/medusajs/medusa/compare/medusa-telemetry@0.0.9...medusa-telemetry@0.0.10) (2021-11-11)
**Note:** Version bump only for package medusa-telemetry
## [0.0.9](https://github.com/medusajs/medusa/compare/medusa-telemetry@0.0.8...medusa-telemetry@0.0.9) (2021-10-18)
**Note:** Version bump only for package medusa-telemetry
+2 -2
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-telemetry",
"version": "0.0.9",
"version": "0.0.10",
"description": "Telemetry for Medusa",
"main": "dist/index.js",
"repository": {
@@ -17,7 +17,7 @@
"@babel/cli": "^7.14.3",
"@babel/core": "^7.14.3",
"@babel/preset-typescript": "^7.15.0",
"babel-preset-medusa-package": "^1.1.17",
"babel-preset-medusa-package": "^1.1.18",
"cross-env": "^5.2.1",
"eslint": "^6.8.0",
"jest": "^25.5.2",
+8
View File
@@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.31](https://github.com/medusajs/medusa/compare/medusa-test-utils@1.1.30...medusa-test-utils@1.1.31) (2021-11-19)
**Note:** Version bump only for package medusa-test-utils
## [1.1.30](https://github.com/medusajs/medusa/compare/medusa-test-utils@1.1.29...medusa-test-utils@1.1.30) (2021-11-19)
**Note:** Version bump only for package medusa-test-utils
## [1.1.29](https://github.com/medusajs/medusa/compare/medusa-test-utils@1.1.28...medusa-test-utils@1.1.29) (2021-10-18)
**Note:** Version bump only for package medusa-test-utils
+3 -3
View File
@@ -1,6 +1,6 @@
{
"name": "medusa-test-utils",
"version": "1.1.29",
"version": "1.1.31",
"description": "Test utils for Medusa",
"main": "dist/index.js",
"repository": {
@@ -29,8 +29,8 @@
},
"dependencies": {
"@babel/plugin-transform-classes": "^7.9.5",
"medusa-core-utils": "^1.1.26",
"medusa-core-utils": "^1.1.28",
"randomatic": "^3.1.1"
},
"gitHead": "41a5425405aea5045a26def95c0dc00cf4a5a44d"
"gitHead": "a69b1e85be1da3b1b5bc4c5446471252623c8808"
}
+151
View File
@@ -3,6 +3,157 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.55](https://github.com/medusajs/medusa/compare/@medusajs/medusa@1.1.52...@medusajs/medusa@1.1.55) (2021-11-19)
### Bug Fixes
- /api/routes/store/auth pass linting ([#645](https://github.com/medusajs/medusa/issues/645)) ([40ad748](https://github.com/medusajs/medusa/commit/40ad748cc3c38bad97690b83c3b4b19c6d6365c3))
- /api/routes/store/customers pass linting ([#646](https://github.com/medusajs/medusa/issues/646)) ([7cc94dc](https://github.com/medusajs/medusa/commit/7cc94dc479ee26df2d5a031bfeb9eb3709d03776))
- add product count to storefront ([#719](https://github.com/medusajs/medusa/issues/719)) ([45b344f](https://github.com/medusajs/medusa/commit/45b344fbe1a570620c4e47cf959bdb605fffddef))
- adds options to default relations in storefront product endpoints ([#712](https://github.com/medusajs/medusa/issues/712)) ([e82737a](https://github.com/medusajs/medusa/commit/e82737a03545f69a833d8329f52daef39cfca46d))
- api/routes/store/products pass linting ([#644](https://github.com/medusajs/medusa/issues/644)) ([2966242](https://github.com/medusajs/medusa/commit/2966242bc812f9e75f0bb9cca5662b66836fc6d8))
- delete region causes cascade error ([#672](https://github.com/medusajs/medusa/issues/672)) ([0a65eca](https://github.com/medusajs/medusa/commit/0a65eca3de4f339178315e88b4220bd92ebe2736))
- lint in packages/medusa/src/services/swap.js pass linting ([#587](https://github.com/medusajs/medusa/issues/587)) ([3156a0d](https://github.com/medusajs/medusa/commit/3156a0de31749c1f32d5bdfe2cf8f1a8044bb42e))
- make /api/routes/admin/gift-cards,routes/store/gift-cards,/routes/store/orders pass linting ([#643](https://github.com/medusajs/medusa/issues/643)) ([60e9432](https://github.com/medusajs/medusa/commit/60e943260b804efe1dec3e139e47180322e5b52e))
- make /swaps pass eslint ([#665](https://github.com/medusajs/medusa/issues/665)) ([623d5f2](https://github.com/medusajs/medusa/commit/623d5f2b6d3881e2334fa48be80928ab9340a7ce))
- make api/routes/admin/apps pass eslint ([#641](https://github.com/medusajs/medusa/issues/641)) ([c9234c2](https://github.com/medusajs/medusa/commit/c9234c2343e19b32b335b93f4fa53e54398a5fe6))
- make api/routes/store/swaps pass eslint ([#678](https://github.com/medusajs/medusa/issues/678)) ([d9ee127](https://github.com/medusajs/medusa/commit/d9ee1272841ef047cceb6047fc34b8e42b5f580f))
- make discounts pass eslint ([3df2b42](https://github.com/medusajs/medusa/commit/3df2b4279f363e746f3514d8d8aa78b0e8fa3906))
- make it possible to update order shipping address ([#668](https://github.com/medusajs/medusa/issues/668)) ([e0fa06f](https://github.com/medusajs/medusa/commit/e0fa06fe964b8000ca539efa875ed6c322f6d57b))
- make packages/medusa/src/api/routes/admin/auth and 3 others pass eslint ([#666](https://github.com/medusajs/medusa/issues/666)) ([95f80f8](https://github.com/medusajs/medusa/commit/95f80f8a6635d1cba74d3c7ccbf794809af2d0bb))
- make packages/medusa/src/api/routes/admin/notes pass eslint ([#690](https://github.com/medusajs/medusa/issues/690)) ([f011662](https://github.com/medusajs/medusa/commit/f01166272db7dc2d1b783223a7ea5c9e662a028b))
- make packages/medusa/src/api/routes/admin/orders pass eslint ([#649](https://github.com/medusajs/medusa/issues/649)) ([dc88210](https://github.com/medusajs/medusa/commit/dc8821095c65e73569bdda1c4a24762f7eb746fe))
- make packages/medusa/src/api/routes/admin/return-reasons pass eslint ([#654](https://github.com/medusajs/medusa/issues/654)) ([a8fc89a](https://github.com/medusajs/medusa/commit/a8fc89af066836224e4f760115d13ba85f89a359))
- make packages/medusa/src/api/routes/admin/returns pass eslint ([#653](https://github.com/medusajs/medusa/issues/653)) ([2f7deea](https://github.com/medusajs/medusa/commit/2f7deea1d0309b5a78d66b0dd0d3c2204717c02b))
- make packages/medusa/src/api/routes/admin/shipping-options pass eslint ([#674](https://github.com/medusajs/medusa/issues/674)) ([bd86d3c](https://github.com/medusajs/medusa/commit/bd86d3c995b27bae5c8d97a21eb900b6dd112068))
- make packages/medusa/src/api/routes/admin/shipping-profiles pass eslint ([#642](https://github.com/medusajs/medusa/issues/642)) ([ce4d361](https://github.com/medusajs/medusa/commit/ce4d3616d733b5472ebfc00b49ab17c5aa53daef))
- make packages/medusa/src/api/routes/admin/store pass eslint ([#686](https://github.com/medusajs/medusa/issues/686)) ([7a230ec](https://github.com/medusajs/medusa/commit/7a230ec7e96cae6628f9b68a41dc6da89559dfe9))
- make packages/medusa/src/api/routes/admin/upload pass eslint ([#627](https://github.com/medusajs/medusa/issues/627)) ([5fbce42](https://github.com/medusajs/medusa/commit/5fbce429489cba79340ae738c54a533bdc627a28))
- make packages/medusa/src/api/routes/admin/users pass eslint ([a6a612c](https://github.com/medusajs/medusa/commit/a6a612c941924722c51e389359393436655cfc65))
- make packages/medusa/src/api/routes/store/carts pass eslint ([#652](https://github.com/medusajs/medusa/issues/652)) ([1ba63cc](https://github.com/medusajs/medusa/commit/1ba63cce08d03edd47b3e651d60a34cf58d5c1e3))
- make packages/medusa/src/api/routes/store/shipping-options pass linting ([#648](https://github.com/medusajs/medusa/issues/648)) ([5cb1b56](https://github.com/medusajs/medusa/commit/5cb1b5687ee80448dfecd0c8ba683ccdfc6900fc))
- make packages/medusa/src/services/cart.js pass eslint ([#700](https://github.com/medusajs/medusa/issues/700)) ([0caba0d](https://github.com/medusajs/medusa/commit/0caba0d49113210af4f6d507e273e8b451a5eaaf))
- Make packages/medusa/src/services/claim-item.js pass linting ([#626](https://github.com/medusajs/medusa/issues/626)) ([0d30369](https://github.com/medusajs/medusa/commit/0d3036978a8203f9fb6e64a2bc82a19ef697db05))
- Make packages/medusa/src/services/oauth.js pass linting ([#604](https://github.com/medusajs/medusa/issues/604)) ([14608b0](https://github.com/medusajs/medusa/commit/14608b0f682e858ee38e4b996693962a25116749))
- make packages/medusa/src/services/payment-provider.js pass eslint ([#549](https://github.com/medusajs/medusa/issues/549)) ([caf4357](https://github.com/medusajs/medusa/commit/caf4357c4d1a2199ab1399dfabd18876dd0642c7)), closes [#692](https://github.com/medusajs/medusa/issues/692)
- Make packages/medusa/src/services/product-variant.js pass linting ([#693](https://github.com/medusajs/medusa/issues/693)) ([a351398](https://github.com/medusajs/medusa/commit/a3513983790eaf78285d32f1797d1d11eb446e5e))
- make packages/medusa/src/services/shipping-profile.js pass eslint ([#582](https://github.com/medusajs/medusa/issues/582)) ([2c415ea](https://github.com/medusajs/medusa/commit/2c415ea520ed700a0a474111b83021a699fbc851))
- make packages/medusa/src/services/totals.js pass eslint ([23e83af](https://github.com/medusajs/medusa/commit/23e83aff1cd858401fba42668f641270128068e1))
- make variants pass eslint ([a1e446c](https://github.com/medusajs/medusa/commit/a1e446c1214a79a799da46b3d1bdd62c64b99ebf))
- make variants pass eslint ([#647](https://github.com/medusajs/medusa/issues/647)) ([f4307c7](https://github.com/medusajs/medusa/commit/f4307c702a6c1420d1e344adc8b5ed880d9f1f8d))
- **medusa:** add total count for list queries in product ([#710](https://github.com/medusajs/medusa/issues/710)) ([109d400](https://github.com/medusajs/medusa/commit/109d4007204964f0a89759f48a6e2d5afc0b1dd9))
- Prepare routes for linting ([#603](https://github.com/medusajs/medusa/issues/603)) ([3e68069](https://github.com/medusajs/medusa/commit/3e68069a8959a2bf75f8639389cdd35b6a8058e7))
- release ([5fa4848](https://github.com/medusajs/medusa/commit/5fa4848b17a9dd432c2361e5d9485950494a2bc6))
- updates documentation and fixes script blockers ([#765](https://github.com/medusajs/medusa/issues/765)) ([3ea6aea](https://github.com/medusajs/medusa/commit/3ea6aea5beb2a50d1a3345fa3833eadb32d0a346))
### Features
- admin api - allow customers to be created and updated with metadata ([#824](https://github.com/medusajs/medusa/issues/824)) ([2d9879e](https://github.com/medusajs/medusa/commit/2d9879ea090898c08ad86a0ebc44d5b8965b5166))
- Algolia plugin for medusa ([#718](https://github.com/medusajs/medusa/issues/718)) ([8ce9b20](https://github.com/medusajs/medusa/commit/8ce9b20222e1f4db75f730898549f0ed09eb1574))
- Allow retrieval of soft-deleted products ([#723](https://github.com/medusajs/medusa/issues/723)) ([1e50aee](https://github.com/medusajs/medusa/commit/1e50aee4feb55092560dd4a9c51a0671363e8576))
- **medusa:** adds collection endpoints to storefront ([#711](https://github.com/medusajs/medusa/issues/711)) ([5812756](https://github.com/medusajs/medusa/commit/58127564d7110c674fb14fdd97fbc080afba156d))
- Typescript for API layer ([#817](https://github.com/medusajs/medusa/issues/817)) ([373532e](https://github.com/medusajs/medusa/commit/373532ecbc8196f47e71af95a8cf82a14a4b1f9e))
## [1.1.54](https://github.com/medusajs/medusa/compare/@medusajs/medusa@1.1.52...@medusajs/medusa@1.1.54) (2021-11-19)
### Bug Fixes
- /api/routes/store/auth pass linting ([#645](https://github.com/medusajs/medusa/issues/645)) ([40ad748](https://github.com/medusajs/medusa/commit/40ad748cc3c38bad97690b83c3b4b19c6d6365c3))
- /api/routes/store/customers pass linting ([#646](https://github.com/medusajs/medusa/issues/646)) ([7cc94dc](https://github.com/medusajs/medusa/commit/7cc94dc479ee26df2d5a031bfeb9eb3709d03776))
- add product count to storefront ([#719](https://github.com/medusajs/medusa/issues/719)) ([45b344f](https://github.com/medusajs/medusa/commit/45b344fbe1a570620c4e47cf959bdb605fffddef))
- adds options to default relations in storefront product endpoints ([#712](https://github.com/medusajs/medusa/issues/712)) ([e82737a](https://github.com/medusajs/medusa/commit/e82737a03545f69a833d8329f52daef39cfca46d))
- api/routes/store/products pass linting ([#644](https://github.com/medusajs/medusa/issues/644)) ([2966242](https://github.com/medusajs/medusa/commit/2966242bc812f9e75f0bb9cca5662b66836fc6d8))
- delete region causes cascade error ([#672](https://github.com/medusajs/medusa/issues/672)) ([0a65eca](https://github.com/medusajs/medusa/commit/0a65eca3de4f339178315e88b4220bd92ebe2736))
- lint in packages/medusa/src/services/swap.js pass linting ([#587](https://github.com/medusajs/medusa/issues/587)) ([3156a0d](https://github.com/medusajs/medusa/commit/3156a0de31749c1f32d5bdfe2cf8f1a8044bb42e))
- make /api/routes/admin/gift-cards,routes/store/gift-cards,/routes/store/orders pass linting ([#643](https://github.com/medusajs/medusa/issues/643)) ([60e9432](https://github.com/medusajs/medusa/commit/60e943260b804efe1dec3e139e47180322e5b52e))
- make /swaps pass eslint ([#665](https://github.com/medusajs/medusa/issues/665)) ([623d5f2](https://github.com/medusajs/medusa/commit/623d5f2b6d3881e2334fa48be80928ab9340a7ce))
- make api/routes/admin/apps pass eslint ([#641](https://github.com/medusajs/medusa/issues/641)) ([c9234c2](https://github.com/medusajs/medusa/commit/c9234c2343e19b32b335b93f4fa53e54398a5fe6))
- make api/routes/store/swaps pass eslint ([#678](https://github.com/medusajs/medusa/issues/678)) ([d9ee127](https://github.com/medusajs/medusa/commit/d9ee1272841ef047cceb6047fc34b8e42b5f580f))
- make discounts pass eslint ([3df2b42](https://github.com/medusajs/medusa/commit/3df2b4279f363e746f3514d8d8aa78b0e8fa3906))
- make it possible to update order shipping address ([#668](https://github.com/medusajs/medusa/issues/668)) ([e0fa06f](https://github.com/medusajs/medusa/commit/e0fa06fe964b8000ca539efa875ed6c322f6d57b))
- make packages/medusa/src/api/routes/admin/auth and 3 others pass eslint ([#666](https://github.com/medusajs/medusa/issues/666)) ([95f80f8](https://github.com/medusajs/medusa/commit/95f80f8a6635d1cba74d3c7ccbf794809af2d0bb))
- make packages/medusa/src/api/routes/admin/notes pass eslint ([#690](https://github.com/medusajs/medusa/issues/690)) ([f011662](https://github.com/medusajs/medusa/commit/f01166272db7dc2d1b783223a7ea5c9e662a028b))
- make packages/medusa/src/api/routes/admin/orders pass eslint ([#649](https://github.com/medusajs/medusa/issues/649)) ([dc88210](https://github.com/medusajs/medusa/commit/dc8821095c65e73569bdda1c4a24762f7eb746fe))
- make packages/medusa/src/api/routes/admin/return-reasons pass eslint ([#654](https://github.com/medusajs/medusa/issues/654)) ([a8fc89a](https://github.com/medusajs/medusa/commit/a8fc89af066836224e4f760115d13ba85f89a359))
- make packages/medusa/src/api/routes/admin/returns pass eslint ([#653](https://github.com/medusajs/medusa/issues/653)) ([2f7deea](https://github.com/medusajs/medusa/commit/2f7deea1d0309b5a78d66b0dd0d3c2204717c02b))
- make packages/medusa/src/api/routes/admin/shipping-options pass eslint ([#674](https://github.com/medusajs/medusa/issues/674)) ([bd86d3c](https://github.com/medusajs/medusa/commit/bd86d3c995b27bae5c8d97a21eb900b6dd112068))
- make packages/medusa/src/api/routes/admin/shipping-profiles pass eslint ([#642](https://github.com/medusajs/medusa/issues/642)) ([ce4d361](https://github.com/medusajs/medusa/commit/ce4d3616d733b5472ebfc00b49ab17c5aa53daef))
- make packages/medusa/src/api/routes/admin/store pass eslint ([#686](https://github.com/medusajs/medusa/issues/686)) ([7a230ec](https://github.com/medusajs/medusa/commit/7a230ec7e96cae6628f9b68a41dc6da89559dfe9))
- make packages/medusa/src/api/routes/admin/upload pass eslint ([#627](https://github.com/medusajs/medusa/issues/627)) ([5fbce42](https://github.com/medusajs/medusa/commit/5fbce429489cba79340ae738c54a533bdc627a28))
- make packages/medusa/src/api/routes/admin/users pass eslint ([a6a612c](https://github.com/medusajs/medusa/commit/a6a612c941924722c51e389359393436655cfc65))
- make packages/medusa/src/api/routes/store/carts pass eslint ([#652](https://github.com/medusajs/medusa/issues/652)) ([1ba63cc](https://github.com/medusajs/medusa/commit/1ba63cce08d03edd47b3e651d60a34cf58d5c1e3))
- make packages/medusa/src/api/routes/store/shipping-options pass linting ([#648](https://github.com/medusajs/medusa/issues/648)) ([5cb1b56](https://github.com/medusajs/medusa/commit/5cb1b5687ee80448dfecd0c8ba683ccdfc6900fc))
- make packages/medusa/src/services/cart.js pass eslint ([#700](https://github.com/medusajs/medusa/issues/700)) ([0caba0d](https://github.com/medusajs/medusa/commit/0caba0d49113210af4f6d507e273e8b451a5eaaf))
- Make packages/medusa/src/services/claim-item.js pass linting ([#626](https://github.com/medusajs/medusa/issues/626)) ([0d30369](https://github.com/medusajs/medusa/commit/0d3036978a8203f9fb6e64a2bc82a19ef697db05))
- Make packages/medusa/src/services/oauth.js pass linting ([#604](https://github.com/medusajs/medusa/issues/604)) ([14608b0](https://github.com/medusajs/medusa/commit/14608b0f682e858ee38e4b996693962a25116749))
- make packages/medusa/src/services/payment-provider.js pass eslint ([#549](https://github.com/medusajs/medusa/issues/549)) ([caf4357](https://github.com/medusajs/medusa/commit/caf4357c4d1a2199ab1399dfabd18876dd0642c7)), closes [#692](https://github.com/medusajs/medusa/issues/692)
- Make packages/medusa/src/services/product-variant.js pass linting ([#693](https://github.com/medusajs/medusa/issues/693)) ([a351398](https://github.com/medusajs/medusa/commit/a3513983790eaf78285d32f1797d1d11eb446e5e))
- make packages/medusa/src/services/shipping-profile.js pass eslint ([#582](https://github.com/medusajs/medusa/issues/582)) ([2c415ea](https://github.com/medusajs/medusa/commit/2c415ea520ed700a0a474111b83021a699fbc851))
- make packages/medusa/src/services/totals.js pass eslint ([23e83af](https://github.com/medusajs/medusa/commit/23e83aff1cd858401fba42668f641270128068e1))
- make variants pass eslint ([a1e446c](https://github.com/medusajs/medusa/commit/a1e446c1214a79a799da46b3d1bdd62c64b99ebf))
- make variants pass eslint ([#647](https://github.com/medusajs/medusa/issues/647)) ([f4307c7](https://github.com/medusajs/medusa/commit/f4307c702a6c1420d1e344adc8b5ed880d9f1f8d))
- **medusa:** add total count for list queries in product ([#710](https://github.com/medusajs/medusa/issues/710)) ([109d400](https://github.com/medusajs/medusa/commit/109d4007204964f0a89759f48a6e2d5afc0b1dd9))
- Prepare routes for linting ([#603](https://github.com/medusajs/medusa/issues/603)) ([3e68069](https://github.com/medusajs/medusa/commit/3e68069a8959a2bf75f8639389cdd35b6a8058e7))
- updates documentation and fixes script blockers ([#765](https://github.com/medusajs/medusa/issues/765)) ([3ea6aea](https://github.com/medusajs/medusa/commit/3ea6aea5beb2a50d1a3345fa3833eadb32d0a346))
### Features
- admin api - allow customers to be created and updated with metadata ([#824](https://github.com/medusajs/medusa/issues/824)) ([2d9879e](https://github.com/medusajs/medusa/commit/2d9879ea090898c08ad86a0ebc44d5b8965b5166))
- Algolia plugin for medusa ([#718](https://github.com/medusajs/medusa/issues/718)) ([8ce9b20](https://github.com/medusajs/medusa/commit/8ce9b20222e1f4db75f730898549f0ed09eb1574))
- Allow retrieval of soft-deleted products ([#723](https://github.com/medusajs/medusa/issues/723)) ([1e50aee](https://github.com/medusajs/medusa/commit/1e50aee4feb55092560dd4a9c51a0671363e8576))
- **medusa:** adds collection endpoints to storefront ([#711](https://github.com/medusajs/medusa/issues/711)) ([5812756](https://github.com/medusajs/medusa/commit/58127564d7110c674fb14fdd97fbc080afba156d))
- Typescript for API layer ([#817](https://github.com/medusajs/medusa/issues/817)) ([373532e](https://github.com/medusajs/medusa/commit/373532ecbc8196f47e71af95a8cf82a14a4b1f9e))
## [1.1.53](https://github.com/medusajs/medusa/compare/@medusajs/medusa@1.1.52...@medusajs/medusa@1.1.53) (2021-11-19)
### Bug Fixes
- /api/routes/store/auth pass linting ([#645](https://github.com/medusajs/medusa/issues/645)) ([40ad748](https://github.com/medusajs/medusa/commit/40ad748cc3c38bad97690b83c3b4b19c6d6365c3))
- /api/routes/store/customers pass linting ([#646](https://github.com/medusajs/medusa/issues/646)) ([7cc94dc](https://github.com/medusajs/medusa/commit/7cc94dc479ee26df2d5a031bfeb9eb3709d03776))
- add product count to storefront ([#719](https://github.com/medusajs/medusa/issues/719)) ([45b344f](https://github.com/medusajs/medusa/commit/45b344fbe1a570620c4e47cf959bdb605fffddef))
- adds options to default relations in storefront product endpoints ([#712](https://github.com/medusajs/medusa/issues/712)) ([e82737a](https://github.com/medusajs/medusa/commit/e82737a03545f69a833d8329f52daef39cfca46d))
- api/routes/store/products pass linting ([#644](https://github.com/medusajs/medusa/issues/644)) ([2966242](https://github.com/medusajs/medusa/commit/2966242bc812f9e75f0bb9cca5662b66836fc6d8))
- delete region causes cascade error ([#672](https://github.com/medusajs/medusa/issues/672)) ([0a65eca](https://github.com/medusajs/medusa/commit/0a65eca3de4f339178315e88b4220bd92ebe2736))
- lint in packages/medusa/src/services/swap.js pass linting ([#587](https://github.com/medusajs/medusa/issues/587)) ([3156a0d](https://github.com/medusajs/medusa/commit/3156a0de31749c1f32d5bdfe2cf8f1a8044bb42e))
- make /api/routes/admin/gift-cards,routes/store/gift-cards,/routes/store/orders pass linting ([#643](https://github.com/medusajs/medusa/issues/643)) ([60e9432](https://github.com/medusajs/medusa/commit/60e943260b804efe1dec3e139e47180322e5b52e))
- make /swaps pass eslint ([#665](https://github.com/medusajs/medusa/issues/665)) ([623d5f2](https://github.com/medusajs/medusa/commit/623d5f2b6d3881e2334fa48be80928ab9340a7ce))
- make api/routes/admin/apps pass eslint ([#641](https://github.com/medusajs/medusa/issues/641)) ([c9234c2](https://github.com/medusajs/medusa/commit/c9234c2343e19b32b335b93f4fa53e54398a5fe6))
- make api/routes/store/swaps pass eslint ([#678](https://github.com/medusajs/medusa/issues/678)) ([d9ee127](https://github.com/medusajs/medusa/commit/d9ee1272841ef047cceb6047fc34b8e42b5f580f))
- make discounts pass eslint ([3df2b42](https://github.com/medusajs/medusa/commit/3df2b4279f363e746f3514d8d8aa78b0e8fa3906))
- make it possible to update order shipping address ([#668](https://github.com/medusajs/medusa/issues/668)) ([e0fa06f](https://github.com/medusajs/medusa/commit/e0fa06fe964b8000ca539efa875ed6c322f6d57b))
- make packages/medusa/src/api/routes/admin/auth and 3 others pass eslint ([#666](https://github.com/medusajs/medusa/issues/666)) ([95f80f8](https://github.com/medusajs/medusa/commit/95f80f8a6635d1cba74d3c7ccbf794809af2d0bb))
- make packages/medusa/src/api/routes/admin/notes pass eslint ([#690](https://github.com/medusajs/medusa/issues/690)) ([f011662](https://github.com/medusajs/medusa/commit/f01166272db7dc2d1b783223a7ea5c9e662a028b))
- make packages/medusa/src/api/routes/admin/orders pass eslint ([#649](https://github.com/medusajs/medusa/issues/649)) ([dc88210](https://github.com/medusajs/medusa/commit/dc8821095c65e73569bdda1c4a24762f7eb746fe))
- make packages/medusa/src/api/routes/admin/return-reasons pass eslint ([#654](https://github.com/medusajs/medusa/issues/654)) ([a8fc89a](https://github.com/medusajs/medusa/commit/a8fc89af066836224e4f760115d13ba85f89a359))
- make packages/medusa/src/api/routes/admin/returns pass eslint ([#653](https://github.com/medusajs/medusa/issues/653)) ([2f7deea](https://github.com/medusajs/medusa/commit/2f7deea1d0309b5a78d66b0dd0d3c2204717c02b))
- make packages/medusa/src/api/routes/admin/shipping-options pass eslint ([#674](https://github.com/medusajs/medusa/issues/674)) ([bd86d3c](https://github.com/medusajs/medusa/commit/bd86d3c995b27bae5c8d97a21eb900b6dd112068))
- make packages/medusa/src/api/routes/admin/shipping-profiles pass eslint ([#642](https://github.com/medusajs/medusa/issues/642)) ([ce4d361](https://github.com/medusajs/medusa/commit/ce4d3616d733b5472ebfc00b49ab17c5aa53daef))
- make packages/medusa/src/api/routes/admin/store pass eslint ([#686](https://github.com/medusajs/medusa/issues/686)) ([7a230ec](https://github.com/medusajs/medusa/commit/7a230ec7e96cae6628f9b68a41dc6da89559dfe9))
- make packages/medusa/src/api/routes/admin/upload pass eslint ([#627](https://github.com/medusajs/medusa/issues/627)) ([5fbce42](https://github.com/medusajs/medusa/commit/5fbce429489cba79340ae738c54a533bdc627a28))
- make packages/medusa/src/api/routes/admin/users pass eslint ([a6a612c](https://github.com/medusajs/medusa/commit/a6a612c941924722c51e389359393436655cfc65))
- make packages/medusa/src/api/routes/store/carts pass eslint ([#652](https://github.com/medusajs/medusa/issues/652)) ([1ba63cc](https://github.com/medusajs/medusa/commit/1ba63cce08d03edd47b3e651d60a34cf58d5c1e3))
- make packages/medusa/src/api/routes/store/shipping-options pass linting ([#648](https://github.com/medusajs/medusa/issues/648)) ([5cb1b56](https://github.com/medusajs/medusa/commit/5cb1b5687ee80448dfecd0c8ba683ccdfc6900fc))
- make packages/medusa/src/services/cart.js pass eslint ([#700](https://github.com/medusajs/medusa/issues/700)) ([0caba0d](https://github.com/medusajs/medusa/commit/0caba0d49113210af4f6d507e273e8b451a5eaaf))
- Make packages/medusa/src/services/claim-item.js pass linting ([#626](https://github.com/medusajs/medusa/issues/626)) ([0d30369](https://github.com/medusajs/medusa/commit/0d3036978a8203f9fb6e64a2bc82a19ef697db05))
- Make packages/medusa/src/services/oauth.js pass linting ([#604](https://github.com/medusajs/medusa/issues/604)) ([14608b0](https://github.com/medusajs/medusa/commit/14608b0f682e858ee38e4b996693962a25116749))
- make packages/medusa/src/services/payment-provider.js pass eslint ([#549](https://github.com/medusajs/medusa/issues/549)) ([caf4357](https://github.com/medusajs/medusa/commit/caf4357c4d1a2199ab1399dfabd18876dd0642c7)), closes [#692](https://github.com/medusajs/medusa/issues/692)
- Make packages/medusa/src/services/product-variant.js pass linting ([#693](https://github.com/medusajs/medusa/issues/693)) ([a351398](https://github.com/medusajs/medusa/commit/a3513983790eaf78285d32f1797d1d11eb446e5e))
- make packages/medusa/src/services/shipping-profile.js pass eslint ([#582](https://github.com/medusajs/medusa/issues/582)) ([2c415ea](https://github.com/medusajs/medusa/commit/2c415ea520ed700a0a474111b83021a699fbc851))
- make packages/medusa/src/services/totals.js pass eslint ([23e83af](https://github.com/medusajs/medusa/commit/23e83aff1cd858401fba42668f641270128068e1))
- make variants pass eslint ([a1e446c](https://github.com/medusajs/medusa/commit/a1e446c1214a79a799da46b3d1bdd62c64b99ebf))
- make variants pass eslint ([#647](https://github.com/medusajs/medusa/issues/647)) ([f4307c7](https://github.com/medusajs/medusa/commit/f4307c702a6c1420d1e344adc8b5ed880d9f1f8d))
- **medusa:** add total count for list queries in product ([#710](https://github.com/medusajs/medusa/issues/710)) ([109d400](https://github.com/medusajs/medusa/commit/109d4007204964f0a89759f48a6e2d5afc0b1dd9))
- Prepare routes for linting ([#603](https://github.com/medusajs/medusa/issues/603)) ([3e68069](https://github.com/medusajs/medusa/commit/3e68069a8959a2bf75f8639389cdd35b6a8058e7))
- updates documentation and fixes script blockers ([#765](https://github.com/medusajs/medusa/issues/765)) ([3ea6aea](https://github.com/medusajs/medusa/commit/3ea6aea5beb2a50d1a3345fa3833eadb32d0a346))
### Features
- admin api - allow customers to be created and updated with metadata ([#824](https://github.com/medusajs/medusa/issues/824)) ([2d9879e](https://github.com/medusajs/medusa/commit/2d9879ea090898c08ad86a0ebc44d5b8965b5166))
- Algolia plugin for medusa ([#718](https://github.com/medusajs/medusa/issues/718)) ([8ce9b20](https://github.com/medusajs/medusa/commit/8ce9b20222e1f4db75f730898549f0ed09eb1574))
- Allow retrieval of soft-deleted products ([#723](https://github.com/medusajs/medusa/issues/723)) ([1e50aee](https://github.com/medusajs/medusa/commit/1e50aee4feb55092560dd4a9c51a0671363e8576))
- **medusa:** adds collection endpoints to storefront ([#711](https://github.com/medusajs/medusa/issues/711)) ([5812756](https://github.com/medusajs/medusa/commit/58127564d7110c674fb14fdd97fbc080afba156d))
- Typescript for API layer ([#817](https://github.com/medusajs/medusa/issues/817)) ([373532e](https://github.com/medusajs/medusa/commit/373532ecbc8196f47e71af95a8cf82a14a4b1f9e))
## [1.1.52](https://github.com/medusajs/medusa/compare/@medusajs/medusa@1.1.51...@medusajs/medusa@1.1.52) (2021-11-09)
**Note:** Version bump only for package @medusajs/medusa
Regular → Executable
View File
+6 -6
View File
@@ -1,6 +1,6 @@
{
"name": "@medusajs/medusa",
"version": "1.1.52",
"version": "1.1.55",
"description": "E-commerce for JAMstack",
"main": "dist/index.js",
"bin": {
@@ -26,7 +26,7 @@
"cross-env": "^5.2.1",
"eslint": "^7.32.0",
"jest": "^25.5.2",
"medusa-interfaces": "^1.1.27",
"medusa-interfaces": "^1.1.29",
"nodemon": "^2.0.1",
"prettier": "^1.19.1",
"sqlite3": "^5.0.2",
@@ -48,7 +48,7 @@
},
"dependencies": {
"@hapi/joi": "^16.1.8",
"@medusajs/medusa-cli": "^1.1.22",
"@medusajs/medusa-cli": "^1.1.23",
"@types/lodash": "^4.14.168",
"awilix": "^4.2.3",
"body-parser": "^1.19.0",
@@ -72,8 +72,8 @@
"joi": "^17.3.0",
"joi-objectid": "^3.0.1",
"jsonwebtoken": "^8.5.1",
"medusa-core-utils": "^1.1.26",
"medusa-test-utils": "^1.1.29",
"medusa-core-utils": "^1.1.28",
"medusa-test-utils": "^1.1.31",
"morgan": "^1.9.1",
"multer": "^1.4.2",
"passport": "^0.4.0",
@@ -93,4 +93,4 @@
"winston": "^3.2.1"
},
"gitHead": "5afd0dfbabaebfb6b09f0e2f055386ac76059372"
}
}
@@ -0,0 +1,355 @@
import { MedusaError, Validator } from "medusa-core-utils"
import { defaultRelations, defaultFields } from "./"
/**
* @oas [post] /order/{id}/claims
* operationId: "PostOrdersOrderClaims"
* summary: "Create a Claim"
* description: "Creates a Claim."
* parameters:
* - (path) id=* {string} The id of the Order.
* requestBody:
* content:
* application/json:
* schema:
* properties:
* type:
* description: "The type of the Claim. This will determine how the Claim is treated: `replace` Claims will result in a Fulfillment with new items being created, while a `refund` Claim will refund the amount paid for the claimed items."
* type: string
* enum:
* - replace
* - refund
* claim_items:
* description: The Claim Items that the Claim will consist of.
* type: array
* items:
* properties:
* item_id:
* description: The id of the Line Item that will be claimed.
* type: string
* quantity:
* description: The number of items that will be returned
* type: integer
* note:
* description: Short text describing the Claim Item in further detail.
* type: string
* reason:
* description: The reason for the Claim
* type: string
* enum:
* - missing_item
* - wrong_item
* - production_failure
* - other
* tags:
* description: A list o tags to add to the Claim Item
* type: array
* items:
* type: string
* images:
* description: A list of image URL's that will be associated with the Claim
* items:
* type: string
* return_shipping:
* description: Optional details for the Return Shipping Method, if the items are to be sent back.
* type: object
* properties:
* option_id:
* type: string
* description: The id of the Shipping Option to create the Shipping Method from.
* price:
* type: integer
* description: The price to charge for the Shipping Method.
* additional_items:
* description: The new items to send to the Customer when the Claim type is Replace.
* type: array
* items:
* properties:
* variant_id:
* description: The id of the Product Variant to ship.
* type: string
* quantity:
* description: The quantity of the Product Variant to ship.
* type: integer
* shipping_methods:
* description: The Shipping Methods to send the additional Line Items with.
* type: array
* items:
* properties:
* id:
* description: The id of an existing Shipping Method
* type: string
* option_id:
* description: The id of the Shipping Option to create a Shipping Method from
* type: string
* price:
* description: The price to charge for the Shipping Method
* type: integer
* shipping_address:
* type: object
* description: "An optional shipping address to send the claim to. Defaults to the parent order's shipping address"
* refund_amount:
* description: The amount to refund the Customer when the Claim type is `refund`.
* type: integer
* no_notification:
* description: If set to true no notification will be send related to this Claim.
* type: boolean
* metadata:
* description: An optional set of key-value pairs to hold additional information.
* type: object
* tags:
* - Order
* responses:
* 200:
* description: OK
* content:
* application/json:
* schema:
* properties:
* order:
* $ref: "#/components/schemas/order"
*/
export default async (req, res) => {
const { id } = req.params
const schema = Validator.object().keys({
type: Validator.string()
.valid("replace", "refund")
.required(),
claim_items: Validator.array()
.items({
item_id: Validator.string().required(),
quantity: Validator.number().required(),
note: Validator.string().optional(),
reason: Validator.string().valid(
"missing_item",
"wrong_item",
"production_failure",
"other"
),
tags: Validator.array().items(Validator.string()),
images: Validator.array().items(Validator.string()),
})
.required(),
return_shipping: Validator.object()
.keys({
option_id: Validator.string().optional(),
price: Validator.number()
.integer()
.optional(),
})
.optional(),
additional_items: Validator.array()
.items({
variant_id: Validator.string().required(),
quantity: Validator.number().required(),
})
.optional(),
shipping_methods: Validator.array()
.items({
id: Validator.string().optional(),
option_id: Validator.string().optional(),
price: Validator.number()
.integer()
.optional(),
})
.optional(),
refund_amount: Validator.number()
.integer()
.optional(),
shipping_address: Validator.object().optional(),
no_notification: Validator.boolean().optional(),
metadata: Validator.object().optional(),
})
const { value, error } = schema.validate(req.body)
if (error) {
throw new MedusaError(MedusaError.Types.INVALID_DATA, error.details)
}
const idempotencyKeyService = req.scope.resolve("idempotencyKeyService")
const headerKey = req.get("Idempotency-Key") || ""
let idempotencyKey
try {
idempotencyKey = await idempotencyKeyService.initializeRequest(
headerKey,
req.method,
req.params,
req.path
)
} catch (error) {
res.status(409).send("Failed to create idempotency key")
return
}
res.setHeader("Access-Control-Expose-Headers", "Idempotency-Key")
res.setHeader("Idempotency-Key", idempotencyKey.idempotency_key)
try {
const orderService = req.scope.resolve("orderService")
const claimService = req.scope.resolve("claimService")
const returnService = req.scope.resolve("returnService")
let inProgress = true
let err = false
while (inProgress) {
switch (idempotencyKey.recovery_point) {
case "started": {
const { key, error } = await idempotencyKeyService.workStage(
idempotencyKey.idempotency_key,
async (manager) => {
const order = await orderService
.withTransaction(manager)
.retrieve(id, {
relations: ["items", "discounts", "discounts.rule"],
})
await claimService.withTransaction(manager).create({
idempotency_key: idempotencyKey.idempotency_key,
order,
type: value.type,
shipping_address: value.shipping_address,
claim_items: value.claim_items,
return_shipping: value.return_shipping,
additional_items: value.additional_items,
shipping_methods: value.shipping_methods,
no_notification: value.no_notification,
metadata: value.metadata,
})
return {
recovery_point: "claim_created",
}
}
)
if (error) {
inProgress = false
err = error
} else {
idempotencyKey = key
}
break
}
case "claim_created": {
const { key, error } = await idempotencyKeyService.workStage(
idempotencyKey.idempotency_key,
async (manager) => {
let claim = await claimService.withTransaction(manager).list({
idempotency_key: idempotencyKey.idempotency_key,
})
if (!claim.length) {
throw new MedusaError(
MedusaError.Types.INVALID_DATA,
`Claim not found`
)
}
claim = claim[0]
if (claim.type === "refund") {
await claimService
.withTransaction(manager)
.processRefund(claim.id)
}
return {
recovery_point: "refund_handled",
}
}
)
if (error) {
inProgress = false
err = error
} else {
idempotencyKey = key
}
break
}
case "refund_handled": {
const { key, error } = await idempotencyKeyService.workStage(
idempotencyKey.idempotency_key,
async (manager) => {
let order = await orderService
.withTransaction(manager)
.retrieve(id, {
relations: ["items", "discounts"],
})
let claim = await claimService.withTransaction(manager).list(
{
idempotency_key: idempotencyKey.idempotency_key,
},
{
relations: ["return_order"],
}
)
if (!claim.length) {
throw new MedusaError(
MedusaError.Types.INVALID_DATA,
`Claim not found`
)
}
claim = claim[0]
if (claim.return_order) {
await returnService
.withTransaction(manager)
.fulfill(claim.return_order.id)
}
order = await orderService.withTransaction(manager).retrieve(id, {
select: defaultFields,
relations: defaultRelations,
})
return {
response_code: 200,
response_body: { order },
}
}
)
if (error) {
inProgress = false
err = error
} else {
idempotencyKey = key
}
break
}
case "finished": {
inProgress = false
break
}
default:
idempotencyKey = await idempotencyKeyService.update(
idempotencyKey.idempotency_key,
{
recovery_point: "finished",
response_code: 500,
response_body: { message: "Unknown recovery point" },
}
)
break
}
}
if (err) {
throw err
}
res.status(idempotencyKey.response_code).json(idempotencyKey.response_body)
} catch (error) {
throw error
}
}