[FIX] website_sale_digital: let salesman download digital via portal
Portal shows all Sale Orders available for current user. For example, salesman can see his sales. If such a user can download digital files via product form in backend, it makes sense to let user download them via SO page on portal. However, it wasn't the case because /my/download requires product be purchased by current user [1]. Fix it by checking read access first. STEPS * in backend create SO with digital product (customer must be different from current user) * create invoice and register a payment * navigate to portal (without using customer's token), * open SO, click download on digital product [1]: https://github.com/odoo/odoo/blob/1a24477fab4dd323cf94c010321d8942fb2c1a01/addons/website_sale_digital/models/account_invoice.py#L14-L22 opw-3144600 closes odoo/odoo#112639 Signed-off-by:Morgane Demesmaeker <edm@odoo.com>
Loading