diff --git a/addons/account/account.py b/addons/account/account.py index 0f8c9575931..e35676e08a5 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -344,7 +344,7 @@ class account_account(osv.osv): _columns = { 'name': fields.char('Name', size=128, required=True, select=True), 'currency_id': fields.many2one('res.currency', 'Secondary Currency', help="Forces all moves for this account to have this secondary currency."), - 'code': fields.char('Code', size=64, required=True), + 'code': fields.char('Code', size=64, required=True, select=1), 'type': fields.selection([ ('view', 'View'), ('other', 'Regular'), @@ -2254,7 +2254,7 @@ class account_account_template(osv.osv): _columns = { 'name': fields.char('Name', size=128, required=True, select=True), 'currency_id': fields.many2one('res.currency', 'Secondary Currency', help="Forces all moves for this account to have this secondary currency."), - 'code': fields.char('Code', size=64), + 'code': fields.char('Code', size=64, select=1), 'type': fields.selection([ ('receivable','Receivable'), ('payable','Payable'), diff --git a/addons/account/invoice.py b/addons/account/invoice.py index f965b405545..af26e7d2d28 100644 --- a/addons/account/invoice.py +++ b/addons/account/invoice.py @@ -263,7 +263,7 @@ class account_invoice(osv.osv): 'invoice_line': fields.one2many('account.invoice.line', 'invoice_id', 'Invoice Lines', readonly=True, states={'draft':[('readonly',False)]}), 'tax_line': fields.one2many('account.invoice.tax', 'invoice_id', 'Tax Lines', readonly=True, states={'draft':[('readonly',False)]}), - 'move_id': fields.many2one('account.move', 'Journal Entry', readonly=True, help="Link to the automatically generated Journal Items."), + 'move_id': fields.many2one('account.move', 'Journal Entry', readonly=True, select=1, help="Link to the automatically generated Journal Items."), 'amount_untaxed': fields.function(_amount_all, method=True, digits_compute=dp.get_precision('Account'), string='Untaxed', store={ 'account.invoice': (lambda self, cr, uid, ids, c={}: ids, ['invoice_line'], 20),