Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
8a379e6
[ADD] web_widget_url_advanced
simahawk Nov 20, 2018
044129a
[UPD] Update web_widget_url_advanced.pot
oca-travis Jan 9, 2019
7c83723
[MIG] web_widget_url_advanced: Migration to 12.0
alexey-pelykh Jul 20, 2019
42c528d
[UPD] Update web_widget_url_advanced.pot
oca-travis Jul 25, 2019
38a11c9
[UPD] README.rst
OCA-git-bot Jul 29, 2019
fcb5d55
Added translation using Weblate (Chinese (Simplified))
liweijie0812 Sep 1, 2019
ca88990
[IMP] web_widget_url_advanced: black, isort
JoanSForgeFlow Mar 2, 2020
294f541
[MIG] web_widget_url_advanced: Migration to 13.0
JoanSForgeFlow Mar 2, 2020
3e66753
[IMP] Merge 'web_widget_prefixed_url'
JoanSForgeFlow Mar 3, 2020
120933d
[UPD] Update web_widget_url_advanced.pot
oca-travis Mar 9, 2020
ea7dd86
[UPD] README.rst
OCA-git-bot Mar 9, 2020
bfaaaa3
web_widget_url_advanced 13.0.1.1.0
OCA-git-bot Mar 9, 2020
fa619b8
[UPD] README.rst
OCA-git-bot Jul 13, 2020
bd5c64a
[UPD] README.rst
OCA-git-bot Jul 13, 2020
8f62742
[UPD] Brainbean Apps => CorporateHub
alexey-pelykh Nov 8, 2020
be1bbec
[UPD] README.rst
OCA-git-bot Nov 10, 2020
2ce0d68
Added translation using Weblate (Spanish)
claudiagn Feb 17, 2021
8cb6520
web_widget_url_advanced: fix display in tree view
simahawk May 4, 2021
362271f
[IMP] web_widget_url_advanced: black, isort, prettier
Peerapong-Supasompob Jul 13, 2021
e670fcd
[14.0][MIG] web_widget_url_advanced
Peerapong-Supasompob Jul 13, 2021
df3402a
[UPD] Update web_widget_url_advanced.pot
oca-travis Jul 13, 2021
f16e4bc
[UPD] README.rst
OCA-git-bot Jul 13, 2021
38f6e6f
web_widget_url_advanced 14.0.1.0.1
OCA-git-bot Jul 13, 2021
db0a5ca
Update translation files
oca-transbot Jul 13, 2021
0ec64da
[MIG] web_widget_url_advanced: Migration to 15.0
JasminSForgeFlow Dec 23, 2021
dc9cbb8
[UPD] Update web_widget_url_advanced.pot
Mar 9, 2022
a63c8ac
[UPD] README.rst
OCA-git-bot Mar 9, 2022
3a6ad68
[UPD] README.rst
OCA-git-bot Sep 3, 2023
461b8c3
[IMP] web_widget_url_advanced: pre-commit auto fixes
May 27, 2024
c3339ea
[MIG] web_widget_url_advanced: Migration to 17.0
May 27, 2024
02322b9
[UPD] Update web_widget_url_advanced.pot
Aug 29, 2024
8a57c5d
[BOT] post-merge updates
OCA-git-bot Aug 29, 2024
ba27356
[IMP] web_widget_url_advanced: pre-commit auto fixes
Vang-NguyenPhu Dec 13, 2024
9411ff2
[MIG] web_widget_url_advanced: Migration to 18.0
Vang-NguyenPhu Dec 14, 2024
5e1de8a
[UPD] Update web_widget_url_advanced.pot
Sep 17, 2025
121b20c
[BOT] post-merge updates
OCA-git-bot Sep 17, 2025
183a526
Added translation using Weblate (Italian)
mymage Sep 18, 2025
87e38ba
[MIG] web_widget_url_advanced: Migration to 19.0
JasminSForgeFlow Nov 21, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
146 changes: 146 additions & 0 deletions web_widget_url_advanced/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
.. image:: https://odoo-community.org/readme-banner-image
:target: https://odoo-community.org/get-involved?utm_source=readme
:alt: Odoo Community Association

=======================
Web URL widget advanced
=======================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:8390450f4787bfcef6bcf0da87974bc964fe6e8621d110430885912514941c4a
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/license-LGPL--3-blue.png
:target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html
:alt: License: LGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fweb-lightgray.png?logo=github
:target: https://github.com/OCA/web/tree/19.0/web_widget_url_advanced
:alt: OCA/web
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/web-19-0/web-19-0-web_widget_url_advanced
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
:target: https://runboat.odoo-community.org/builds?repo=OCA/web&target_branch=19.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

Extend URL, CopyClipboardURL widget features to ease customization of
anchor's text.

By default, the URL, CopyClipboardURL widget will show the plain URL.
You can specify an attribute to provide a static label too.

With this module, you can use a field for link's inner text using
attribute 'text_field'. You can also add a prefix to the link using
attribute 'prefix_name'.

Until 13.0 this functionality was separated in modules
'web_widget_url_advanced' and 'web_widget_prefixed_url'

