[MERGE] merged with main trunk
authorQuentin (OpenERP) <qdp-launchpad@openerp.com>
Fri, 9 Dec 2011 10:58:17 +0000 (11:58 +0100)
committerQuentin (OpenERP) <qdp-launchpad@openerp.com>
Fri, 9 Dec 2011 10:58:17 +0000 (11:58 +0100)
bzr revid: qdp-launchpad@openerp.com-20111209105817-ad57voseie1btglz

1  2 
addons/account/__openerp__.py
addons/account/account.py
addons/account/account_view.xml

Simple merge
@@@ -130,23 -130,8 +130,23 @@@ account_payment_term_line(
  class account_account_type(osv.osv):
      _name = "account.account.type"
      _description = "Account Type"
 +    
 +    def _get_report_type(self, cr, uid, context=None):
 +        report_obj = self.pool.get('account.financial.report')
 +        report_ids = report_obj.search(cr, uid, [], context=context)
 +        report_type = [('none','/')]
 +        for report in report_obj.browse(cr, uid, report_ids, context=context):
 +            type = report.account_type_ids and report.account_type_ids[0] or False
 +            if type:
 +                if type.code in ('income', 'expense'):
 +                    report_name = 'Profit & Loss ('+type.code+' accounts)'
 +                elif type.code in ('asset','liability'):
 +                    report_name = 'Balance Sheet ('+type.code+' accounts)'
 +                report_type.append((type.code, report_name))
 +        return report_type
 +
      _columns = {
-         'name': fields.char('Account Type', size=64, required=True),
+         'name': fields.char('Account Type', size=64, required=True, translate=True),
          'code': fields.char('Code', size=32, required=True),
          'close_method': fields.selection([('none', 'None'), ('balance', 'Balance'), ('detail', 'Detail'), ('unreconciled', 'Unreconciled')], 'Deferral Method', required=True, help="""Set here the method that will be used to generate the end of year journal entries for all the accounts of this type.
  
Simple merge