is it possible? is it correct way for Man2one field?
i have following models:
1) coa_ledgers with id, acc_name, ledger_acc etc.
2) banks with id, bank_name, ledger_acc etc.
for my banks field 'ledger_acc' is Many2one to select from coa_ledgers and it should return the value of 'ledger_acc' field instead of 'id' field means in banks Many2one field will display 'acc_name' field and should return 'ledger_acc' field value and NOT return 'id' field value )
how i can achieve this? please help.
in my Model for banks i have Many2one field as below (by default this will Return 'id' field value from coa_ledgers to Many2one field to store the value but i want it to Return 'ledger_acc' field to store the value)
ledger_acc = fields.Many2one('coa_ledgers', string='Ledger A/c')
kindly help with all possible way(s).
regards