[project_mailgate] Terms in history are not entirely translated

Bug #707984 reported by Laurent Urbain (Realdolmen)
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Low
OpenERP R&D Addons Team 1
Odoo Server (MOVED TO GITHUB)
Invalid
Undecided
Unassigned

Bug Description

Hi,

All is in the summary.
In project_mailgate module, the terms in history are not entirely translated.

V6.0.1

Related branches

Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :
Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :

It's not because the term is not translated but because term is not present in translation files

Amit Parik (amit-parik)
affects: openobject-addons → openobject-server
Changed in openobject-server:
assignee: nobody → OpenERP's Framework R&D (openerp-dev-framework)
importance: Undecided → Wishlist
status: New → Confirmed
Revision history for this message
Naresh(OpenERP) (nch-openerp) wrote :

Hello,

The bug reported here and its duplicate(lp:797272) has two problems...

1: The translations are missing as per comment #2
2: Having look at the case given in (lp:797272) the code written is something like this in crm_lead.py at line 304.

 self.history(cr, uid, ids, _("Changed Stage to: %s") % stage_obj.name, details=_("Changed Stage to: %s") % stage_obj.name)

note here the 4th argument value " _("Changed Stage to: %s") % stage_obj.name" its passed like this... which is the cause of the bug even if the translations are availble in the respective *.po files. The value is translated before replacing the value of "%s" by stage_obj.name.

So for the 1st part the *.po files needs to be updated where as for the 2nd part I request the addons team to change in the modules where this sort of code effect few eg: crm, project etc they are the modules which has history to be maintained.. the changes to be done is to assign the value before translation... i.e
something like:
msg = "Changed Stage to: %s") % stage_obj.name
self.history(cr, uid, ids,msg, details=msg)

@ community team : can you please add the bug to addons project too

Correct me if I am missing something !

Thanks !

Revision history for this message
Naresh(OpenERP) (nch-openerp) wrote :

corrections:
self.history(cr, uid, ids,_(msg) , details= _(msg))

Amit Parik (amit-parik)
Changed in openobject-addons:
status: New → Confirmed
importance: Undecided → Low
assignee: nobody → OpenERP R&D Addons Team 1 (openerp-dev-addons1)
Changed in openobject-server:
importance: Wishlist → Low
summary: - [V6][project_mailgate] Terms in history are not entirely translated
+ [project_mailgate] Terms in history are not entirely translated
Jigar A. (ifixthat)
Changed in openobject-addons:
status: Confirmed → In Progress
Revision history for this message
Jigar A. (ifixthat) wrote :

Hello Laurent,

     We have tested the issue at our end and found the problem so we have fixed the issue and committed to lp:~openerp-dev/openobject-addons/trunk-bug-707984-jam and proposed for merging in trunk. And Due to recent changes in CRM the message body text have changed so i suggest you to check it with new changes. i have attached the Image file here to give you idea.

Thank You for your kind support

Revision history for this message
Jigar A. (ifixthat) wrote :
Changed in openobject-addons:
status: In Progress → Fix Committed
Changed in openobject-server:
status: Confirmed → Invalid
assignee: OpenERP's Framework R&D (openerp-dev-framework) → nobody
importance: Low → Undecided
tfr (Openerp) (tfr)
Changed in openobject-addons:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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