← Back to team overview

openerp-expert-localization team mailing list archive

[Bug 900861] Re: on_change doesn't pass context, no translations on exceptions

 

The Bug is fixed... I could do it in this way!!
def onchange_remaining_seats(self,cr,uid,ids,seats,attendee_ids):
		res = {
			'value':{
				'remaining_seats_percent': self._get_remaining_seats_percent(seats,attendee_ids),
					 }
				}	 
		if seats < 0:
			res['warning'] = {
						'title': _('Warning'),
						'message': _('You cannot have negative seats'),
						}
				
		return res

-- 
You received this bug notification because you are a member of OpenERP
Localization Experts, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/900861

Title:
  on_change doesn't pass context, no translations on exceptions

Status in OpenERP Server:
  Confirmed

Bug description:
  This report is related to #537858
  No context is passed on on_change events. That means that messages used in the event (like for example exceptions fired within the event) will be NOT translated by tools.translate '_()' method.
  It is critical on system outside Europe and US

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-server/+bug/900861/+subscriptions