add check for update previous value
This commit is contained in:
parent
56b75ac205
commit
924b9dac6e
|
@ -72,6 +72,7 @@ class Project(models.Model):
|
|||
project_cons_hrs = fields.One2many('project.consultant.hrs', 'project_id', 'Consultant Allocation', copy=False)
|
||||
comment = fields.Text(string='Comment')
|
||||
tag_ids = fields.Many2many('custom.project.tags', string='Tags')
|
||||
is_check = fields.Boolean()
|
||||
|
||||
@api.onchange('allowed_internal_user_ids')
|
||||
def onchange_add_allowed_internal_users(self):
|
||||
|
@ -109,7 +110,7 @@ class Project(models.Model):
|
|||
'employee_id': rec[1],
|
||||
'timesheet_hour': rec[2]})
|
||||
|
||||
@api.depends('cost', 'expenses_amt', 'budgeted_revenue')
|
||||
@api.depends('cost', 'expenses_amt', 'budgeted_revenue', 'is_check')
|
||||
def _compute_calc(self):
|
||||
for record in self:
|
||||
consultant_cost = 0.0
|
||||
|
|
|
@ -59,6 +59,7 @@
|
|||
<field name="sale_line_id" string="Default Sales Order Item"
|
||||
invisible="1"
|
||||
options="{'no_create': True, 'no_edit': True, 'delete': False}"/>
|
||||
<field name="is_check" invisible="1"/>
|
||||
</group>
|
||||
<field name="sale_line_employee_ids"
|
||||
attrs="{'invisible': ['|', ('bill_type', '!=', 'customer_project'), ('pricing_type', '!=', 'employee_rate')]}">
|
||||
|
|
Loading…
Reference in New Issue