[IMP] CRM views
bzr revid: fp@tinyerp.com-20100228132156-zw29a51luyuwxz2x
This commit is contained in:
+10
-9
@@ -62,15 +62,15 @@ icon_lst = {
|
||||
|
||||
class crm_case_section(osv.osv):
|
||||
_name = "crm.case.section"
|
||||
_description = "Case Section"
|
||||
_description = "Sales Teams"
|
||||
_order = "name"
|
||||
_columns = {
|
||||
'name': fields.char('Case Section',size=64, required=True, translate=True),
|
||||
'code': fields.char('Section Code',size=8),
|
||||
'active': fields.boolean('Active', help="If the active field is set to true, it will allow you to hide the case section without removing it."),
|
||||
'name': fields.char('Sales Team',size=64, required=True, translate=True),
|
||||
'code': fields.char('Code',size=8),
|
||||
'active': fields.boolean('Active', help="If the active field is set to true, it will allow you to hide the sales team without removing it."),
|
||||
'allow_unlink': fields.boolean('Allow Delete', help="Allows to delete non draft cases"),
|
||||
'user_id': fields.many2one('res.users', 'Responsible User'),
|
||||
'reply_to': fields.char('Reply-To', size=64, help="The email address put in the 'Reply-To' of all emails sent by Open ERP about cases in this section"),
|
||||
'reply_to': fields.char('Reply-To', size=64, help="The email address put in the 'Reply-To' of all emails sent by Open ERP about cases in this sales team"),
|
||||
'parent_id': fields.many2one('crm.case.section', 'Parent Section'),
|
||||
'child_ids': fields.one2many('crm.case.section', 'parent_id', 'Child Sections'),
|
||||
}
|
||||
@@ -112,7 +112,7 @@ class crm_case_categ(osv.osv):
|
||||
|
||||
_columns = {
|
||||
'name': fields.char('Case Category Name', size=64, required=True, translate=True),
|
||||
'section_id': fields.many2one('crm.case.section', 'Case Section'),
|
||||
'section_id': fields.many2one('crm.case.section', 'Sales Team'),
|
||||
'object_id': fields.many2one('ir.model','Object Name'),
|
||||
}
|
||||
def _find_object_id(self, cr, uid, context=None):
|
||||
@@ -131,7 +131,7 @@ class crm_case_resource_type(osv.osv):
|
||||
_rec_name = "name"
|
||||
_columns = {
|
||||
'name': fields.char('Case Resource Type', size=64, required=True, translate=True),
|
||||
'section_id': fields.many2one('crm.case.section', 'Case Section'),
|
||||
'section_id': fields.many2one('crm.case.section', 'Sales Team'),
|
||||
'object_id': fields.many2one('ir.model','Object Name'),
|
||||
}
|
||||
def _find_object_id(self, cr, uid, context=None):
|
||||
@@ -151,7 +151,7 @@ class crm_case_stage(osv.osv):
|
||||
_order = "sequence"
|
||||
_columns = {
|
||||
'name': fields.char('Stage Name', size=64, required=True, translate=True),
|
||||
'section_id': fields.many2one('crm.case.section', 'Case Section'),
|
||||
'section_id': fields.many2one('crm.case.section', 'Sales Team'),
|
||||
'sequence': fields.integer('Sequence', help="Gives the sequence order when displaying a list of case stages."),
|
||||
'object_id': fields.many2one('ir.model','Object Name'),
|
||||
'probability': fields.float('Probability (%)', required=True),
|
||||
@@ -221,7 +221,7 @@ class crm_case(osv.osv):
|
||||
'active': fields.boolean('Active', help="If the active field is set to true, it will allow you to hide the case without removing it."),
|
||||
'description': fields.text('Description'),
|
||||
'section_id': fields.many2one('crm.case.section', 'Sales Team', select=True, help='Sales team to which Case belongs to. Define Responsible user and Email account for mail gateway.'),
|
||||
'email_from': fields.char('Partner Email', size=128, help="These people will receive email."),
|
||||
'email_from': fields.char('Email', size=128, help="These people will receive email."),
|
||||
'email_cc': fields.text('Watchers Emails', size=252 , help="These people will receive a copy of the future" \
|
||||
" communication between partner and users by email"),
|
||||
'email_last': fields.function(_email_last, method=True,
|
||||
@@ -278,6 +278,7 @@ class crm_case(osv.osv):
|
||||
'state': lambda *a: 'draft',
|
||||
'date_deadline': lambda *a:(datetime.today() + timedelta(days=3)).strftime('%Y-%m-%d %H:%M:%S'),
|
||||
'section_id': _get_section,
|
||||
'company_id': lambda s,cr,uid,c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.case', context=c),
|
||||
}
|
||||
_order = 'date_deadline desc, date desc,id desc'
|
||||
|
||||
|
||||
@@ -8,25 +8,25 @@
|
||||
<field name="name">Claim Categories</field>
|
||||
<field name="res_model">crm.case.categ</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="crm.crm_case_categ_tree-view"/>
|
||||
<field name="domain">[('object_id.model', '=', 'crm.claim')]</field>
|
||||
<field name="context">{'object_id':'crm.claim'}</field>
|
||||
<field name="view_id" ref="crm.crm_case_categ_tree-view"/>
|
||||
<field name="domain">[('object_id.model', '=', 'crm.claim')]</field>
|
||||
<field name="context">{'object_id':'crm.claim'}</field>
|
||||
</record>
|
||||
<menuitem action="crm_claim_categ_action" id="menu_crm_case_claim-act" parent="crm.menu_crm_case_categ"/>
|
||||
# ------------------------------------------------------
|
||||
# Stages
|
||||
# ------------------------------------------------------
|
||||
<record id="crm_claim_stage_act" model="ir.actions.act_window">
|
||||
<field name="name">Claim Stages</field>
|
||||
<field name="res_model">crm.case.stage</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="crm.crm_case_stage_tree"/>
|
||||
<field name="domain">[('object_id.model', '=', 'crm.claim')]</field>
|
||||
<field name="context">{'object_id':'crm.claim'}</field>
|
||||
</record>
|
||||
<menuitem action="crm_claim_stage_act" id="menu_crm_claim_stage_act" parent="crm.menu_crm_case_stage"/>
|
||||
<record id="crm_claim_stage_act" model="ir.actions.act_window">
|
||||
<field name="name">Claim Stages</field>
|
||||
<field name="res_model">crm.case.stage</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="crm.crm_case_stage_tree"/>
|
||||
<field name="domain">[('object_id.model', '=', 'crm.claim')]</field>
|
||||
<field name="context">{'object_id':'crm.claim'}</field>
|
||||
</record>
|
||||
<menuitem action="crm_claim_stage_act" id="menu_crm_claim_stage_act" parent="crm.menu_crm_case_stage"/>
|
||||
|
||||
<!-- Claims -->
|
||||
<!-- Claims -->
|
||||
<record model="ir.ui.view" id="crm_case_claims_tree_view">
|
||||
<field name="name">CRM - Claims Tree</field>
|
||||
<field name="model">crm.claim</field>
|
||||
@@ -59,35 +59,35 @@
|
||||
<group colspan="4" col="4">
|
||||
<notebook>
|
||||
<page string="Claim Info">
|
||||
<separator colspan="4" string="Communication"/>
|
||||
<group colspan="4" col="4">
|
||||
<field name="partner_id" string="Partner"
|
||||
on_change="onchange_partner_id(partner_id)" />
|
||||
<field name="partner_address_id" string="Contact"
|
||||
on_change="onchange_partner_address_id(partner_address_id, email_from)" />
|
||||
<field name="partner_phone"/>
|
||||
<field name="partner_mobile"/>
|
||||
<field name="email_from"/>
|
||||
</group>
|
||||
<separator colspan="4" string="Communication"/>
|
||||
<group colspan="4" col="4">
|
||||
<field name="partner_id" string="Partner"
|
||||
on_change="onchange_partner_id(partner_id)" />
|
||||
<field name="partner_address_id" string="Contact"
|
||||
on_change="onchange_partner_address_id(partner_address_id, email_from)" />
|
||||
<field name="partner_phone"/>
|
||||
<field name="partner_mobile"/>
|
||||
<field name="email_from"/>
|
||||
</group>
|
||||
<separator colspan="4" string="Status and Categorization"/>
|
||||
<group colspan="4" col="6">
|
||||
<field name="user_id" string="Responsible" select="2"/>
|
||||
<field name="section_id" widget="selection"/>
|
||||
<label string="Stage: " align="1.0"/>
|
||||
<group colspan="1" col="2">
|
||||
<field name="stage_id" select="1" nolabel="1"/>
|
||||
<button icon="gtk-go-forward" string="" name="stage_next" type="object"/>
|
||||
</group>
|
||||
<field name="categ_id" select="1" widget="selection"
|
||||
domain="[('object_id.model', '=', 'crm.claim')]" />
|
||||
<field name="type_id" string="Type of Action" select="1"
|
||||
domain="[('object_id.model', '=', 'crm.claim')]" />
|
||||
<field name="priority"/>
|
||||
<field name="user_id" string="Responsible" select="2"/>
|
||||
<field name="section_id" widget="selection"/>
|
||||
<label string="Stage: " align="1.0"/>
|
||||
<group colspan="1" col="2">
|
||||
<field name="stage_id" select="1" nolabel="1"/>
|
||||
<button icon="gtk-go-forward" string="" name="stage_next" type="object"/>
|
||||
</group>
|
||||
<field name="categ_id" select="1" widget="selection"
|
||||
domain="[('object_id.model', '=', 'crm.claim')]" />
|
||||
<field name="type_id" string="Type of Action" select="1"
|
||||
domain="[('object_id.model', '=', 'crm.claim')]" />
|
||||
<field name="priority"/>
|
||||
</group>
|
||||
<separator colspan="4" string="References"/>
|
||||
<group colspan="4" col="4">
|
||||
<field name="ref"/>
|
||||
<field name="ref2"/>
|
||||
<field name="ref"/>
|
||||
<field name="ref2"/>
|
||||
</group>
|
||||
<separator colspan="4" string="Claim/Action Description"/>
|
||||
<field name="description" colspan="4" nolabel="1"/>
|
||||
@@ -131,9 +131,9 @@
|
||||
<field name="email"/>
|
||||
<field name="canal_id"/>
|
||||
<button
|
||||
string="Add a CC"
|
||||
name="%(crm.action_view_crm_email_add_cc_wizard)d"
|
||||
icon="gtk-add" type="action"/>
|
||||
string="Add a CC"
|
||||
name="%(crm.action_view_crm_email_add_cc_wizard)d"
|
||||
icon="gtk-add" type="action"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<field name="description" colspan="4" nolabel="1"/>
|
||||
@@ -167,17 +167,17 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="crm_case_graph_view_stage_cost">
|
||||
<field name="name">CRM -Graph</field>
|
||||
<field name="model">crm.claim</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph string="Cases By Stage and Estimates" type="bar" orientation="vertical">
|
||||
<field name="stage_id"/>
|
||||
<field name="planned_cost" operator="+"/>
|
||||
<field name="planned_revenue" operator="+"/>
|
||||
</graph>
|
||||
</field>
|
||||
<record model="ir.ui.view" id="crm_case_graph_view_stage_cost">
|
||||
<field name="name">CRM -Graph</field>
|
||||
<field name="model">crm.claim</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph string="Cases By Stage and Estimates" type="bar" orientation="vertical">
|
||||
<field name="stage_id"/>
|
||||
<field name="planned_cost" operator="+"/>
|
||||
<field name="planned_revenue" operator="+"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_crm_case_claims_filter" model="ir.ui.view">
|
||||
@@ -186,35 +186,32 @@
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search Claims">
|
||||
<group col="4" colspan="1">
|
||||
<filter icon="gtk-new" string="Current Claims"
|
||||
domain="[('state','in',('draft', 'open'))]"
|
||||
separator="1" help="Current Claims" default="1"
|
||||
/>
|
||||
<filter icon="gtk-execute"
|
||||
string="In Progress Claims"
|
||||
domain="[('state','=','open')]"
|
||||
separator="1" help="In Progress Claims"
|
||||
/>
|
||||
<filter icon="gtk-media-pause"
|
||||
string="Pending Claims"
|
||||
domain="[('state','=','pending')]"
|
||||
separator="1" help="All pending Claims"
|
||||
/>
|
||||
</group>
|
||||
<filter icon="gtk-new" string="Current Claims"
|
||||
domain="[('state','in',('draft', 'open'))]"
|
||||
separator="1" help="Current Claims" default="1"
|
||||
/>
|
||||
<filter icon="gtk-execute"
|
||||
string="In Progress Claims"
|
||||
domain="[('state','=','open')]"
|
||||
separator="1" help="In Progress Claims"
|
||||
/>
|
||||
<filter icon="gtk-media-pause"
|
||||
string="Pending Claims"
|
||||
domain="[('state','=','pending')]"
|
||||
separator="1" help="All pending Claims"
|
||||
/>
|
||||
<separator orientation="vertical"/>
|
||||
<group col="4" colspan="2">
|
||||
<field name="name" select='1'/>
|
||||
<field name="partner_id" select="1"/>
|
||||
<field name="user_id" select="1" widget="selection"/>
|
||||
</group>
|
||||
<field name="name" select='1'/>
|
||||
<field name="partner_id" select="1"/>
|
||||
<field name="user_id" select="1" widget="selection"/>
|
||||
<field name="section_id" select="1" widget="selection" string="Section" default="context.get('section_id', False)">
|
||||
<filter icon="terp-crm"
|
||||
domain="[('section_id','=',context.get('section_id',False))]"
|
||||
help="My section"
|
||||
/>
|
||||
</field>
|
||||
<group expand="1" string="Group By..." colspan="4" col="20">
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="10" col="20">
|
||||
<filter string="Deadline" icon="terp-crm" domain="[]" context="{'group_by':'date_deadline'}"/>
|
||||
<filter string="Closure" icon="terp-crm" domain="[]" context="{'group_by':'date_closed'}"/>
|
||||
</group>
|
||||
|
||||
@@ -160,34 +160,31 @@
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search Helpdesk">
|
||||
<group col="6" colspan="1">
|
||||
<filter icon="gtk-home" string="Today"
|
||||
separator="1"
|
||||
domain="[('date::date','=',time.strftime('%%Y-%%m-%%d'))]"
|
||||
help="Todays's Helpdesk Requests"
|
||||
/>
|
||||
<filter icon="gtk-media-rewind"
|
||||
string="7 Days" separator="1"
|
||||
help="Helpdesk requests during last 7 days"
|
||||
domain="[('date','<', time.strftime('%%Y-%%m-%%d')), ('date','>=',(datetime.date.today()-datetime.timedelta(days=7)).strftime('%%Y-%%m-%%d'))]"
|
||||
/>
|
||||
</group>
|
||||
<filter icon="gtk-home" string="Today"
|
||||
separator="1"
|
||||
domain="[('date::date','=',time.strftime('%%Y-%%m-%%d'))]"
|
||||
help="Todays's Helpdesk Requests"
|
||||
/>
|
||||
<filter icon="gtk-media-rewind"
|
||||
string="7 Days" separator="1"
|
||||
help="Helpdesk requests during last 7 days"
|
||||
domain="[('date','<', time.strftime('%%Y-%%m-%%d')), ('date','>=',(datetime.date.today()-datetime.timedelta(days=7)).strftime('%%Y-%%m-%%d'))]"
|
||||
/>
|
||||
<separator orientation="vertical"/>
|
||||
<group col="6" colspan="2">
|
||||
<field name="name" select='1' string="Query"/>
|
||||
<field name="user_id" select="1" widget="selection">
|
||||
<filter icon="terp-partner" domain="[('user_id','=',uid)]" help="My Helpdesk Requests" default="1"/>
|
||||
</field>
|
||||
<field name="state" select="1">
|
||||
<filter icon="gtk-index" domain="[('state','in',('open','draft' ))]" help="Current " default="1"/>
|
||||
</field>
|
||||
<field name="section_id" default="context.get('section_id', False)" select="1" widget="selection" string="Section">
|
||||
<filter icon="terp-crm"
|
||||
domain="[('section_id','=',context.get('section_id',False))]"
|
||||
help="My section"/>
|
||||
</field>
|
||||
</group>
|
||||
<group expand="1" string="Group By..." colspan="4" col="20">
|
||||
<field name="name" select='1' string="Query"/>
|
||||
<field name="user_id" select="1" widget="selection">
|
||||
<filter icon="terp-partner" domain="[('user_id','=',uid)]" help="My Helpdesk Requests" default="1"/>
|
||||
</field>
|
||||
<field name="state" select="1">
|
||||
<filter icon="gtk-index" domain="[('state','in',('open','draft' ))]" help="Current " default="1"/>
|
||||
</field>
|
||||
<field name="section_id" default="context.get('section_id', False)" select="1" widget="selection" string="Section">
|
||||
<filter icon="terp-crm"
|
||||
domain="[('section_id','=',context.get('section_id',False))]"
|
||||
help="My section"/>
|
||||
</field>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="12" col="20">
|
||||
<filter string="Customer" icon="terp-crm" domain="[]" context="{'group_by':'partner_id'}"/>
|
||||
<filter string="State" icon="terp-crm" domain="[]" context="{'group_by':'state'}"/>
|
||||
<filter string="Priority" icon="terp-crm" domain="[]" context="{'group_by':'priority'}"/>
|
||||
|
||||
+6
-11
@@ -25,27 +25,22 @@ import crm
|
||||
class crm_lead(osv.osv):
|
||||
_name = "crm.lead"
|
||||
_description = "Leads Cases"
|
||||
_order = "id desc"
|
||||
_order = "priority desc, id desc"
|
||||
_inherit = ['res.partner.address','crm.case']
|
||||
_columns = {
|
||||
'categ_id': fields.many2one('crm.case.categ', 'Category', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.opportunity')]"),
|
||||
'type_id': fields.many2one('crm.case.resource.type', 'Lead Type Name', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.lead')]"),
|
||||
'categ_id': fields.many2one('crm.case.categ', 'Lead Source', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.opportunity')]"),
|
||||
'type_id': fields.many2one('crm.case.resource.type', 'Lead Type', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.lead')]"),
|
||||
'partner_name': fields.char("Lead Name", size=64),
|
||||
|
||||
'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority'),
|
||||
'probability': fields.float('Probability (%)'),
|
||||
'date_closed': fields.datetime('Closed', readonly=True),
|
||||
'ref' : fields.reference('Reference', selection=crm._links_get, size=128),
|
||||
'ref2' : fields.reference('Reference 2', selection=crm._links_get, size=128),
|
||||
'canal_id': fields.many2one('res.partner.canal', 'Channel',help="The channels represent the different communication modes available with the customer." \
|
||||
" With each commercial opportunity, you can indicate the canall which is this opportunity source."),
|
||||
'stage_id': fields.many2one('crm.case.stage', 'Stage', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.lead')]"),
|
||||
'som': fields.many2one('res.partner.som', 'State of Mind', help="The minds states allow to define a value scale which represents" \
|
||||
"the partner mentality in relation to our services.The scale has" \
|
||||
"to be created with a factor for each level from 0 (Very dissatisfied) to 10 (Extremely satisfied)."),
|
||||
'opportunity_id': fields.many2one('crm.opportunity', 'Opportunity'),
|
||||
|
||||
'user_id': fields.many2one('res.users', 'Salesman'),
|
||||
'referred': fields.char('Referred By', size=32),
|
||||
}
|
||||
_defaults = {
|
||||
'company_id': lambda s,cr,uid,c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.lead', context=c),
|
||||
}
|
||||
crm_lead()
|
||||
|
||||
@@ -8,111 +8,111 @@
|
||||
<!--For Leads-->
|
||||
<record id="crm_case_itisatelesalescampaign0" model="crm.lead">
|
||||
<field name="type_id" ref="crm.type_lead1"/>
|
||||
<field eval=""3"" name="priority"/>
|
||||
<field eval="'3'" name="priority"/>
|
||||
<field name="user_id" ref="base.user_root"/>
|
||||
<field eval=""Exhibition ERP 2009"" name="name"/>
|
||||
<field eval=""open"" name="state"/>
|
||||
<field eval="'Luc Latour'" name="name"/>
|
||||
<field eval="'open'" name="state"/>
|
||||
<field name="section_id" ref="crm.section_sales_department"/>
|
||||
<field eval=""Michel Lafont"" name="partner_name2"/>
|
||||
<field eval=""(726) 782-0636"" name="partner_mobile"/>
|
||||
<field eval="'Michel Lafont'" name="partner_name2"/>
|
||||
<field eval="'(726) 782-0636'" name="partner_mobile"/>
|
||||
<field eval="1" name="active"/>
|
||||
<field name="categ_id" ref="crm.categ_oppor6"/>
|
||||
<field name="stage_id" ref="crm.stage_lead1"/>
|
||||
<field eval=""The Oil Company"" name="partner_name"/>
|
||||
<field eval=""(769) 703-274"" name="partner_phone"/>
|
||||
<field eval="'The Oil Company'" name="partner_name"/>
|
||||
<field eval="'(769) 703-274'" name="partner_phone"/>
|
||||
</record>
|
||||
<record id="crm_case_electonicgoodsdealer0" model="crm.lead">
|
||||
<field name="type_id" ref="crm.type_lead7"/>
|
||||
<field eval=""4"" name="priority"/>
|
||||
<field eval="'4'" name="priority"/>
|
||||
<field name="user_id" ref="base.user_root"/>
|
||||
<field eval=""Exhibition ERP 2009"" name="name"/>
|
||||
<field eval=""open"" name="state"/>
|
||||
<field eval="'Marc Dufour'" name="name"/>
|
||||
<field eval="'open'" name="state"/>
|
||||
<field name="section_id" ref="crm.section_sales_department"/>
|
||||
<field eval=""Luc Latour"" name="partner_name2"/>
|
||||
<field eval=""(392) 895-7917"" name="partner_mobile"/>
|
||||
<field eval="'Luc Latour'" name="partner_name2"/>
|
||||
<field eval="'(392) 895-7917'" name="partner_mobile"/>
|
||||
<field eval="1" name="active"/>
|
||||
<field name="categ_id" ref="crm.categ_oppor2"/>
|
||||
<field name="stage_id" ref="crm.stage_lead2"/>
|
||||
<field eval=""Le Club SARL"" name="partner_name"/>
|
||||
<field eval=""(956) 293-2595"" name="partner_phone"/>
|
||||
<field eval="'Le Club SARL'" name="partner_name"/>
|
||||
<field eval="'(956) 293-2595'" name="partner_phone"/>
|
||||
</record>
|
||||
<record id="crm_case_developingwebapplications0" model="crm.lead">
|
||||
<field name="type_id" ref="crm.type_lead5"/>
|
||||
<field eval=""2"" name="priority"/>
|
||||
<field eval="'2'" name="priority"/>
|
||||
<field name="user_id" ref="base.user_demo"/>
|
||||
<field eval=""Exhibition ERP 2009"" name="name"/>
|
||||
<field eval=""done"" name="state"/>
|
||||
<field eval="'Fabien Pinckaers'" name="name"/>
|
||||
<field eval="'done'" name="state"/>
|
||||
<field name="section_id" ref="crm.section_sales_department"/>
|
||||
<field eval=""Mike Gardner"" name="partner_name2"/>
|
||||
<field eval=""(820) 167-3208"" name="partner_mobile"/>
|
||||
<field eval="'Mike Gardner'" name="partner_name2"/>
|
||||
<field eval="'(820) 167-3208'" name="partner_mobile"/>
|
||||
<field eval="1" name="active"/>
|
||||
<field name="categ_id" ref="crm.categ_oppor4"/>
|
||||
<field name="stage_id" ref="crm.stage_lead4"/>
|
||||
<field eval=""TheKompany"" name="partner_name"/>
|
||||
<field eval=""(079) 681-2139"" name="partner_phone"/>
|
||||
<field eval=""contact@tecsas.fr"" name="email_from"/>
|
||||
<field eval="'TheKompany'" name="partner_name"/>
|
||||
<field eval="'(079) 681-2139'" name="partner_phone"/>
|
||||
<field eval="'contact@tecsas.fr'" name="email_from"/>
|
||||
</record>
|
||||
<record id="crm_case_qrecorp0" model="crm.lead">
|
||||
<field name="type_id" ref="crm.type_lead8"/>
|
||||
<field eval=""3"" name="priority"/>
|
||||
<field eval="'3'" name="priority"/>
|
||||
<field name="user_id" ref="base.user_root"/>
|
||||
<field eval=""Exhibition ERP 2009"" name="name"/>
|
||||
<field eval=""draft"" name="state"/>
|
||||
<field eval="'Henry Mc Coy'" name="name"/>
|
||||
<field eval="'draft'" name="state"/>
|
||||
<field name="section_id" ref="crm.section_sales_department"/>
|
||||
<field eval=""(077) 582-4035"" name="partner_mobile"/>
|
||||
<field eval="'(077) 582-4035'" name="partner_mobile"/>
|
||||
<field eval="1" name="active"/>
|
||||
<field name="categ_id" ref="crm.categ_oppor1"/>
|
||||
<field name="stage_id" ref="crm.stage_lead1"/>
|
||||
<field eval=""The Gas Company"" name="partner_name"/>
|
||||
<field eval=""(514) 698-4118"" name="partner_phone"/>
|
||||
<field eval="'The Gas Company'" name="partner_name"/>
|
||||
<field eval="'(514) 698-4118'" name="partner_phone"/>
|
||||
</record>
|
||||
<record id="crm_case_itdeveloper0" model="crm.lead">
|
||||
<field name="type_id" ref="crm.type_lead4"/>
|
||||
<field eval=""3"" name="priority"/>
|
||||
<field eval="'3'" name="priority"/>
|
||||
<field name="user_id" ref="base.user_root"/>
|
||||
<field eval=""Carrie Helle"" name="name"/>
|
||||
<field eval=""pending"" name="state"/>
|
||||
<field eval="'Carrie Helle'" name="name"/>
|
||||
<field eval="'pending'" name="state"/>
|
||||
<field name="section_id" ref="crm.section_sales_department"/>
|
||||
<field eval=""Sam Stone"" name="partner_name2"/>
|
||||
<field eval=""(333) 715-1450"" name="partner_mobile"/>
|
||||
<field eval="'Sam Stone'" name="partner_name2"/>
|
||||
<field eval="'(333) 715-1450'" name="partner_mobile"/>
|
||||
<field eval="1" name="active"/>
|
||||
<field name="categ_id" ref="crm.categ_oppor6"/>
|
||||
<field name="stage_id" ref="crm.stage_lead3"/>
|
||||
<field eval=""Stonage IT"" name="partner_name"/>
|
||||
<field eval=""(855) 924-4364"" name="partner_phone"/>
|
||||
<field eval="'Stonage IT'" name="partner_name"/>
|
||||
<field eval="'(855) 924-4364'" name="partner_phone"/>
|
||||
</record>
|
||||
<record id="crm_case_mgroperations0" model="crm.lead">
|
||||
<field name="partner_address_id" ref="base.res_partner_address_1"/>
|
||||
<field eval="1" name="active"/>
|
||||
<field name="type_id" ref="crm.type_lead3"/>
|
||||
<field name="partner_id" ref="base.res_partner_9"/>
|
||||
<field eval=""3"" name="priority"/>
|
||||
<field eval="'3'" name="priority"/>
|
||||
<field name="user_id" ref="base.user_root"/>
|
||||
<field eval=""Tina Pinero"" name="name"/>
|
||||
<field eval=""cancel"" name="state"/>
|
||||
<field eval="'Tina Pinero'" name="name"/>
|
||||
<field eval="'cancel'" name="state"/>
|
||||
<field name="section_id" ref="crm.section_sales_department"/>
|
||||
<field eval=""Benoit Mortier"" name="partner_name2"/>
|
||||
<field eval=""(468) 017-2684"" name="partner_mobile"/>
|
||||
<field eval="'Benoit Mortier'" name="partner_name2"/>
|
||||
<field eval="'(468) 017-2684'" name="partner_mobile"/>
|
||||
<field name="categ_id" ref="crm.categ_oppor8"/>
|
||||
<field name="stage_id" ref="crm.stage_lead6"/>
|
||||
<field eval=""Opensides SPRL"" name="partner_name"/>
|
||||
<field eval=""(373) 907-1009"" name="partner_phone"/>
|
||||
<field eval=""info@opensides.be"" name="email_from"/>
|
||||
<field eval="'Opensides SPRL'" name="partner_name"/>
|
||||
<field eval="'(373) 907-1009'" name="partner_phone"/>
|
||||
<field eval="'info@opensides.be'" name="email_from"/>
|
||||
</record>
|
||||
<record id="crm_case_vpoperations0" model="crm.lead">
|
||||
<field eval="1" name="active"/>
|
||||
<field name="type_id" ref="crm.type_lead8"/>
|
||||
<field eval=""3"" name="priority"/>
|
||||
<field eval="'3'" name="priority"/>
|
||||
<field name="user_id" ref="base.user_root"/>
|
||||
<field eval=""Wendi Baltz"" name="name"/>
|
||||
<field eval=""done"" name="state"/>
|
||||
<field eval="'Wendi Baltz'" name="name"/>
|
||||
<field eval="'done'" name="state"/>
|
||||
<field name="section_id" ref="crm.section_sales_department"/>
|
||||
<field eval=""Will Smith"" name="partner_name2"/>
|
||||
<field eval=""(463) 014-1208"" name="partner_mobile"/>
|
||||
<field eval="'Will Smith'" name="partner_name2"/>
|
||||
<field eval="'(463) 014-1208'" name="partner_mobile"/>
|
||||
<field name="categ_id" ref="crm.categ_oppor4"/>
|
||||
<field name="stage_id" ref="crm.stage_lead4"/>
|
||||
<field eval=""Gardner Group"" name="partner_name"/>
|
||||
<field eval=""(282) 603-7489"" name="partner_phone"/>
|
||||
<field eval="'Gardner Group'" name="partner_name"/>
|
||||
<field eval="'(282) 603-7489'" name="partner_phone"/>
|
||||
</record>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
+105
-52
@@ -27,45 +27,59 @@
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Leads Form">
|
||||
<group colspan="4" col="7">
|
||||
<field name="partner_name" string="Partner Name" required="1"/>
|
||||
<field name="partner_contact"/>
|
||||
<group colspan="4" col="6">
|
||||
<field name="partner_name" required="1"/>
|
||||
<field name="priority" required="1"/>
|
||||
<field name="date_deadline"/>
|
||||
|
||||
<newline/>
|
||||
<field name="section_id" colspan="1" widget="selection"/>
|
||||
<field name="user_id"/>
|
||||
<button
|
||||
string="Convert to Opportunity"
|
||||
name="%(wizard_crm_lead_opportunity_set)d"
|
||||
icon="gtk-index"
|
||||
type="action"/>
|
||||
<field name="name"/>
|
||||
<field name="email_from"/>
|
||||
<field name="partner_phone"/>
|
||||
<button string="Convert to Partner"
|
||||
icon="terp-partner" name="%(wizard_crm_lead_partner_create)d"
|
||||
type="action" attrs="{'invisible':[('partner_id','!=',False)]}"
|
||||
/>
|
||||
<field name="stage_id" widget="selection" domain="[('object_id.model', '=', 'crm.lead')]"/>
|
||||
|
||||
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Leads">
|
||||
<separator colspan="4" string="Communication"/>
|
||||
<field name="partner_id" string="Partner"
|
||||
on_change="onchange_partner_id(partner_id)" />
|
||||
<field name="partner_address_id"
|
||||
string="Contact"
|
||||
on_change="onchange_partner_address_id(partner_address_id, email_from)" />
|
||||
<field name="partner_phone"/>
|
||||
<field name="partner_mobile"/>
|
||||
<separator colspan="4" string="Status and Categorization"/>
|
||||
<group colspan="4" col="6">
|
||||
<field name="stage_id" widget="selection" domain="[('object_id.model', '=', 'crm.lead')]"/>
|
||||
<field name="categ_id"
|
||||
string="Lead Source" widget="selection"
|
||||
domain="[('object_id.model', '=', 'crm.opportunity')]" />
|
||||
<field name="type_id" string="Campaign" select="1"/>
|
||||
<field name="section_id" colspan="1" widget="selection"/>
|
||||
<field name="priority" string="Priority"/>
|
||||
<field name="create_date"/>
|
||||
<page string="Lead">
|
||||
<group colspan="2" col="4">
|
||||
<separator string="Contact" colspan="4" col="4"/>
|
||||
<field name="name" string="Contact Name" colspan="4"/>
|
||||
<newline/>
|
||||
<field domain="[('domain', '=', 'contact')]" name="title"/>
|
||||
<field name="function"/>
|
||||
<field name="street" colspan="4"/>
|
||||
<field name="street2" colspan="4"/>
|
||||
<field name="zip"/>
|
||||
<field name="city"/>
|
||||
<field name="country_id"/>
|
||||
<field name="state_id"/>
|
||||
</group>
|
||||
<separator colspan="4" string="Details"/>
|
||||
<group colspan="2" col="3">
|
||||
<separator string="Communication" colspan="4" col="3"/>
|
||||
<field name="phone"/>
|
||||
<newline/>
|
||||
<field name="fax"/>
|
||||
<newline/>
|
||||
<field name="mobile"/>
|
||||
<newline/>
|
||||
<field name="email_from" widget="email"/>
|
||||
<newline/>
|
||||
<separator string="Links" colspan="4" col="3"/>
|
||||
<field name="partner_id"/>
|
||||
<button
|
||||
name="%(wizard_crm_lead_partner_create)d"
|
||||
icon="gtk-index" type="action"
|
||||
string="Create"
|
||||
attrs="{'invisible':[('partner_id','!=',False)]}"/>
|
||||
<field name="opportunity_id"/>
|
||||
<button
|
||||
name="%(wizard_crm_lead_opportunity_set)d"
|
||||
string="Convert"
|
||||
icon="gtk-index"
|
||||
type="action"
|
||||
attrs="{'invisible':[('opportunity_id','!=',False)]}"/>
|
||||
</group>
|
||||
<separator colspan="4" string="Notes"/>
|
||||
<field name="description" nolabel="1" colspan="4"/>
|
||||
<separator colspan="4"/>
|
||||
<group col="8" colspan="4">
|
||||
@@ -108,6 +122,23 @@
|
||||
context="{'mail':'new'}" icon="gtk-go-forward"
|
||||
type="action" />
|
||||
</page>
|
||||
<page string="Extra Info" groups="base.group_extended">
|
||||
<group colspan="2" col="2">
|
||||
<separator string="Categories" colspan="2" col="2"/>
|
||||
<field name="company_id" groups="base.group_multi_company" widget="selection" colspan="2"/>
|
||||
<field name="categ_id"
|
||||
widget="selection"
|
||||
domain="[('object_id.model', '=', 'crm.opportunity')]" />
|
||||
<field name="type_id" string="Campaign" select="1"/>
|
||||
<field name="referred"/>
|
||||
</group>
|
||||
<group colspan="2" col="2">
|
||||
<separator string="Dates" colspan="2" col="2"/>
|
||||
<field name="create_date"/>
|
||||
<field name="write_date"/>
|
||||
<field name="date_closed"/>
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
</field>
|
||||
@@ -121,12 +152,18 @@
|
||||
<tree string="Leads Tree" colors="blue:state=='pending';grey:state in ('cancel', 'done')">
|
||||
<field name="create_date"/>
|
||||
<field name="partner_name"/>
|
||||
<field name="partner_contact"/>
|
||||
<field name="name"/>
|
||||
<field name="email_from"/>
|
||||
<field name="partner_phone"/>
|
||||
<field name="phone"/>
|
||||
|
||||
<field name="categ_id" invisible="1"/>
|
||||
<field name="type_id" invisible="1"/>
|
||||
<field name="referred" invisible="1"/>
|
||||
|
||||
<field name="stage_id"/>
|
||||
<button name="stage_previous" string="Previous" states="open,pending" type="object" icon="gtk-go-back"/>
|
||||
<button name="stage_next" string="Next" states="open,pending" type="object" icon="gtk-go-forward"/>
|
||||
<field name="section_id"/>
|
||||
<field name="section_id" invisible="context.get('invisible_section', True)"/>
|
||||
<field name="user_id"/>
|
||||
<field name="state"/>
|
||||
<button name="case_open" string="Open" states="draft,pending" type="object" icon="gtk-go-forward"/>
|
||||
@@ -157,6 +194,18 @@
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search Leads">
|
||||
<filter icon="terp-project"
|
||||
string="Current"
|
||||
default="1"
|
||||
domain="[('state','in',('draft','open'))]"/>
|
||||
<filter icon="terp-project"
|
||||
string="Open"
|
||||
domain="[('state','=','open')]"/>
|
||||
<filter icon="terp-project"
|
||||
string="Pending"
|
||||
domain="[('state','=','pending')]"/>
|
||||
|
||||
<separator orientation="vertical"/>
|
||||
<filter icon="gtk-home" string="Today"
|
||||
domain="[('create_date','<', time.strftime('%%Y-%%m-%%d 23:59:59')), ('create_date','>=', time.strftime('%%Y-%%m-%%d 23:59:59'))]"
|
||||
help="Todays' Opportunities"
|
||||
@@ -166,33 +215,37 @@
|
||||
domain="[('create_date','<', time.strftime('%%Y-%%m-%%d')), ('create_date','>=',(datetime.date.today()-datetime.timedelta(days=7)).strftime('%%Y-%%m-%%d'))]"
|
||||
/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="name" string="Opportunity"/>
|
||||
<field name="partner_name"/>
|
||||
<field name="email_from"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<filter icon="terp-partner"
|
||||
domain="[('user_id','=',uid)]"
|
||||
help="My Opportunities" default="1"
|
||||
help="My Leads" default="1"
|
||||
/>
|
||||
</field>
|
||||
<field name="partner_id"/>
|
||||
<field name="state">
|
||||
<filter icon="gtk-media-rewind"
|
||||
string="New and open opportunities"
|
||||
default="1"
|
||||
domain="[('state','in',('draft','open'))]"/>
|
||||
</field>
|
||||
<field name="section_id" default="context.get('section_id', False)" select="1" widget="selection" string="Section">
|
||||
<field name="section_id" default="context.get('section_id', False)" widget="selection"
|
||||
context="{'invisible_section': False}">
|
||||
<filter icon="terp-crm"
|
||||
domain="[('section_id','=',context.get('section_id',False))]"
|
||||
context="{'invisible_section': False}"
|
||||
domain="[('section_id.user_id','=',uid)]"
|
||||
help="My section"/>
|
||||
<filter icon="terp-crm"
|
||||
context="{'invisible_section': False}"
|
||||
domain="[]"
|
||||
help="Show Sections"/>
|
||||
</field>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="4">
|
||||
<group expand="1" string="Group By..." colspan="14">
|
||||
<filter string="Stage" icon="terp-crm" domain="[]" context="{'group_by':'stage_id'}"/>
|
||||
<filter string="Partner" icon="terp-crm" domain="[]" context="{'group_by':'partner_id'}"/>
|
||||
<filter string="State" icon="terp-crm" domain="[]" context="{'group_by':'state'}"/>
|
||||
<filter string="Source" icon="terp-crm" domain="[]" context="{'group_by':'categ_id'}"/>
|
||||
<filter string="Type" icon="terp-crm" domain="[]" context="{'group_by':'type'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Team" icon="terp-crm" domain="[]" context="{'group_by':'section_id'}"/>
|
||||
<filter string="Salesman" icon="terp-crm" domain="[]" context="{'group_by':'user_id'}"/>
|
||||
<filter string="Referrer" icon="terp-crm" domain="[]" context="{'group_by':'referred'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Creation" icon="terp-project" domain="[]" context="{'group_by':'create_date'}"/>
|
||||
<filter string="Exp.Closing" icon="terp-project" domain="[]" context="{'group_by':'date_deadline'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
|
||||
@@ -60,5 +60,9 @@ class crm_opportunity(osv.osv):
|
||||
return {'value':{}}
|
||||
return {'value':{'probability':stage.probability}}
|
||||
|
||||
_defaults = {
|
||||
'company_id': lambda s,cr,uid,c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.opportunity', context=c),
|
||||
}
|
||||
|
||||
crm_opportunity()
|
||||
|
||||
|
||||
@@ -206,7 +206,7 @@
|
||||
default="1"
|
||||
domain="[('state','in',('draft','open'))]"/>
|
||||
</field>
|
||||
<field name="section_id" default="context.get('section_id', False)" select="1" widget="selection" string="Section">
|
||||
<field name="section_id" default="context.get('section_id', False)" select="1" widget="selection">
|
||||
<filter icon="terp-crm"
|
||||
domain="[('section_id','=',context.get('section_id',False))]"
|
||||
help="My section"/>
|
||||
|
||||
@@ -40,5 +40,8 @@ class crm_phonecall(osv.osv):
|
||||
'date': fields.datetime('Date'),
|
||||
'opportunity_id':fields.many2one ('crm.opportunity', 'Opportunity'),
|
||||
}
|
||||
_defaults = {
|
||||
'date': lambda *a: time.strftime('%Y-%m-%d')
|
||||
}
|
||||
crm_phonecall()
|
||||
|
||||
|
||||
@@ -404,7 +404,7 @@
|
||||
<field name="arch" type="xml">
|
||||
<search string="Task Edition">
|
||||
<group col="20" colspan="4">
|
||||
<filter string="Current" domain="[('state','in',('open','draft'))]" help="Draft, Open and Pending Tasks" icon="terp-project" default="1"/>
|
||||
<filter string="Current" domain="[('state','in',('open','draft'))]" help="Draft and Open Tasks" icon="terp-project" default="1"/>
|
||||
<filter string="In Progress" domain="[('state','=','open')]" help="Open Tasks" icon="terp-project"/>
|
||||
<filter string="Pending" domain="[('state','=','pending')]" context="{'show_delegated':False}" help="Pending Tasks" icon="terp-project"/>
|
||||
<separator orientation="vertical"/>
|
||||
|
||||
Reference in New Issue
Block a user