Hardik Sanchawat (OpenERP) has proposed merging 
lp:~openerp-commiter/openobject-addons/trunk-exception-warning-imp-dbr-account-hsa
 into lp:~openerp-dev/openobject-addons/trunk-exception-warning-imp-dbr.

Requested reviews:
  Kuldeep Joshi(OpenERP) (kjo-openerp)

For more details, see:
https://code.launchpad.net/~openerp-commiter/openobject-addons/trunk-exception-warning-imp-dbr-account-hsa/+merge/114788

Hello,

I update warning messages in account modules.

Thanks
-hsa
 
-- 
https://code.launchpad.net/~openerp-commiter/openobject-addons/trunk-exception-warning-imp-dbr-account-hsa/+merge/114788
Your team OpenERP R&D Team is subscribed to branch 
lp:~openerp-dev/openobject-addons/trunk-exception-warning-imp-dbr.
=== modified file 'account/account.py'
--- account/account.py	2012-07-11 09:07:53 +0000
+++ account/account.py	2012-07-13 07:04:35 +0000
@@ -624,7 +624,7 @@
         value = 'account.account,' + str(ids[0])
         partner_prop_acc = self.pool.get('ir.property').search(cr, uid, [('value_reference','=',value)], context=context)
         if partner_prop_acc:
-            raise osv.except_osv(_('Warning !'), _('You can not remove/desactivate an account which is set on a customer or supplier.'))
+            raise osv.except_osv(_('Warning !'), _('You cannot remove/deactivate an account which is set on a customer or supplier.'))
         return True
 
     def _check_allow_type_change(self, cr, uid, ids, new_type, context=None):
@@ -907,7 +907,7 @@
         return True
 
     _constraints = [
-        (_check_duration, 'Error! The start date of the fiscal year must be before his end date.', ['date_start','date_stop'])
+        (_check_duration, 'Error! The start date of the fiscal year must be less than the end date.', ['date_start','date_stop'])
     ]
 
     def create_period3(self, cr, uid, ids, context=None):
@@ -1025,7 +1025,7 @@
 
     _constraints = [
         (_check_duration, 'Error ! The duration of the Period(s) is/are invalid. ', ['date_stop']),
-        (_check_year_limit, 'Invalid period ! Some periods overlap or the date period is not in the scope of the fiscal year. ', ['date_stop'])
+        (_check_year_limit, 'Invalid period ! Some periods overlap or the date period which is not in the scope of the fiscal year. ', ['date_stop'])
     ]
 
     def next(self, cr, uid, period, step, context=None):
@@ -1072,7 +1072,7 @@
         if 'company_id' in vals:
             move_lines = self.pool.get('account.move.line').search(cr, uid, [('period_id', 'in', ids)])
             if move_lines:
-                raise osv.except_osv(_('Warning !'), _('You can not modify company of this period as some journal items exists.'))
+                raise osv.except_osv(_('Warning !'), _('You cannot modify company of this period as some journal items exist.'))
         return super(account_period, self).write(cr, uid, ids, vals, context=context)
 
     def build_ctx_periods(self, cr, uid, period_from_id, period_to_id):
@@ -1085,9 +1085,9 @@
         period_date_stop = period_to.date_stop
         company2_id = period_to.company_id.id
         if company1_id != company2_id:
-            raise osv.except_osv(_('Error'), _('You should have chosen periods that belongs to the same company'))
+            raise osv.except_osv(_('Error'), _('You should choose the periods that belong to the same company.'))
         if period_date_start > period_date_stop:
-            raise osv.except_osv(_('Error'), _('Start period should be smaller then End period'))
+            raise osv.except_osv(_('Error'), _('Start period should be smaller than End period.'))
         #for period from = january, we want to exclude the opening period (but it has same date_from, so we have to check if period_from is special or not to include that clause or not in the search).
         if period_from.special:
             return self.search(cr, uid, [('date_start', '>=', period_date_start), ('date_stop', '<=', period_date_stop), ('company_id', '=', company1_id)])
@@ -1569,11 +1569,11 @@
                 if not company_id:
                     company_id = line.account_id.company_id.id
                 if not company_id == line.account_id.company_id.id:
