Browse Source

base_country_state_translatable Module (#461)

pull/689/head
rami-wafaie 7 years ago
committed by David Dufresne
parent
commit
a2161280f6
  1. 50
      base_country_state_translatable/README.rst
  2. 5
      base_country_state_translatable/__init__.py
  3. 17
      base_country_state_translatable/__manifest__.py
  4. 5
      base_country_state_translatable/models/__init__.py
  5. 11
      base_country_state_translatable/models/res_country.py

50
base_country_state_translatable/README.rst

@ -0,0 +1,50 @@
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
========================
Translate Country States
========================
This module allows to translate the country states names
Usage
=====
* Inherit this module in your l10n_xx_country_states Module and translate the states names
.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
:alt: Try me on Runbot
:target: https://runbot.odoo-community.org/runbot/175/10.0
Bug Tracker
===========
Bugs are tracked on `GitHub Issues
<https://github.com/OCA/l10n-germany/issues>`_. In case of trouble, please
check there if your issue has already been reported. If you spotted it first,
help us smashing it by providing a detailed and welcomed feedback.
Credits
=======
Contributors
------------
* Rami Alwafaie <rami.alwafaie@initos.com>
Maintainer
----------
.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org
This module is maintained by the OCA.
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.
To contribute to this module, please visit https://odoo-community.org.

5
base_country_state_translatable/__init__.py

@ -0,0 +1,5 @@
# -*- coding: utf-8 -*-
# © initOS GmbH 2017
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
from . import models

17
base_country_state_translatable/__manifest__.py

@ -0,0 +1,17 @@
# -*- coding: utf-8 -*-
# © initOS GmbH 2017
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
{
"name": "Translate Country States",
"version": "10.0.1.0.0",
"depends": ['base',
],
'application': False,
'author': 'initOS GmbH, Odoo Community Association (OCA)',
"category": "Localisation/Europe",
'license': 'AGPL-3',
'data': [],
'installable': True,
'auto_install': False,
}

5
base_country_state_translatable/models/__init__.py

@ -0,0 +1,5 @@
# -*- coding: utf-8 -*-
# © initOS GmbH 2017
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
from . import res_country

11
base_country_state_translatable/models/res_country.py

@ -0,0 +1,11 @@
# -*- coding: utf-8 -*-
# © initOS GmbH 2017
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
from odoo import fields, models
class CountryState(models.Model):
_inherit = 'res.country.state'
name = fields.Char(translate=True)
Loading…
Cancel
Save