[IMP] mail: use widget one2many_binary

bzr revid: chm@openerp.com-20121024092503-mpk7f1vd8jqynvqc
This commit is contained in:
Christophe Matthieu 2012-10-24 11:25:03 +02:00
parent d8e3f1d46b
commit 2055dacf04
3 changed files with 6 additions and 11 deletions

View File

@ -8,7 +8,7 @@
<field name="inherit_id" ref="mail.email_compose_message_wizard_form"/>
<field name="arch" type="xml">
<data>
<xpath expr="//form/notebook" position="after">
<xpath expr="//form/group" position="after">
<group attrs="{'invisible':[('use_template','=',False)]}">
<field name="use_template" invisible="1"
on_change="onchange_use_template(use_template, template_id, composition_mode, model, res_id, context)"/>

View File

@ -90,6 +90,7 @@ Main Features
'static/lib/jquery.expander/jquery.expander.js',
'static/src/js/mail.js',
'static/src/js/mail_followers.js',
'static/src/js/mail_uploader.js',
],
'qweb': [
'static/src/xml/mail.xml',

View File

@ -14,20 +14,14 @@
<field name="parent_id" invisible="1"/>
<field name="content_subtype" invisible="1"/>
<!-- visible wizard -->
<field name="subject" placeholder="Subject..."
attrs="{'invisible':[('content_subtype', '=', 'plain')]}"/>/>
<field name="partner_ids" widget="many2many_tags" placeholder="Add contacts to notify..."
context="{'force_email':True}"
on_change="onchange_partner_ids(partner_ids)"/>
<field name="subject" placeholder="Subject..."
attrs="{'invisible':[('content_subtype', '=', 'plain')]}"/>/>
<field name="attachment_ids" colspan="4" nolabel="1" widget="one2many_binary" blockui="1"/>
<field name="body" colspan="4" nolabel="1"/>
</group>
<notebook>
<page string="Body">
<field name="body" nolabel="1"/>
</page>
<page string="Attachments">
<field name="attachment_ids" colspan="4" nolabel="1"/>
</page>
</notebook>
<footer>
<button string="Send" name="send_mail" type="object" class="oe_highlight" />
or