From 20fd88ba605194aaabc225a0a646c146bf98b43d Mon Sep 17 00:00:00 2001 From: Nicolas Baccelli Date: Tue, 7 Jan 2025 10:33:11 +0100 Subject: [PATCH 1/2] Document `DISABLE_MEDIA_DOWNLOAD` env variable --- docs/setup/configuration.mdx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/setup/configuration.mdx b/docs/setup/configuration.mdx index 6c89c5f28..dc2c32257 100644 --- a/docs/setup/configuration.mdx +++ b/docs/setup/configuration.mdx @@ -262,6 +262,10 @@ Controls [Django's secret key](https://docs.djangoproject.com/en/3.0/ref/setting Controls the production assets mount path. Defaults to `/static/`. +### `DISABLE_MEDIA_DOWNLOAD` + +Disable medias download on media creation. Defaults to `False` (ie not disabled). + ## Currency exchange Saleor can automatically convert amounts between currencies. To use this feature, you will need an [Open Exchange Rates account](https://openexchangerates.org/). From ef5f172aa9a429aad674d3b59cc46912f88877dc Mon Sep 17 00:00:00 2001 From: Nicolas Baccelli Date: Fri, 10 Jan 2025 16:51:54 +0100 Subject: [PATCH 2/2] Add `asyncDownload` field in input API documentation --- docs/api-reference/miscellaneous/inputs/media-input.mdx | 5 +++++ .../products/inputs/product-media-create-input.mdx | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/docs/api-reference/miscellaneous/inputs/media-input.mdx b/docs/api-reference/miscellaneous/inputs/media-input.mdx index 6e9771120..15e11e9df 100644 --- a/docs/api-reference/miscellaneous/inputs/media-input.mdx +++ b/docs/api-reference/miscellaneous/inputs/media-input.mdx @@ -36,6 +36,7 @@ input MediaInput { alt: String image: Upload mediaUrl: String + asyncDownload: Boolean } ``` @@ -53,6 +54,10 @@ Represents an image file in a multipart request. Represents an URL to an external media. +#### [MediaInput.asyncDownload](#)[`Boolean`](../../../api-reference/miscellaneous/scalars/boolean.mdx) + +Determine if mediaUrl will downloaded synchronously or not. + ### Member Of [`ProductBulkCreateInput`](../../../api-reference/products/inputs/product-bulk-create-input.mdx) diff --git a/docs/api-reference/products/inputs/product-media-create-input.mdx b/docs/api-reference/products/inputs/product-media-create-input.mdx index 85662c2d1..ceb4cdce4 100644 --- a/docs/api-reference/products/inputs/product-media-create-input.mdx +++ b/docs/api-reference/products/inputs/product-media-create-input.mdx @@ -37,6 +37,7 @@ input ProductMediaCreateInput { image: Upload product: ID! mediaUrl: String + asyncDownload: Boolean } ``` @@ -58,6 +59,10 @@ ID of an product. Represents an URL to an external media. +#### [ProductMediaCreateInput.asyncDownload](#)[`Boolean`](../../../api-reference/miscellaneous/scalars/boolean.mdx) + +Determine if mediaUrl will downloaded synchronously or not. + ### Member Of [`productMediaCreate`](../../../api-reference/products/mutations/product-media-create.mdx)