diff options
| author | stephanchrst <stephanchrst@gmail.com> | 2022-10-25 13:55:43 +0700 |
|---|---|---|
| committer | stephanchrst <stephanchrst@gmail.com> | 2022-10-25 13:55:43 +0700 |
| commit | 3fc38cab92e820cf0b59a6e06d933bfec5c90d4e (patch) | |
| tree | e1997a1c09d0f94005a76ed0d503ce1e576818bb | |
| parent | da1ba5223456e4c39d11a5af67968dda6d569c6b (diff) | |
update stars to zero in pipeline
| -rwxr-xr-x | indoteknik_custom/models/crm_lead.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/indoteknik_custom/models/crm_lead.py b/indoteknik_custom/models/crm_lead.py index 53ea176c..e0a90d9c 100755 --- a/indoteknik_custom/models/crm_lead.py +++ b/indoteknik_custom/models/crm_lead.py @@ -11,6 +11,11 @@ class CrmLead(models.Model): file_siup = fields.Binary(string="Surat Izin Usaha Perdagangan") body_html_lead = fields.Text('Body HTML', compute='compute_body_leads') + @api.onchange('stage_id') + def update_stars(self): + for lead in self: + lead.priority = 0 + def compute_body_leads(self): for lead in self: mail_message = self.env['mail.message'].search([ |
