From 28a33f3a8d66b198262a05b1cb18fad28676cdf6 Mon Sep 17 00:00:00 2001 From: "Bharat R. Devnani (OpenERP)" Date: Fri, 24 Jan 2014 18:00:45 +0530 Subject: [PATCH] [IMP] improved some warning messages bzr revid: bde@tinyerp.com-20140124123045-kgovbmuhkovax068 --- addons/hr_timesheet_sheet/hr_timesheet_sheet.py | 4 ++-- addons/purchase/purchase.py | 2 +- .../wizard/purchase_requisition_partner.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/hr_timesheet_sheet/hr_timesheet_sheet.py b/addons/hr_timesheet_sheet/hr_timesheet_sheet.py index 12eae4e6ba2..c62bbfb2b57 100644 --- a/addons/hr_timesheet_sheet/hr_timesheet_sheet.py +++ b/addons/hr_timesheet_sheet/hr_timesheet_sheet.py @@ -65,7 +65,7 @@ class hr_timesheet_sheet(osv.osv): def create(self, cr, uid, vals, *args, **argv): if 'employee_id' in vals: if not self.pool.get('hr.employee').browse(cr, uid, vals['employee_id']).user_id: - raise osv.except_osv(_('Error!'), _('In order to create a timesheet for this employee, you must relate a user to it.')) + raise osv.except_osv(_('Error!'), _('In order to create a timesheet for this employee, you must link an employee to a user.')) if not self.pool.get('hr.employee').browse(cr, uid, vals['employee_id']).product_id: raise osv.except_osv(_('Error!'), _('In order to create a timesheet for this employee, you must link the employee to a product, like \'Consultant\'.')) if not self.pool.get('hr.employee').browse(cr, uid, vals['employee_id']).journal_id: @@ -76,7 +76,7 @@ class hr_timesheet_sheet(osv.osv): if 'employee_id' in vals: new_user_id = self.pool.get('hr.employee').browse(cr, uid, vals['employee_id']).user_id.id or False if not new_user_id: - raise osv.except_osv(_('Error!'), _('In order to create a timesheet for this employee, you must relate a user to it.')) + raise osv.except_osv(_('Error!'), _('In order to create a timesheet for this employee, you must link an employee to a user.')) if not self._sheet_date(cr, uid, ids, forced_user_id=new_user_id): raise osv.except_osv(_('Error!'), _('You cannot have 2 timesheets that overlap!\nYou should use the menu \'My Timesheet\' to avoid this problem.')) if not self.pool.get('hr.employee').browse(cr, uid, vals['employee_id']).product_id: diff --git a/addons/purchase/purchase.py b/addons/purchase/purchase.py index e570a73a539..09cdcd4e4d5 100644 --- a/addons/purchase/purchase.py +++ b/addons/purchase/purchase.py @@ -476,7 +476,7 @@ class purchase_order(osv.osv): if not acc_id: acc_id = po_line.product_id.categ_id.property_account_expense_categ.id if not acc_id: - raise osv.except_osv(_('Error!'), _('Define expense account for this product: "%s" (id:%d).') % (po_line.product_id.name, po_line.product_id.id,)) + raise osv.except_osv(_('Error!'), _('Define an expense account for this product: "%s" (id:%d).') % (po_line.product_id.name, po_line.product_id.id,)) else: acc_id = property_obj.get(cr, uid, 'property_account_expense_categ', 'product.category', context=context).id fpos = po_line.order_id.fiscal_position or False diff --git a/addons/purchase_requisition/wizard/purchase_requisition_partner.py b/addons/purchase_requisition/wizard/purchase_requisition_partner.py index 5aeb2c82ab6..a71b53e5ee9 100644 --- a/addons/purchase_requisition/wizard/purchase_requisition_partner.py +++ b/addons/purchase_requisition/wizard/purchase_requisition_partner.py @@ -38,7 +38,7 @@ class purchase_requisition_partner(osv.osv_memory): record_id = context and context.get('active_id', False) or False tender = self.pool.get('purchase.requisition').browse(cr, uid, record_id, context=context) if not tender.line_ids: - raise osv.except_osv(_('Error!'), _('No Product in Requisition.')) + raise osv.except_osv(_('Error!'), _('Define products you want include in the call for bids.')) return res def create_order(self, cr, uid, ids, context=None):