===========================================
Website Snippet Country Phone Code Dropdown
===========================================
..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:af3a26574c6f70e54f7e2131a4c5c429db1d6619b81eb4724517a212f0e0a7af
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |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/licence-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%2Fwebsite-lightgray.png?logo=github
:target: https://github.com/OCA/website/tree/16.0/website_snippet_country_phone_code_dropdown
:alt: OCA/website
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/website-16-0/website-16-0-website_snippet_country_phone_code_dropdown
: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/website&target_branch=16.0
:alt: Try me on Runboat
|badge1| |badge2| |badge3| |badge4| |badge5|
This module enhances the features of the `website_snippet_country_dropdown`
module, and its implementation and functionality are very similar. It offers a
snippet with a dropdown for selecting a country as well as an input text field
that auto-populates with the corresponding phone code. This module is intended
to serve as a base for other modules to inherit and integrate into HTML forms.
**Table of contents**
.. contents::
:local:
Usage
=====
To extend this template, you should inherit the `country_dropdown` template and
add your custom code. This template includes three input text fields, which are
the following:
#. ``no_country_field``: Field without code country.
#. ``country_phone_code_field``: Field with only country code (read only)
#. ``complete_field``: Field with the previous two joined (hidden)
The name of the complete field is customizable when user insert the snippet
into a form element with the website editor.
Development
~~~~~~~~~~~
In order to use this element, you can call the reusable Qweb template
`website_snippet_country_phone_code_dropdown.country_dropdown` in your views or
forms to add a sensible country-combined field, which could be a useful element
for the registration of international phone numbers.
**Default Country Selection**
The default country will be determined by the first match among:
#. Extracted from the `default_country` variable.
#. Extracted from the `default_value_prefix` variable, searching by phone code.
#. The current user's country.
#. The current website's company's country.
#. The first country in the list.
**Variables**
All variables you can use to modify its behavior:
#. ``complete_field``: To give the form information a name. Habitually it will
match the field name.
#. ``default_value_prefix``: The phone prefix to be used in the complete_field.
#. ``default_value_number``: The phone number to be used in the complete_field.
#. ``countries``: A recordset of res.country containing all the available
countries.
#. ``default_country``: A res.country record representing the default country.
#. ``no_country_placeholder``: A placeholder text for the phone number input
field.
Bug Tracker
===========
Bugs are tracked on `GitHub Issues <https://github.com/OCA/website/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/website/issues/new?body=module:%20website_snippet_country_phone_code_dropdown%0Aversion:%2016.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
~~~~~~~
* ForgeFlow
Contributors
~~~~~~~~~~~~
* Laura Cazorla <laura.cazorla@forgeflow.com>
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/website <https://github.com/OCA/website/tree/16.0/website_snippet_country_phone_code_dropdown>`_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
Raw data
{
"_id": null,
"home_page": "https://github.com/OCA/website",
"name": "odoo-addon-website-snippet-country-phone-code-dropdown",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.10",
"maintainer_email": null,
"keywords": null,
"author": "ForgeFlow, Odoo Community Association (OCA)",
"author_email": "support@odoo-community.org",
"download_url": null,
"platform": null,
"description": "===========================================\nWebsite Snippet Country Phone Code Dropdown\n===========================================\n\n.. \n !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!\n !! This file is generated by oca-gen-addon-readme !!\n !! changes will be overwritten. !!\n !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!\n !! source digest: sha256:af3a26574c6f70e54f7e2131a4c5c429db1d6619b81eb4724517a212f0e0a7af\n !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!\n\n.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png\n :target: https://odoo-community.org/page/development-status\n :alt: Beta\n.. |badge2| image:: https://img.shields.io/badge/licence-LGPL--3-blue.png\n :target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html\n :alt: License: LGPL-3\n.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fwebsite-lightgray.png?logo=github\n :target: https://github.com/OCA/website/tree/16.0/website_snippet_country_phone_code_dropdown\n :alt: OCA/website\n.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png\n :target: https://translation.odoo-community.org/projects/website-16-0/website-16-0-website_snippet_country_phone_code_dropdown\n :alt: Translate me on Weblate\n.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png\n :target: https://runboat.odoo-community.org/builds?repo=OCA/website&target_branch=16.0\n :alt: Try me on Runboat\n\n|badge1| |badge2| |badge3| |badge4| |badge5|\n\nThis module enhances the features of the `website_snippet_country_dropdown`\nmodule, and its implementation and functionality are very similar. It offers a\nsnippet with a dropdown for selecting a country as well as an input text field\nthat auto-populates with the corresponding phone code. This module is intended\nto serve as a base for other modules to inherit and integrate into HTML forms.\n\n**Table of contents**\n\n.. contents::\n :local:\n\nUsage\n=====\n\nTo extend this template, you should inherit the `country_dropdown` template and\nadd your custom code. This template includes three input text fields, which are\nthe following:\n\n#. ``no_country_field``: Field without code country.\n#. ``country_phone_code_field``: Field with only country code (read only)\n#. ``complete_field``: Field with the previous two joined (hidden)\n\nThe name of the complete field is customizable when user insert the snippet\ninto a form element with the website editor.\n\nDevelopment\n~~~~~~~~~~~\n\nIn order to use this element, you can call the reusable Qweb template\n`website_snippet_country_phone_code_dropdown.country_dropdown` in your views or\nforms to add a sensible country-combined field, which could be a useful element\nfor the registration of international phone numbers.\n\n**Default Country Selection**\n\nThe default country will be determined by the first match among:\n\n#. Extracted from the `default_country` variable.\n#. Extracted from the `default_value_prefix` variable, searching by phone code.\n#. The current user's country.\n#. The current website's company's country.\n#. The first country in the list.\n\n**Variables**\n\nAll variables you can use to modify its behavior:\n\n#. ``complete_field``: To give the form information a name. Habitually it will\n match the field name.\n#. ``default_value_prefix``: The phone prefix to be used in the complete_field.\n#. ``default_value_number``: The phone number to be used in the complete_field.\n#. ``countries``: A recordset of res.country containing all the available\n countries.\n#. ``default_country``: A res.country record representing the default country.\n#. ``no_country_placeholder``: A placeholder text for the phone number input\n field.\n\nBug Tracker\n===========\n\nBugs are tracked on `GitHub Issues <https://github.com/OCA/website/issues>`_.\nIn case of trouble, please check there if your issue has already been reported.\nIf you spotted it first, help us to smash it by providing a detailed and welcomed\n`feedback <https://github.com/OCA/website/issues/new?body=module:%20website_snippet_country_phone_code_dropdown%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.\n\nDo not contact contributors directly about support or help with technical issues.\n\nCredits\n=======\n\nAuthors\n~~~~~~~\n\n* ForgeFlow\n\nContributors\n~~~~~~~~~~~~\n\n* Laura Cazorla <laura.cazorla@forgeflow.com>\n\nMaintainers\n~~~~~~~~~~~\n\nThis module is maintained by the OCA.\n\n.. image:: https://odoo-community.org/logo.png\n :alt: Odoo Community Association\n :target: https://odoo-community.org\n\nOCA, or the Odoo Community Association, is a nonprofit organization whose\nmission is to support the collaborative development of Odoo features and\npromote its widespread use.\n\nThis module is part of the `OCA/website <https://github.com/OCA/website/tree/16.0/website_snippet_country_phone_code_dropdown>`_ project on GitHub.\n\nYou are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.\n",
"bugtrack_url": null,
"license": "LGPL-3",
"summary": "Allow to select country in a dropdown, and fill with phone code",
"version": "16.0.1.0.0.2",
"project_urls": {
"Homepage": "https://github.com/OCA/website"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "ccf9c8cdb0fbc8919486f938526167900a7fe985dfd0666338c5b68776b1c6df",
"md5": "80d11d80d0a7ae845a921cfe16cddade",
"sha256": "59c999361165911836512414e3d73d24559ac39d224eae6f1938070563f777a3"
},
"downloads": -1,
"filename": "odoo_addon_website_snippet_country_phone_code_dropdown-16.0.1.0.0.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "80d11d80d0a7ae845a921cfe16cddade",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.10",
"size": 30874,
"upload_time": "2025-08-18T12:52:05",
"upload_time_iso_8601": "2025-08-18T12:52:05.054544Z",
"url": "https://files.pythonhosted.org/packages/cc/f9/c8cdb0fbc8919486f938526167900a7fe985dfd0666338c5b68776b1c6df/odoo_addon_website_snippet_country_phone_code_dropdown-16.0.1.0.0.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-08-18 12:52:05",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "OCA",
"github_project": "website",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "odoo-addon-website-snippet-country-phone-code-dropdown"
}