You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
829 B

  1. # -*- encoding: utf-8 -*-
  2. ##############################################################################
  3. # For copyright and license notices, see __openerp__.py file in root directory
  4. ##############################################################################
  5. from openerp import models, fields
  6. class CrmJobPosition(models.Model):
  7. _name = 'crm.job_position'
  8. _order = "parent_left"
  9. _parent_order = "name"
  10. _parent_store = True
  11. _description = "Job position"
  12. name = fields.Char(required=True)
  13. parent_id = fields.Many2one(comodel_name='crm.job_position')
  14. children = fields.One2many(comodel_name='crm.job_position',
  15. inverse_name='parent_id')
  16. parent_left = fields.Integer('Parent Left', select=True)
  17. parent_right = fields.Integer('Parent Right', select=True)