[ADD] send mail
bzr revid: mva@openerp.com-20120106135955-m39cr5g7eont0f2y
This commit is contained in:
parent
d512d9a846
commit
b07edf7795
|
@ -89,7 +89,7 @@ class event_event(osv.osv):
|
|||
"""
|
||||
register_pool = self.pool.get('event.registration')
|
||||
for event in self.browse(cr, uid, ids, context=context):
|
||||
if event.mail_auto_confirm:
|
||||
# if event.mail_auto_confirm:
|
||||
#send reminder that will confirm the event for all the people that were already confirmed
|
||||
reg_ids = register_pool.search(cr, uid, [
|
||||
('event_id', '=', event.id),
|
||||
|
@ -542,10 +542,11 @@ class event_registration(osv.osv):
|
|||
def mail_user(self, cr, uid, ids, confirm=False, context=None):
|
||||
"""
|
||||
Send email to user
|
||||
"""
|
||||
mail_message = self.pool.get('mail.message')
|
||||
"""
|
||||
|
||||
mail_message = self.pool.get('email.template')
|
||||
for registration in self.browse(cr, uid, ids, context=context):
|
||||
src = registration.event_id.reply_to or False
|
||||
# src = registration.reply_to or False
|
||||
email_to = []
|
||||
email_cc = []
|
||||
if registration.email_from:
|
||||
|
@ -568,7 +569,7 @@ class event_registration(osv.osv):
|
|||
body = registration.event_id.mail_confirm
|
||||
if subject or body:
|
||||
mail_message.schedule_with_attach(cr, uid, src, email_to, subject, body, model='event.registration', email_cc=email_cc, res_id=registration.id)
|
||||
|
||||
|
||||
return True
|
||||
|
||||
def mail_user_confirm(self, cr, uid, ids, context=None):
|
||||
|
|
|
@ -457,8 +457,9 @@
|
|||
<filter string="Partner" icon="terp-partner" domain="[]" context="{'group_by':'partner_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Event" icon="terp-crm" domain="[]" context="{'group_by':'event_id'}"/>
|
||||
<filter string="State" icon="terp-stock_effects-object-colorize" domain="[]" context="{'group_by':'state'}"/>
|
||||
<filter string="State" icon="terp-stock_effects-object-colorize" domain="[]" context="{'group_by':'registration_state'}"/>
|
||||
</group>
|
||||
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
|
|
@ -129,4 +129,4 @@ class report_event_registration(osv.osv):
|
|||
|
||||
report_event_registration()
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
|
@ -97,7 +97,7 @@
|
|||
</group>
|
||||
<newline/>
|
||||
|
||||
<group expand="1" string="Group By...">
|
||||
<group expand="1" string="Group By Event...">
|
||||
<filter string="Responsible" name="user_id" icon="terp-personal" context="{'group_by': 'user_id'}"/>
|
||||
<filter string="Speaker" name="speaker" icon="terp-personal+" context="{'group_by': 'speaker_id'}"/>
|
||||
<filter string="Sale Team" icon="terp-personal" context="{'group_by': 'section_id'}"/>
|
||||
|
@ -117,6 +117,12 @@
|
|||
<filter string="Year" icon="terp-go-year"
|
||||
domain="[]" context="{'group_by':'year'}" help="Event Beginning Date"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By Registration...">
|
||||
<filter string="State" icon="terp-stock_effects-object-colorize" context="{'group_by':'state'}" help="Events States"/>
|
||||
<filter string="State" icon="terp-stock_effects-object-colorize" context="{'group_by':'c.state'}" help="Events States"/>
|
||||
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
|
Loading…
Reference in New Issue