[ADD]l10n_multilang:One of the existing problem of localization modules is that it doesnot allow you to translate the objects name So Add the tags translate=True on journal name, account name, account type ,account Tax, Templates..

bzr revid: ron@tinyerp.com-20110715124238-0pm6xakc7io3p3mg
This commit is contained in:
ron@tinyerp.com 2011-07-15 18:12:38 +05:30
parent 5a823350e0
commit 3161713bea
3 changed files with 190 additions and 0 deletions

View File

@ -0,0 +1,24 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
import account
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -0,0 +1,49 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
{
"name" : "Belgium - Multi language Chart of Accounts (en/nl/fr)",
"version" : "1.1",
"author" : "OpenERP SA",
"category": 'Localization/Account Charts',
"description": """
Belgian localisation (on top of l10n_be):
* Multilanguage support (en/nl/fr) for Chart of Accounts, Taxes, Tax Codes and Journals
* Multilingual accounting templates
* Multilanguage support Analytic Chart of Accounts and Analytic Journals
* Update partner titles for commonly used legal entities
* Add constraint to ensure unique Tax Code per Company
* Setup wizard changes
- Copy translations for CoA, Tax, Tax Code and Fiscal Position from templates to target objects
- Add options to install the nl and fr languages during the setup
- Generate Financial Journals from the templates
""",
'website': 'http://www.openerp.com',
'init_xml': [],
"depends" : ['account_accountant','l10n_be'],
'update_xml': [
],
'demo_xml': [
],
'installable': True,
'active': False,
}
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -0,0 +1,117 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from osv import fields, osv
from tools.translate import _
class account_account_template(osv.osv):
_inherit = 'account.account.template'
_columns = {
'name': fields.char('Name', size=128, required=True, select=True, translate=True),
}
account_account_template()
class account_account(osv.osv):
_inherit = 'account.account'
_columns = {
'name': fields.char('Name', size=128, required=True, select=True, translate=True),
}
account_account()
class account_tax_code(osv.osv):
_inherit = 'account.tax.code'
_sql_constraints = [
('code_company_uniq', 'unique (code,company_id)', 'The code of the Tax Case must be unique per company !')
]
account_tax_code()
class account_tax_template(osv.osv):
_inherit = 'account.tax.template'
_columns = {
'name': fields.char('Tax Name', size=128, required=True, select=True, translate=True),
}
account_tax_template()
class account_tax_code_template(osv.osv):
_inherit = 'account.tax.code.template'
_columns = {
'name': fields.char('Tax Case Name', size=64, required=True, translate=True),
}
account_tax_code_template()
class account_chart_template(osv.osv):
_inherit = 'account.chart.template'
_columns={
'name': fields.char('Name', size=64, required=True, translate=True),
'bank_from_template':fields.boolean('Banks/Cash from Template', help="Generate Bank/Cash accounts and journals from the Templates."),
}
_defaults = {
'bank_from_template': False,
}
_order = 'name'
account_chart_template()
class account_fiscal_position(osv.osv):
_inherit = 'account.fiscal.position'
_columns = {
'name': fields.char('Fiscal Position', size=64, required=True, translate=True),
}
account_fiscal_position()
class account_fiscal_position_template(osv.osv):
_inherit = 'account.fiscal.position.template'
_columns = {
'name': fields.char('Fiscal Position Template', size=64, required=True, translate=True),
}
account_fiscal_position_template()
class account_journal(osv.osv):
_inherit = 'account.journal'
_columns = {
'name': fields.char('Journal Name', size=64, required=True, translate=True),
}
account_journal()
class account_analytic_account(osv.osv):
_inherit = 'account.analytic.account'
_columns = {
'name': fields.char('Account Name', size=128, required=True, translate=True),
}
account_analytic_account()
class account_analytic_journal(osv.osv):
_inherit = 'account.analytic.journal'
_columns = {
'name': fields.char('Journal Name', size=64, required=True, translate=True),
}
account_analytic_journal()