[CLEAN] mail.compose.message: some cleaning in new fields strings, and in form vivew.
authorThibault Delavallée <tde@openerp.com>
Tue, 5 Mar 2013 12:42:59 +0000 (13:42 +0100)
committerThibault Delavallée <tde@openerp.com>
Tue, 5 Mar 2013 12:42:59 +0000 (13:42 +0100)
bzr revid: tde@openerp.com-20130305124259-x3vb5ds2xi9v389d

addons/email_template/wizard/mail_compose_message_view.xml
addons/mail/wizard/mail_compose_message.py
addons/mail/wizard/mail_compose_message_view.xml

index 5b820e5..8391924 100644 (file)
@@ -7,7 +7,7 @@
             <field name="model">mail.compose.message</field>
             <field name="inherit_id" ref="mail.email_compose_message_wizard_form"/>
             <field name="arch" type="xml">
-                <xpath expr="//field[@name='parent_id']" position="after">
+                <xpath expr="//field[@name='subject']" position="after">
                     <field name="partner_to" groups="base.group_no_one"/>
                     <field name="email_to" groups="base.group_no_one"/>
                     <field name="email_cc" groups="base.group_no_one"/>
index 8445da3..9a84e1b 100644 (file)
@@ -113,11 +113,11 @@ class mail_compose_message(osv.TransientModel):
         'partner_ids': fields.many2many('res.partner',
             'mail_compose_message_res_partner_rel',
             'wizard_id', 'partner_id', 'Additional contacts'),
-        'notify': fields.boolean('Notify followers',
-            help='Notify followers of the documents.'),
-        'post': fields.boolean('Post',
+        'post': fields.boolean('Post a copy in the document',
             help='Post a copy of the message on the document communication history.'),
-        'same_thread': fields.boolean('Reply in the document',
+        'notify': fields.boolean('Notify followers',
+            help='Notify followers of the document'),
+        'same_thread': fields.boolean('Replies in the document',
             help='Replies to the messages will go into the selected document.'),
         'attachment_ids': fields.many2many('ir.attachment',
             'mail_compose_message_ir_attachments_rel',
index 29a305a..6c85e6b 100644 (file)
                         <field name="model" invisible="1"/>
                         <field name="res_id" invisible="1"/>
                         <field name="parent_id" invisible="1"/>
-                        <field name="post"  groups="base.group_no_one"/>
-                        <field name="notify"  groups="base.group_no_one"/>
                         <!-- visible wizard -->
                         <field name="email_from"
                             attrs="{'invisible':[('composition_mode', '!=', 'mass_mail')]}"/>
+                        <field name="subject" placeholder="Subject..." required="True"/>
+                        <field name="post"  groups="base.group_no_one"/>
+                        <field name="notify"  groups="base.group_no_one"
+                            attrs="{'invisible':[('post', '=', True)]}"/>
+                        <field name="same_thread"/>
+                        <field name="reply_to" placeholder="Email address te redirect replies..."
+                            attrs="{'invisible':[('same_thread', '=', True)],
+                                    'required':[('same_thread', '!=', True)]}"/>
                         <label for="partner_ids" string="Recipients"
                             attrs="{'invisible':[('composition_mode', '=', 'mass_mail')]}"/>
                         <div groups="base.group_user"
                             <field name="partner_ids" widget="many2many_tags_email" placeholder="Add contacts to notify..."
                                 context="{'force_email':True, 'show_email':True}"/>
                         </div>
-                        <field name="same_thread"/>
-                        <field name="reply_to" placeholder="Email address te redirect replies..."
-                            attrs="{'invisible':[('same_thread', '=', True)],
-                                    'required':[('same_thread', '!=', True)]}"/>
-                        <field name="subject" placeholder="Subject..." required="True"/>
                     </group>
                     <field name="body"/>
                     <field name="attachment_ids" widget="many2many_binary" string="Attach a file"/>