Odoo Help


Translation of tracked fields in openerp 7

Alexei R. Acosta
on 9/19/14, 11:40 AM 1,483 views

I'm developing a custom module. In some models I have some tracked fields by using "_track_visibility" option and state field by using "_track" option. When a new object is created tracked fields are shown properly translated, but when I change state field value to confirmed, then tracked fields are shown in English and not as I was expecting translated to Spanish.

What's the problem here? I'm doing something wrong? Is this problem fixed in Odoo v8? There is some parts of my code:

class death(osv.osv): _name = 'death.death' _description = _("Death Record") _rec_name = 'date' _inherit = ['mail.thread', 'ir.needaction_mixin'] _track = { 'state': { 'animal_health_and_biosafety.mt_death_confirmation': lambda self, cr, uid, obj, ctx=None: obj['state'] in ['confirmed'] }, } columns = { 'date': fields.date('Date', required=True, readonly=False, states={'confirmed': [('readonly', True)]}), 'cause_id': fields.many2one('death.cause', string='Cause', help='Death cause', readonly=False, states={'confirmed': [('readonly',True)]}, track_visibility='always'), 'amount': fields.function(_amount, type='integer', string='Amount', multi="amount", help="Number of dead animals", track_visibility='always'), 'note': fields.text('Description', readonly=False, states={'confirmed': [('readonly', True)]}), 'state': fields.selection([('unconfirmed', 'Unconfirmed'), ('confirmed', 'Confirmed')], 'State', required=True, help="Status"), }

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

1 follower(s)


Asked: 9/19/14, 11:40 AM
Seen: 1483 times
Last updated: 3/16/15, 8:10 AM