diff options
| author | std-odoo <std@odoo.com> | 2020-04-27 08:18:34 +0000 |
|---|---|---|
| committer | std-odoo <std@odoo.com> | 2020-05-18 08:26:50 +0000 |
| commit | 3a8166d74af7b9d9e011344623a7b5d930422246 (patch) | |
| tree | ab8e47fb610226060c3d224c99f84d8c8921cb66 | |
| parent | 2269a66251cfcd1959945b5abe5ebe96abf86e3b (diff) | |
[FIX] sms: fix empty phone number in the mass SMS composer
Bug
===
Go to CRM, in the lead list view and select a lead without
phone number. Then, click on the action "Send SMS Text Message".
Then, enter in debug mode and go to the SMS form view. The
number will be "0" instead of being empty.
Task-2244195
closes odoo/odoo#51389
X-original-commit: 8805c16bfb1bfb001e674d9a2755ad0e98fcb834
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
| -rw-r--r-- | addons/sms/models/mail_thread.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/sms/models/mail_thread.py b/addons/sms/models/mail_thread.py index 1db4ecd9d53..c3ff8168faa 100644 --- a/addons/sms/models/mail_thread.py +++ b/addons/sms/models/mail_thread.py @@ -133,7 +133,7 @@ class MailThread(models.AbstractModel): # if none, just assign False to the first available number field value, fname = next( ((value, fname) for value, fname in zip(all_numbers, tocheck_fields) if value), - (0, tocheck_fields[0] if tocheck_fields else False) + (False, tocheck_fields[0] if tocheck_fields else False) ) result[record.id] = { 'partner': self.env['res.partner'], |