**Table of contents**

.. contents::
:local:

Usage
=====

Use url, CopyClipboardURL widget as you do usually, then add an extra
parameter text\_ field to indicate which field (present in the view
already) must be used for the anchor text.

.. code:: xml

<field name="some_url" widget="url" text_field="another_field" />

M2O fields are supported: display_name is used automatically.

For example, in the partner form, if you want to display the website
link with partner's name as anchor you can do:

.. code:: xml

<field name="website" widget="url" text_field="name" placeholder="e.g. www.odoo.com"/>

This is going to change the rendering from

|image1|

to

|image2|

Or user can add any hyperlink text using 'prefix_name' attribute

.. code:: xml

<field name="skype_name" widget="url" prefix_name="skype"/>

both can be applied inside the options attribute too:

.. code:: xml

<field name="skype_name" widget="url" options="{'prefix_name': 'skype'}"/>

.. |image1| image:: https://raw.githubusercontent.com/OCA/web/19.0/web_widget_url_advanced/static/description/before.png
.. |image2| image:: https://raw.githubusercontent.com/OCA/web/19.0/web_widget_url_advanced/static/description/after.png

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/web/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback <https://github.com/OCA/web/issues/new?body=module:%20web_widget_url_advanced%0Aversion:%2019.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Credits
=======

Authors
-------

* Camptocamp

Contributors
------------

- Simone Orsi <[email protected]>
- `CorporateHub <https://corporatehub.eu/>`__

- Alexey Pelykh <[email protected]>

- Jay Vora <[email protected]>
- Swapnesh Shah <[email protected]>
- Joan Sisquella <[email protected]>
- Peerapong Supasompob <[email protected]>
- Nedas Žilinskas <[email protected]>
- `Komit <https://komit-consulting.com>`__:

- Vang Nguyen Phu

Maintainers
-----------

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.

This module is part of the `OCA/web <https://github.com/OCA/web/tree/19.0/web_widget_url_advanced>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
Empty file.
20 changes: 20 additions & 0 deletions web_widget_url_advanced/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Copyright 2018 Simone Orsi - Camptocamp SA
# License LGPLv3.0 or later (https://www.gnu.org/licenses/lgpl-3.0.en.html).
{
"name": "Web URL widget advanced",
"summary": "This module extends URL widget "
"for displaying anchors with custom labels.",
"category": "Web",
"version": "19.0.1.0.0",
"license": "LGPL-3",
"author": "Camptocamp, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/web",
"depends": ["web"],
"data": [],
"assets": {
"web.assets_backend": [
"web_widget_url_advanced/static/src/fields/**/*",
],
},
"installable": True,
}
Empty file.
14 changes: 14 additions & 0 deletions web_widget_url_advanced/i18n/it.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 18.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
13 changes: 13 additions & 0 deletions web_widget_url_advanced/i18n/web_widget_url_advanced.pot
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 18.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"
Empty file.
3 changes: 3 additions & 0 deletions web_widget_url_advanced/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[build-system]
requires = ["whool"]
build-backend = "whool.buildapi"
10 changes: 10 additions & 0 deletions web_widget_url_advanced/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
- Simone Orsi \<<[email protected]>\>
- [CorporateHub](https://corporatehub.eu/)
- Alexey Pelykh \<<[email protected]>\>
- Jay Vora \<<[email protected]>\>
- Swapnesh Shah \<<[email protected]>\>
- Joan Sisquella \<<[email protected]>\>
- Peerapong Supasompob \<<[email protected]>\>
- Nedas Žilinskas \<<[email protected]>\>
- [Komit](https://komit-consulting.com):
- Vang Nguyen Phu
11 changes: 11 additions & 0 deletions web_widget_url_advanced/readme/DESCRIPTION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
Extend URL, CopyClipboardURL widget features to ease customization of anchor's text.

By default, the URL, CopyClipboardURL widget will show the plain URL. You can specify an
attribute to provide a static label too.

With this module, you can use a field for link's inner text using
attribute 'text_field'. You can also add a prefix to the link using
attribute 'prefix_name'.

Until 13.0 this functionality was separated in modules
'web_widget_url_advanced' and 'web_widget_prefixed_url'
36 changes: 36 additions & 0 deletions web_widget_url_advanced/readme/USAGE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
Use url, CopyClipboardURL widget as you do usually, then add an extra parameter text_
field to indicate which field (present in the view already) must be used for
the anchor text.

``` xml
<field name="some_url" widget="url" text_field="another_field" />
```

M2O fields are supported: display_name is used automatically.

For example, in the partner form, if you want to display the website
link with partner's name as anchor you can do:

``` xml
<field name="website" widget="url" text_field="name" placeholder="e.g. www.odoo.com"/>
```

This is going to change the rendering from

![](../static/description/before.png)

to

![](../static/description/after.png)

Or user can add any hyperlink text using 'prefix_name' attribute

``` xml
<field name="skype_name" widget="url" prefix_name="skype"/>
```

both can be applied inside the options attribute too:

``` xml
<field name="skype_name" widget="url" options="{'prefix_name': 'skype'}"/>
```
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading