Open
Description
Preconditions and environment
- Magento version: All version
Steps to reproduce
- From Admin create a product and Customizable Options with Option type: File
- From frontend purchase this product with an attached file: sample.jpg
- Placing order with this.
- After expired the period of Quote Lifetime & Enable Clear Shopping Cart: Yes from
(Stores > Configuration > Sales > Checkout > Shopping Cart)
- Open order detail: from customer side, or admin side to download sample.jpg from order above.
Expected result
- Attached file sample.jpg could be downloaded
Actual result
- 404 while attempting to download attached file sample.jpg from order item option
Additional information
Download controller requested to quote_item_option
table where the quote of current order was no longer exist by Quote Lifetime & Enable Clear Shopping Cart leading the request to 404.
here is a constraint key relationship between the following tables: quote
=> quote_item
=> quote_item_option
, tables.
For faster reproduction, you can manually delete the quote instead of waiting for the Quote Lifetime to expire.
Suggestion
- Modify the download functionality to fetch the file from the
sales_order_item
table. - Alternatively, introduce a new table,
sales_order_item_option
, to store attached file references that are independent of the quote expiration and cleaning process.
Release note
No response
Triage and priority
- Severity: S0 - Affects critical data or functionality and leaves users without workaround.
- Severity: S1 - Affects critical data or functionality and forces users to employ a workaround.
- Severity: S2 - Affects non-critical data or functionality and forces users to employ a workaround.
- Severity: S3 - Affects non-critical data or functionality and does not force users to employ a workaround.
- Severity: S4 - Affects aesthetics, professional look and feel, “quality” or “usability”.