diff --git a/addons/crm/crm_lead.py b/addons/crm/crm_lead.py
index 34d38668d4f..a6fe706f76a 100644
--- a/addons/crm/crm_lead.py
+++ b/addons/crm/crm_lead.py
@@ -170,7 +170,7 @@ class crm_lead(crm_case, osv.osv):
'contact_name': fields.char('Contact Name', size=64),
'partner_name': fields.char("Customer Name", size=64,help='The name of the future partner company that will be created while converting the lead into opportunity', select=1),
'optin': fields.boolean('Opt-In', help="If opt-in is checked, this contact has accepted to receive emails."),
- 'optout': fields.boolean('Opt-Out', help="If opt-out is checked, this contact has refused to receive emails or unsubscribed to a campaign."),
+ 'opt_out': fields.boolean('Opt-Out', help="If opt-out is checked, this contact has refused to receive emails or unsubscribed to a campaign."),
'type':fields.selection([ ('lead','Lead'), ('opportunity','Opportunity'), ],'Type', help="Type is used to separate Leads and Opportunities"),
'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority', select=True),
'date_closed': fields.datetime('Closed', readonly=True),
@@ -231,10 +231,10 @@ class crm_lead(crm_case, osv.osv):
return {'value': {'email_from': address.email, 'phone': address.phone, 'country_id': address.country_id.id}}
def on_change_optin(self, cr, uid, ids, optin):
- return {'value':{'optin':optin,'optout':False}}
+ return {'value':{'optin':optin,'opt_out':False}}
def on_change_optout(self, cr, uid, ids, optout):
- return {'value':{'optout':optout,'optin':False}}
+ return {'value':{'opt_out':optout,'optin':False}}
def onchange_stage_id(self, cr, uid, ids, stage_id, context={}):
if not stage_id:
diff --git a/addons/crm/crm_lead_view.xml b/addons/crm/crm_lead_view.xml
index 6e2540f7954..09a214a7d53 100644
--- a/addons/crm/crm_lead_view.xml
+++ b/addons/crm/crm_lead_view.xml
@@ -186,7 +186,7 @@
-
+
@@ -539,7 +539,7 @@
-
+
diff --git a/addons/crm/test/ui/crm_demo.yml b/addons/crm/test/ui/crm_demo.yml
index 5ef40838466..a949fecae03 100644
--- a/addons/crm/test/ui/crm_demo.yml
+++ b/addons/crm/test/ui/crm_demo.yml
@@ -15,7 +15,7 @@
name: 'Need 20 Days of Consultancy'
type: opportunity
state: draft
- optout: True
+ opt_out: True
-
I create phonecall record to call partner onchange method.
-