Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[17.0] [MIG] website_sale_product_attachment: migration to 17 re-open #1022

Open
wants to merge 60 commits into
base: 17.0
Choose a base branch
from

Conversation

eugenios73
Copy link

Reopen of #945

Jairo Llopis and others added 30 commits February 13, 2025 13:36
… website

This module lets you publish downloadable attachments in a product page.

This is useful if you want to publish firmwares, manuals, specs, warranties,
or whatever document related to the product.

@Tecnativa TT20984 TT23657
… names

Without this fix, the order in which attachments were displayed couldn't be predictable. Now, it's as expected by user: by name.

Also the thumbnails got stretched when the attachment had a long name.

@Tecnativa TT24437
Currently translated at 100.0% (9 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/es/
Currently translated at 33.3% (3 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/fr/
Currently translated at 100.0% (9 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/fr/
Currently translated at 33.3% (3 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/nl/
Currently translated at 100.0% (9 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/ca/
…sudo

In v13, there's no general read ACL for public files, so we need to get
filenames and file type using sudo. The download is performed normally
due to the public=True field in the attachments.
On previous version, attachments had 2 fields for adding both attachment
name and file name.

Now on v13, there's only one, that is fille with the file name. On
initial migration, it was considered that this field is enough, but
putting file names on the website product page can be ugly, limited and
confusing, so we are adding here a new field to store the name we want
to give it for the website e-commerce product page.

It also includes migration script for recovering the old information if
coming from v12.
Currently translated at 100.0% (12 of 12 strings)

Translation: e-commerce-13.0/e-commerce-13.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-13-0/e-commerce-13-0-website_sale_product_attachment/ca/
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: e-commerce-16.0/e-commerce-16.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-16-0/e-commerce-16-0-website_sale_product_attachment/
Currently translated at 100.0% (12 of 12 strings)

Translation: e-commerce-16.0/e-commerce-16.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-16-0/e-commerce-16-0-website_sale_product_attachment/es/
Currently translated at 100.0% (12 of 12 strings)

Translation: e-commerce-16.0/e-commerce-16.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-16-0/e-commerce-16-0-website_sale_product_attachment/it/
…justment

- Make the alert and table placed correctly with the grid display, avoiding overlap and poor placement of the elements in the view.
Jairo Llopis and others added 25 commits February 13, 2025 13:45
… names

Without this fix, the order in which attachments were displayed couldn't be predictable. Now, it's as expected by user: by name.

Also the thumbnails got stretched when the attachment had a long name.

@Tecnativa TT24437
Currently translated at 100.0% (9 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/es/
Currently translated at 33.3% (3 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/fr/
Currently translated at 100.0% (9 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/fr/
Currently translated at 33.3% (3 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/nl/
Currently translated at 100.0% (9 of 9 strings)

Translation: e-commerce-12.0/e-commerce-12.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-12-0/e-commerce-12-0-website_sale_product_attachment/ca/
…sudo

In v13, there's no general read ACL for public files, so we need to get
filenames and file type using sudo. The download is performed normally
due to the public=True field in the attachments.
On previous version, attachments had 2 fields for adding both attachment
name and file name.

Now on v13, there's only one, that is fille with the file name. On
initial migration, it was considered that this field is enough, but
putting file names on the website product page can be ugly, limited and
confusing, so we are adding here a new field to store the name we want
to give it for the website e-commerce product page.

It also includes migration script for recovering the old information if
coming from v12.
Currently translated at 100.0% (12 of 12 strings)

Translation: e-commerce-13.0/e-commerce-13.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-13-0/e-commerce-13-0-website_sale_product_attachment/ca/
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: e-commerce-16.0/e-commerce-16.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-16-0/e-commerce-16-0-website_sale_product_attachment/
Currently translated at 100.0% (12 of 12 strings)

Translation: e-commerce-16.0/e-commerce-16.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-16-0/e-commerce-16-0-website_sale_product_attachment/es/
Currently translated at 100.0% (12 of 12 strings)

Translation: e-commerce-16.0/e-commerce-16.0-website_sale_product_attachment
Translate-URL: https://translation.odoo-community.org/projects/e-commerce-16-0/e-commerce-16-0-website_sale_product_attachment/it/
…justment

- Make the alert and table placed correctly with the grid display, avoiding overlap and poor placement of the elements in the view.
@eugenios73 eugenios73 force-pushed the 17.0-mig-website_sale_product_attachment_re-open branch 2 times, most recently from bde2a2a to c8bfd12 Compare February 13, 2025 16:06
@eugenios73 eugenios73 force-pushed the 17.0-mig-website_sale_product_attachment_re-open branch from c8bfd12 to 8a2b452 Compare February 13, 2025 16:15
@eugenios73 eugenios73 changed the title 17.0 mig website sale product attachment re open [17.0] [MIG] website_sale_product_attachment: migration to 17 re-open Feb 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.