Skip to Content
Menu
This question has been flagged
3639 Rodiniai
class Employee(models.Model):
_name = "hr.employee"
_description = "Employee"
_order = 'name_related'
_inherits = {'resource.resource': "resource_id"}
_inherit = ['mail.thread', 'hr.contract']
rel_field = fields.Many2one('hr.contract')
hr_wage = fields.Char(string='wage', related='rel_field.wage')


class Contract(models.Model):
_name = 'hr.contract'
_description = 'Contract'
_inherit = ['mail.thread', 'ir.needaction_mixin']
wage = fields.Float('Wage', digits=(16, 2), required=True, help="Basic Salary of the employee")

   in hr.xml file i have this field<field name ='hr_wage' />

Portretas
Atmesti
Related Posts Replies Rodiniai Veikla
3
rugs. 21
9385
4
saus. 20
3192
0
lapkr. 18
4427
1
saus. 25
1869
3
spal. 22
5890