[IMP]: base_calendar: Usability improvement in invite attendee wizard
bzr revid: rpa@tinyerp.com-20101001134641-0s9tmilk1denie0x
This commit is contained in:
parent
6822cd8f20
commit
4f9d58b2a5
|
@ -36,11 +36,11 @@ class base_calendar_invite_attendee(osv.osv_memory):
|
|||
_columns = {
|
||||
'type': fields.selection([('internal', 'Internal User'), \
|
||||
('external', 'External Email'), \
|
||||
('partner', 'Partner Contacts')], 'Type', required=True),
|
||||
('partner', 'Partner Contacts')], 'Type', required=True, help="Select whom you want to Invite"),
|
||||
'user_ids': fields.many2many('res.users', 'invite_user_rel',
|
||||
'invite_id', 'user_id', 'Users'),
|
||||
'partner_id': fields.many2one('res.partner', 'Partner'),
|
||||
'email': fields.char('Email', size=124),
|
||||
'email': fields.char('Email', size=124, help="Provide external email address who will receive this invitation."),
|
||||
'contact_ids': fields.many2many('res.partner.address', 'invite_contact_rel',
|
||||
'invite_id', 'contact_id', 'Contacts'),
|
||||
'send_mail': fields.boolean('Send mail?', help='Check this if you want to \
|
||||
|
|
|
@ -10,42 +10,31 @@
|
|||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Invite People">
|
||||
<separator string="Invite People" colspan="4" />
|
||||
<field name="type" />
|
||||
<field name="send_mail" />
|
||||
<newline />
|
||||
<group col="2" colspan="6"
|
||||
attrs="{'invisible': [('type', '!=', 'external')]}">
|
||||
<field name="email" colspan="4"
|
||||
attrs="{'required': [('type', '=', 'external')]}" />
|
||||
</group>
|
||||
<group col="2" colspan="6"
|
||||
attrs="{'invisible': [('type', '!=', 'internal')]}">
|
||||
<separator string="Users" colspan="4" />
|
||||
<field name="user_ids" select="1" colspan="4"
|
||||
nolabel="1" />
|
||||
<newline />
|
||||
</group>
|
||||
<group col="2" colspan="6"
|
||||
attrs="{'invisible': [('type', '!=', 'partner')]}">
|
||||
<field name="partner_id" colspan="2"
|
||||
on_change="onchange_partner_id(partner_id)"
|
||||
attrs="{'required': [('type', '=', 'partner')]}" />
|
||||
<newline />
|
||||
<separator string="Partner Contacts"
|
||||
colspan="6" />
|
||||
<field name="contact_ids" select="1" colspan="4"
|
||||
nolabel="1" domain="[('partner_id', '=', partner_id)]"
|
||||
attrs="{'readonly': [('type', '!=', 'partner')]}" />
|
||||
</group>
|
||||
<newline />
|
||||
<separator string="" colspan="6" />
|
||||
<group col="4" colspan="4">
|
||||
<button icon='gtk-cancel' special="cancel"
|
||||
string="Cancel" />
|
||||
<button name="do_invite" string="Invite"
|
||||
type="object" icon="gtk-ok" />
|
||||
</group>
|
||||
<separator string="Invite People" colspan="4"/>
|
||||
<field name="type"/>
|
||||
<field name="send_mail"/>
|
||||
<notebook colspan="4">
|
||||
<page string="Data">
|
||||
<group col="2" colspan="6" attrs="{'invisible': [('type', '!=', 'external')]}">
|
||||
<field name="email" colspan="4" attrs="{'required': [('type', '=', 'external')]}"/>
|
||||
</group>
|
||||
<group col="2" colspan="6" attrs="{'invisible': [('type', '!=', 'internal')]}">
|
||||
<separator string="Users" colspan="4"/>
|
||||
<field name="user_ids" select="1" colspan="4" nolabel="1" height="180"/>
|
||||
<newline/>
|
||||
</group>
|
||||
<group col="2" colspan="6" attrs="{'invisible': [('type', '!=', 'partner')]}">
|
||||
<field name="partner_id" colspan="2" on_change="onchange_partner_id(partner_id)" attrs="{'required': [('type', '=', 'partner')]}"/>
|
||||
<newline/>
|
||||
<separator string="Partner Contacts" colspan="6"/>
|
||||
<field name="contact_ids" select="1" colspan="4" nolabel="1" domain="[('partner_id', '=', partner_id)]" attrs="{'readonly': [('type', '!=', 'partner')]}"/>
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
<group col="4" colspan="4">
|
||||
<button icon="gtk-cancel" special="cancel" string="Cancel"/>
|
||||
<button name="do_invite" string="Invite" type="object" icon="gtk-ok"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
|
Loading…
Reference in New Issue