[ADD] mail.message.common: added a destination_partners field, many2many to partners, to match the new way of sending emails (to partners).

bzr revid: tde@openerp.com-20120615083610-1rrou3m1lcqc4fcf
This commit is contained in:
Thibault Delavallée 2012-06-15 10:36:10 +02:00
parent 3e47bfeed0
commit 464d3c15ae
3 changed files with 14 additions and 6 deletions

View File

@ -85,6 +85,7 @@ The main features are:
'css': [
'static/src/css/mail.css',
'static/src/css/mail_group.css',
'static/src/css/mail_compose_message.css',
],
'js': [
'static/src/js/jquery.expander.min.js',

View File

@ -117,6 +117,9 @@ class mail_message_common(osv.TransientModel):
'email_cc': fields.char('Cc', size=256, help='Carbon copy message recipients'),
'email_bcc': fields.char('Bcc', size=256, help='Blind carbon copy message recipients'),
'reply_to':fields.char('Reply-To', size=256, help='Preferred response address for the message'),
'destination_partners': fields.many2many('res.partner',
'mail_message_common_partners_destination_rel',
'common_id', 'partner_id', 'Destination partners'),
'headers': fields.text('Message Headers', readonly=1,
help="Full message headers, e.g. SMTP session headers (usually available on inbound messages only)"),
'message_id': fields.char('Message-Id', size=256, help='Message unique identifier', select=1, readonly=1),

View File

@ -57,14 +57,18 @@
<field name="priority">1</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Compose Email">
<form string="Compose Email" version="7.0">
<group col="4">
<field name="subject" colspan="4" widget="char" size="512"/>
<field name="body_text" colspan="4" nolabel="1" height="300" width="300"/>
<field name="subject" colspan="4" nolabel="1" placeholder="Subject..."/>
<field name="body_text" colspan="4" nolabel="1" placeholder="What are you working on ?"/>
<field name="destination_partners" colspan="4" nolabel="1" widget="many2many_tags"/>
<newline/>
<label string="" name="placeholder" colspan="1"/>
<button icon="gtk-close" special="cancel" string="Cancel"/>
<button icon="gtk-ok" name="send_mail" string="Send" type="object"/>
<button icon="gtk-ok" name="send_mail" string="Post" type="object"/>
<p> or <a href="#">Send a Message</a></p>
<button icon="gtk-close" string="Cancel" special="cancel" />
<p>
Checklist . Attach
</p>
</group>
</form>
</field>