[IMP] crm lead filed optput to opt_out to support res_partner mailtemplare opt_out field consiatancy
bzr revid: jam@tinyerp.com-20120307085701-7j6usg7xszop0n61
This commit is contained in:
parent
108641b123
commit
6c291f1aa0
|
@ -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:
|
||||
|
|
|
@ -186,7 +186,7 @@
|
|||
<group colspan="2" col="2">
|
||||
<separator string="Mailings" colspan="2" col="2"/>
|
||||
<field name="optin" on_change="on_change_optin(optin)"/>
|
||||
<field name="optout" on_change="on_change_optout(optout)"/>
|
||||
<field name="opt_out" on_change="on_change_optout(opt_out)"/>
|
||||
</group>
|
||||
<group colspan="2" col="2">
|
||||
<separator string="Statistics" colspan="2" col="2"/>
|
||||
|
@ -539,7 +539,7 @@
|
|||
<group colspan="2" col="2">
|
||||
<separator string="Mailings" colspan="2"/>
|
||||
<field name="optin" on_change="on_change_optin(optin)"/>
|
||||
<field name="optout" on_change="on_change_optout(optout)"/>
|
||||
<field name="opt_out" on_change="on_change_optout(opt_out)"/>
|
||||
</group>
|
||||
</page>
|
||||
<page string="Communication & History" groups="base.group_extended">
|
||||
|
|
|
@ -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.
|
||||
-
|
||||
|
|
Loading…
Reference in New Issue