[IMP]: Modified view of sales configuration.
bzr revid: uco@tinyerp.com-20120223105553-gkjlqq129bbcoig3
This commit is contained in:
@@ -67,12 +67,38 @@ class sale_config_picking_policy(osv.osv_memory):
|
||||
'wiki_sale_faq' : fields.boolean("Install a sales FAQ?"),
|
||||
'crm_partner_assign' : fields.boolean("Manage a several address per customer"),
|
||||
'google_map' : fields.boolean("Google maps on customer"),
|
||||
'create_leads': fields.boolean("Create Leads from an Email Account"),
|
||||
'server' : fields.char('Server Name', size=256, required=True),
|
||||
'port' : fields.integer('Port', required=True),
|
||||
'type':fields.selection([
|
||||
('pop', 'POP Server'),
|
||||
('imap', 'IMAP Server'),
|
||||
('local', 'Local Server'),
|
||||
], 'Server Type', required=True),
|
||||
'is_ssl': fields.boolean('SSL/TLS', help="Connections are encrypted with SSL/TLS through a dedicated port (default: IMAPS=993, POP=995)"),
|
||||
'user' : fields.char('Username', size=256, required=True),
|
||||
'password' : fields.char('Password', size=1024, required=True),
|
||||
'plugin_thunderbird': fields.boolean('Push your email from Thunderbird to an OpenERP document'),
|
||||
'plugin_outlook': fields.boolean('Push your email from Outlook to an OpenERP document'),
|
||||
|
||||
}
|
||||
_defaults = {
|
||||
'order_policy': 'manual',
|
||||
'tax_policy': 'no_tax',
|
||||
'type': 'pop',
|
||||
}
|
||||
|
||||
def onchange_server_type(self, cr, uid, ids, server_type=False, ssl=False):
|
||||
port = 0
|
||||
values = {}
|
||||
if server_type == 'pop':
|
||||
port = ssl and 995 or 110
|
||||
elif server_type == 'imap':
|
||||
port = ssl and 993 or 143
|
||||
else:
|
||||
values['server'] = ''
|
||||
values['port'] = port
|
||||
return {'value':values}
|
||||
|
||||
def onchange_order(self, cr, uid, ids, sale, deli, context=None):
|
||||
res = {}
|
||||
|
||||
@@ -31,7 +31,6 @@
|
||||
</group>
|
||||
|
||||
<separator string="Sale Order" colspan="4"/>
|
||||
|
||||
<group colspan="4" col="8">
|
||||
<group colspan="4" col="4">
|
||||
<field name="group_sale_pricelist_per_customer"/>
|
||||
@@ -62,7 +61,6 @@
|
||||
</group>
|
||||
|
||||
<separator string="Contracts" colspan="4"/>
|
||||
|
||||
<group colspan="4" col="8">
|
||||
<group colspan="4" col="4">
|
||||
<field name="analytic_user_function"/>
|
||||
@@ -71,9 +69,31 @@
|
||||
<newline/>
|
||||
</group>
|
||||
</group>
|
||||
|
||||
<separator string="Emails" colspan="8"/>
|
||||
<group col="8" colspan="4">
|
||||
<field name="create_leads"/>
|
||||
<group col="4" colspan="4" attrs="{'invisible': [('create_leads','=',False)]}">
|
||||
<group col="8" colspan="4">
|
||||
<field name="server"/>
|
||||
<field name="type" nolabel="1" on_change="onchange_server_type(type, is_ssl)"/>
|
||||
<field name="port"/>
|
||||
<field name="is_ssl" on_change="onchange_server_type(type, is_ssl)"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group col="4" colspan="2">
|
||||
<field name="user"/>
|
||||
<field name="password"/>
|
||||
</group>
|
||||
</group>
|
||||
<group col="4" colspan="4">
|
||||
<field name="plugin_thunderbird"/>
|
||||
<newline/>
|
||||
<field name="plugin_outlook"/>
|
||||
</group>
|
||||
</group>
|
||||
|
||||
<separator string="Import and Synchronize data from an other application" colspan="4"/>
|
||||
|
||||
<group colspan="4" col="8">
|
||||
<group colspan="4" col="4">
|
||||
<field name="import_sugarcrm"/>
|
||||
@@ -89,7 +109,6 @@
|
||||
</group>
|
||||
|
||||
<separator string="Documents and Wiki" colspan="4"/>
|
||||
|
||||
<group colspan="4" col="8">
|
||||
<group colspan="4" col="4">
|
||||
<newline/>
|
||||
@@ -99,7 +118,6 @@
|
||||
</group>
|
||||
|
||||
<separator string="Documents and Wiki" colspan="4"/>
|
||||
|
||||
<group colspan="4" col="8">
|
||||
<group colspan="4" col="4">
|
||||
<newline/>
|
||||
@@ -109,7 +127,6 @@
|
||||
</group>
|
||||
|
||||
<separator string="Customer Form" colspan="4"/>
|
||||
|
||||
<group colspan="4" col="8">
|
||||
<group colspan="4" col="4">
|
||||
<field name="crm_partner_assign"/>
|
||||
@@ -120,8 +137,8 @@
|
||||
</group>
|
||||
|
||||
<group>
|
||||
<button string="Cancel" icon="gtk-cancel" special="cancel" />
|
||||
<button string="Apply" icon="gtk-apply" name="apply_cb" type="object" />
|
||||
<button string="Cancel" icon="gtk-cancel" special="cancel" />
|
||||
<button string="Apply" icon="gtk-apply" name="apply_cb" type="object" />
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
|
||||
Reference in New Issue
Block a user