Skip to content

Conversation

@BhaveshHeliconia
Copy link
Contributor

No description provided.

pedrobaeza and others added 30 commits December 30, 2025 10:07
[MIG] document_url

* bump version to 9.0.1.0.0 and make it installable
* Update JS structure
* Add css in order to be compliant with odoo style
* Add a README.rst and OCA conventions
* Improve selector
* add fr.po for fr translation
* open link with target='_blank'
Without this patch, when you hover on the menu item, its background color does not change, and its cursor is a text one.

With this patch, the menu item styling matches those available in all surrounding menus.
Replace char © by word Copyright
Change format in usage description
Updated by Update PO files to match POT (msgmerge) hook in Weblate.
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: knowledge-12.0/knowledge-12.0-document_url
Translate-URL: https://translation.odoo-community.org/projects/knowledge-12-0/knowledge-12-0-document_url/
Currently translated at 100.0% (14 of 14 strings)

Translation: knowledge-12.0/knowledge-12.0-document_url
Translate-URL: https://translation.odoo-community.org/projects/knowledge-12-0/knowledge-12-0-document_url/hr/
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: knowledge-13.0/knowledge-13.0-document_url
Translate-URL: https://translation.odoo-community.org/projects/knowledge-13-0/knowledge-13-0-document_url/
[MIG] document_url: Migration to 14.0
Define the add attachment and add URL buttons on the same line.
Allow downloading of url type attachments by clicking on the icon or the name.
Define the name of the url type attachments as links (allows to open it in a new tab).
Hide the download button for url attachments.
Force to set mimetype to "application/link" for url attachments.
Displays a link icon for url attachments.
TT30263
@BhaveshHeliconia BhaveshHeliconia mentioned this pull request Dec 30, 2025
11 tasks
@pedrobaeza
Copy link
Member

/ocabot migration document_url

@OCA-git-bot OCA-git-bot added this to the 19.0 milestone Dec 30, 2025
Copy link
Member

@pedrobaeza pedrobaeza left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested on runboat. Are you testing your migrations in your end before pushing them to a PR? It's not working correctly for clicking on the attachment to go to the URL:

Image

There shouldn't preview box as well.

And finally, please squash administrative commits into the main one.

def setUp(self):
super().setUp()
wizard_add_url = self.env["ir.attachment.add_url"]
self.user = self.env["res.users"].create(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use from odoo.tests import new_test_user

@BhaveshHeliconia
Copy link
Contributor Author

@pedrobaeza I did test the migration on my side, and at that time it was working for me. After reviewing it again, I noticed the issue occurs after refreshing the page once the link is added—most likely I missed that scenario during my initial testing.

I’ve now fixed the issue and also improved the UI for a better user experience. Apologies for the inconvenience.

@pedrobaeza
Copy link
Member

OK, now it's working, but it seems you have copied/pasted the whole CSS. Can you reduce it with inheritance?

@pedrobaeza
Copy link
Member

pedrobaeza commented Jan 8, 2026

Please apply #581 (before migration commit).

Copy link
Member

@marcelsavegnago marcelsavegnago left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@OCA-git-bot
Copy link
Contributor

This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖

ypapouin and others added 2 commits January 9, 2026 14:52
- In a first step, instead of replacing a node content with its verbatim copy, we uses the xpath "replace" command with "$0" magic keyword to move all the <t> content into a <div>.
- In a second step, the "Add URL" button is added after the existing "Attach files"button.
@pedrobaeza
Copy link
Member

/ocabot merge nobump

@OCA-git-bot
Copy link
Contributor

What a great day to merge this nice PR. Let's do it!
Prepared branch 19.0-ocabot-merge-pr-578-by-pedrobaeza-bump-nobump, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit ac8a0e8 into OCA:19.0 Jan 12, 2026
7 checks passed
@OCA-git-bot
Copy link
Contributor

Congratulations, your PR was merged at ffb9a21. Thanks a lot for contributing to OCA. ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.