-                    raise osv.except_osv(_('Error'), _("Couldn't create move between different companies"))
+                    raise osv.except_osv(_('Error'), _("Cannot create moves for different companies"))
 
                 if line.account_id.currency_id and line.currency_id:
                     if line.account_id.currency_id.id != line.currency_id.id and (line.account_id.currency_id.id != line.account_id.company_id.currency_id.id):
-                        raise osv.except_osv(_('Error'), _("""Couldn't create move with currency different from the secondary currency of the account "%s - %s". Clear the secondary currency field of the account definition if you want to accept all currencies.""") % (line.account_id.code, line.account_id.name))
+                        raise osv.except_osv(_('Error'), _("""Cannot create move with currency different from ..""") % (line.account_id.code, line.account_id.name))
 
             if abs(amount) < 10 ** -4:
                 # If the move is balanced
@@ -2514,7 +2514,7 @@
     _check_recursion = check_cycle
     _constraints = [
         (_check_recursion, 'Error ! You can not create recursive account templates.', ['parent_id']),
-        (_check_type, 'Configuration Error!\nYou can not define children to an account with internal type different of "View"! ', ['type']),
+        (_check_type, 'Configuration Error!\nYou can not define children to an account that has internal type other than  "View"!', ['type']),
 
     ]
 

=== modified file 'account/account_cash_statement.py'
--- account/account_cash_statement.py	2012-03-22 14:36:54 +0000
+++ account/account_cash_statement.py	2012-07-13 07:04:35 +0000
@@ -298,7 +298,7 @@
         if journal_type == 'bank':
             return super(account_cash_statement, self).balance_check(cr, uid, cash_id, journal_type, context)
         if not self._equal_balance(cr, uid, cash_id, context):
-            raise osv.except_osv(_('Error !'), _('The closing balance should be the same than the computed balance!'))
+            raise osv.except_osv(_('Error !'), _('The closing balance should be equal to compute balance on this cash register !'))
         return True
 
     def statement_close(self, cr, uid, ids, journal_type='bank', context=None):

=== modified file 'account/account_invoice.py'
--- account/account_invoice.py	2012-07-10 21:21:15 +0000
+++ account/account_invoice.py	2012-07-13 07:04:35 +0000
@@ -364,7 +364,7 @@
         except Exception, e:
             if '"journal_id" viol' in e.args[0]:
                 raise orm.except_orm(_('Configuration Error!'),
-                     _('There is no Accounting Journal of type Sale/Purchase defined!'))
+                     _('No Sale/Purchase Journal(s) defined !'))
             else:
                 raise orm.except_orm(_('Unknown Error'), str(e))
 
@@ -459,7 +459,7 @@
                     pay_res_id = pay_line_data and pay_line_data[0].get('value_reference',False) and int(pay_line_data[0]['value_reference'].split(',')[1]) or False
                     if not rec_res_id and not pay_res_id:
                         raise osv.except_osv(_('Configuration Error !'),
-                            _('Can not find a chart of accounts for this company, you should create one.'))
+                            _('Cannot find a chart of accounts for this company, you should create one.'))
                     account_obj = self.pool.get('account.account')
                     rec_obj_acc = account_obj.browse(cr, uid, [rec_res_id])
                     pay_obj_acc = account_obj.browse(cr, uid, [pay_res_id])
@@ -554,7 +554,7 @@
                     pay_res_id = pay_line_data and pay_line_data[0].get('value_reference',False) and int(pay_line_data[0]['value_reference'].split(',')[1]) or False
                     if not rec_res_id and not pay_res_id:
                         raise osv.except_osv(_('Configuration Error !'),
-                            _('Can not find a chart of account, you should create one from the configuration of the accounting menu.'))
+                            _('Cannot find a chart of account, you should create one from Settings\Configuration\Accounting menu.'))
                     if type in ('out_invoice', 'out_refund'):
                         acc_id = rec_res_id
                     else:
@@ -569,7 +569,7 @@
                                 result_id = account_obj.search(cr, uid, [('name','=',line.account_id.name),('company_id','=',company_id)])
                                 if not result_id:
                                     raise osv.except_osv(_('Configuration Error !'),
-                                        _('Can not find a chart of account, you should create one from the configuration of the accounting menu.'))
+                                        _('Cannot find a chart of account, you should create one from Settings\Configuration\Accounting menu.'))
                                 inv_line_obj.write(cr, uid, [line.id], {'account_id': result_id[-1]})
             else:
                 if invoice_line:
