If you want to define Functional field in OpenERP use below code -
class Demo1 (osv.osv):
_name = Demo1
_description = Contract
_columns = {
name : fields.char(Contract Name, size=30, required=True),
employee_id : fields.many2one(employee, Employee, required=True),
function : fields.many2one(res.partner.function, Function),
}
Demo1()
0 Comment(s)