Export po file BUG on account module, po syntax error

Bug #666724 reported by Jacara
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Low
OpenERP's Framework R&D

Bug Description

I'm using revision 4465 code.
When i export mn.po file from account module (using Admin->Translations->Import / Export->Export Translation wizard) then generated po file has syntax error.

#. module: account
#: code:addons/account/wizard/account_move_journal.py:0
#, python-format
msgid ""
"Can\'t find any account journal of %s type for this company.\n"
"\n"
"You can create one in the menu: \n"
"Configuration\Financial Accounting\Accounts\Journals.' % (context.get('journal_type"
msgstr ""
"Can\'t find any account journal of %s type for this company.\n"
"\n"
"You can create one in the menu: \n"
"Configuration\Financial Accounting\Accounts\Journals.' % (context.get('journal_type"

My solution to fix this error :
addons/account/wizard/account_move_journal.py line 54:

- raise osv.except_osv(_('Configuration Error !'), _('Can\'t find any account journal of %s type for this company.\n\nYou can create one in the menu: \nConfiguration\Financial Accounting\Accounts\Journals.' % (context.get('journal_type'))))

+ raise osv.except_osv(_('Configuration Error !'), _("Can't find any account journal of %s type for this company.\n\nYou can create one in the menu: \nConfiguration\\Financial Accounting\\Accounts\\Journals." % (context.get('journal_type'))))

------------------------------------

#. module: account
#: code:addons/account/invoice.py:0
#, python-format
msgid ""
"Can\'t find any account journal of %s type for this company.\n"
"\n"
"You can create one in the menu: \n"
"Configuration\Financial Accounting\Accounts\Journals.' % (journal_type)))\n"
" dom = {'journal_id': [('id', 'in', journal_ids)]}\n"
" else:\n"
" journal_ids = obj_journal.search(cr, uid, [])\n"
"\n"
" if currency_id and company_id:\n"
" currency = self.pool.get('res.currency"
msgstr ""
"Can\'t find any account journal of %s type for this company.\n"
"\n"
"You can create one in the menu: \n"
"Configuration\Financial Accounting\Accounts\Journals.' % (journal_type)))\n"
" dom = {'journal_id': [('id', 'in', journal_ids)]}\n"
" else:\n"
" journal_ids = obj_journal.search(cr, uid, [])\n"
"\n"
" if currency_id and company_id:\n"
" currency = self.pool.get('res.currency"

My solution to fix this error :
addons/account/invoice.py line 574:

- raise osv.except_osv(_('Configuration Error !'), _('Can\'t find any account journal of %s type for this company.\n\nYou can create one in the menu: \nConfiguration\Financial Accounting\Accounts\Journals.' % (journal_type)))

+ raise osv.except_osv(_('Configuration Error !'), _("Can't find any account journal of %s type for this company.\n\nYou can create one in the menu: \nConfiguration\\Financial Accounting\\Accounts\\Journals." % (journal_type)))

Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
importance: Undecided → Low
status: New → Confirmed
qdp (OpenERP) (qdp)
affects: openobject-addons → openobject-server
Changed in openobject-server:
assignee: OpenERP R&D Addons Team 3 (openerp-dev-addons3) → OpenERP's Framework R&D (openerp-dev-framework)
Revision history for this message
Olivier Dony (Odoo) (odo-openerp) wrote :

Hello Jacara,

This has now been fixed in the latest trunk, and not just this case but any others too. Starting with a fresh database you should have much cleaner translations.

Thanks for reporting

affects: openobject-server → openobject-addons
Changed in openobject-addons:
status: Confirmed → Fix Released
milestone: none → 6.0-rc2
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.