@@ -577,7 +577,7 @@
                         obj_l = account_obj.browse(cr, uid, inv_line[2]['account_id'])
                         if obj_l.company_id.id != company_id:
                             raise osv.except_osv(_('Configuration Error !'),
-                                _('Invoice line account company does not match with invoice company.'))
+                                _('Company of invoice line account and the company of invoice does not match.'))
                         else:
                             continue
         if company_id and type:
@@ -598,7 +598,7 @@
                 if r[1] == 'journal_id' and r[2] in journal_ids:
                     val['journal_id'] = r[2]
             if not val.get('journal_id', False):
-                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 !'), (_('Cannot find any account journal of %s type for this company.\n\nYou can create one in the menu: \nConfiguration\Journals\Journals.') % (journal_type)))
             dom = {'journal_id':  [('id', 'in', journal_ids)]}
         else:
             journal_ids = obj_journal.search(cr, uid, [])
@@ -1475,7 +1475,7 @@
             if prod.uom_id.category_id.id != prod_uom.category_id.id:
                  warning = {
                     'title': _('Warning!'),
-                    'message': _('You selected an Unit of Measure which is not compatible with the product.')
+                    'message': _('You selected a Unit of Measure which is not compatible with the Unit of Measure of the product.')
             }
             return {'value': res['value'], 'warning': warning}
         return res

=== modified file 'account/account_move_line.py'
--- account/account_move_line.py	2012-06-15 13:49:45 +0000
+++ account/account_move_line.py	2012-07-13 07:04:35 +0000
@@ -576,7 +576,7 @@
         lines = self.browse(cr, uid, ids, context=context)
         for l in lines:
             if l.account_id.type == 'view':
-                raise osv.except_osv(_('Error :'), _('You can not create journal items on a "view" account %s %s') % (l.account_id.code, l.account_id.name))
+                raise osv.except_osv(_('Error :'), _('You cannot create journal items on “View” type account %s %s.') % (l.account_id.code, l.account_id.name))
         return True
 
     def _check_no_closed(self, cr, uid, ids, context=None):
@@ -610,7 +610,7 @@
     _constraints = [
         (_check_no_view, 'You can not create journal items on an account of type view.', ['account_id']),
         (_check_no_closed, 'You can not create journal items on closed account.', ['account_id']),
-        (_check_company_id, 'Company must be the same for its related account and period.', ['company_id']),
+        (_check_company_id, 'Account and Period must belong to the same company.', ['company_id']),
         (_check_date, 'The date of your Journal Entry is not in the defined period! You should change the date or remove this constraint from the journal.', ['date']),
         (_check_currency, 'The selected account of your Journal Entry forces to provide a secondary currency. You should remove the secondary currency on the account or select a multi-currency view on the journal.', ['currency_id']),
     ]

=== modified file 'account/wizard/account_move_journal.py'
--- account/wizard/account_move_journal.py	2012-06-29 09:32:56 +0000
+++ account/wizard/account_move_journal.py	2012-07-13 07:04:35 +0000
@@ -60,7 +60,7 @@
         if context.get('journal_type', False):
             jids = journal_pool.search(cr, uid, [('type','=', context.get('journal_type'))])
             if not jids:
-                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 !'), _('Cannot find any account journal of %s type for this company.\n\nYou can create one in the menu: \nConfiguration/Journals/Journals.') % context.get('journal_type'))
             journal_id = jids[0]
 
         return journal_id

=== modified file 'account/wizard/account_report_aged_partner_balance.py'
--- account/wizard/account_report_aged_partner_balance.py	2011-10-16 01:28:00 +0000
+++ account/wizard/account_report_aged_partner_balance.py	2012-07-13 07:04:35 +0000
@@ -53,7 +53,7 @@
 
         period_length = data['form']['period_length']
         if period_length<=0:
-            raise osv.except_osv(_('UserError'), _('You must enter a period length that cannot be 0 or below !'))
+            raise osv.except_osv(_('UserError'), _('You must enter a period length greater than 0 !'))
         if not data['form']['date_from']:
             raise osv.except_osv(_('UserError'), _('Enter a Start date !'))
 

_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help   : https://help.launchpad.net/ListHelp

Reply via email to