123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196 |
- <?xml version="1.0" encoding="utf-8"?>
- <openerp>
- <data>
- <record model="ir.ui.view" id="crm_case_form_view_oppor2">
- <field name="name">crm_case_form_view_oppor2</field>
- <field name="model">crm.lead</field>
- <field name="inherit_id" ref="crm.crm_case_form_view_oppor"/>
- <field name="arch" type="xml">
- <form string="Opportunities" position="replace">
- <form string="Opportunities">
- <header>
- <button name="case_mark_won" string="Mark Won" attrs="{'invisible': [('probability', '=', 100)]}" type="object" class="oe_highlight"/>
- <button name="case_mark_lost" string="Mark Lost" attrs="{'invisible': [('probability', '=', 100)]}" type="object" class="oe_highlight"/>
- <button string="Convert to Quotation" name="534" type="action" class="oe_highlight"/>
- <field name="stage_id" widget="statusbar" clickable="True"
- options="{'fold_field': 'fold'}"
- domain="['&', ('section_ids', '=', section_id), ('type2', '=', 'opportunity')]"/>
- </header>
- <sheet>
- <div class="oe_right oe_button_box">
- <button name="open_wizard" type="object" string="Añadir Tarea"
- class="oe_inline oe_stat_button" icon="fa-calendar"/>
- </div>
- <div class="oe_title">
- <label for="name" class="oe_edit_only"/>
- <h1><field name="name"/></h1>
- <label for="planned_revenue" class="oe_edit_only"/>
- <h2>
- <field name="company_currency" invisible="1"/>
- <field name="planned_revenue" class="oe_inline" widget='monetary' options="{'currency_field': 'company_currency'}"/>
- <span class="oe_grey"> at </span>
- <field name="probability" class="oe_inline" widget="integer"/>%%
- </h2>
- </div>
- <group>
- <group>
- <field name="partner_id"
- required='True'
- on_change="on_change_partner_id(partner_id)"
- string="Customer"
- context="{'default_name': partner_name,
- 'default_email': email_from,
- 'default_mobile': mobile,
- 'default_facebook': facebook,
- 'default_instagram': instagram
- }"/>
- <field name="partner_name" string="Company Name" invisible="1"/>
- <field name="email_from" string="Email" widget="email"/>
- <field name="mobile"/>
- <field name="phone"/>
- <field name="facebook" widget="url" />
- <field name="instagram" widget="url"/>
- </group>
- <group name="new_group">
- <field name="date_deadline"/>
- <field name="priority" widget="priority"/>
- </group>
- <group>
- <field name="user_id" string="Responsable" on_change="on_change_user(user_id, context)" context="{'default_groups_ref': ['base.group_user', 'base.group_partner_manager', 'base.group_sale_salesman_all_leads']}"/>
- <label for="section_id" groups="base.group_multi_salesteams"/>
- <div groups="base.group_multi_salesteams">
- <field name="section_id" widget="selection"/>
- <button name="case_escalate" string="Escalate" type="object" class="oe_link"
- attrs="{'invisible': ['|', ('section_id','=',False), ('probability', '=', 100)]}"/>
- </div>
- </group>
- <group>
- <field name="categ_ids"
- widget="many2many_tags"
- context="{'object_name': 'crm.lead'}"
- domain="[('object_id.model', '=', 'crm.lead')]"/>
- </group>
- </group>
- <notebook colspan="4">
- <page string="Internal Notes">
- <field name="description"/>
- </page>
- <page string="Historial de Tareas">
- <field name="task_ids" widget="many2one_clickable">
- <tree create="false" colors="red:expired_date == True and state == 'pending';gray:state == 'cancel';green:state == 'pending'">
- <field name="task_type_id"/>
- <field name="name"/>
- <field name="user_id" required="True"/>
- <field name="date_action_next"/>
- <field name="state"/>
- <field name="expired_date" invisible="1"/>
- <field name="description"/>
- <button name="action_done" string="Realizado" type="object" icon="gtk-apply" attrs="{'invisible':[('state','=','done')]}"/>
- <button name="action_done" string="Pendiente" type="object" icon="gtk-undo" attrs="{'invisible':[('state','=','pending')]}"/>
- <button name="action_cancel" string="Cancelado" type="object" icon="gtk-cancel" attrs="{'invisible':[('state','=','cancel')]}"/>
- </tree>
- </field>
- </page>
- <page string="Extra Info">
- <group string="Mailings" name="mailings">
- <field name="opt_out"/>
- <field name="message_bounce"/>
- </group>
- </page>
- </notebook>
- </sheet>
- <div class="oe_chatter">
- <field name="message_follower_ids" widget="mail_followers"/>
- <field name="message_ids" widget="mail_thread"/>
- </div>
- </form>
- </form>
- </field>
- </record>
- <record id="crm_task_kanban" model="ir.ui.view">
- <field name="name">crm_task_kanban</field>
- <field name="model">crm.lead</field>
- <field name="inherit_id" ref="crm.crm_case_kanban_view_leads"/>
- <field name="arch" type="xml">
- <templates position="replace">
- <templates>
- <field name="exist_task"/>
- <field name="expired_date"/>
- <t t-name="kanban-box">
- <div t-attf-class="oe_kanban_color_#{kanban_getcolor(record.color.raw_value)} oe_kanban_card oe_kanban_global_click">
- <div class="oe_dropdown_toggle oe_dropdown_kanban">
- <span class="oe_e">í</span>
- <ul class="oe_dropdown_menu">
- <t t-if="widget.view.is_action_enabled('edit')"><li><a type="edit">Edit...</a></li></t>
- <t t-if="widget.view.is_action_enabled('delete')"><li><a type="delete">Delete</a></li></t>
- <li><a name="%(mail.action_email_compose_message_wizard)d" type="action">Send Email</a></li>
- <li><a type="object" name="open_wizard">Añadir Tarea</a></li>
- <li><ul class="oe_kanban_colorpicker" data-field="color"/></li>
- </ul>
- </div>
- <div class="oe_kanban_content">
- <div>
- <b><field name="name"/></b>
- <t t-if="record.planned_revenue.raw_value">
- - <b><t t-esc="record.planned_revenue.value"/>
- <field name="company_currency"/></b>
- </t>
- </div>
- <div>
- <field name="partner_id"/>
- </div>
- <div class="oe_kanban_bottom_right">
- <t t-if="record.exist_task.raw_value">
- <a type="action" name="%(eiru_crm.action_tree_wizard)d">
- <img src="/eiru_crm/static/images/green_button.png" style="width:18px; height:18px;"/>
- </a>
- </t>
- <t t-if="record.expired_date.raw_value">
- <a type="action" name="%(eiru_crm.action_tree_wizard)d">
- <img src="/eiru_crm/static/images/red_button.png" style="width:18px; height:18px;"/>
- </a>
- </t>
- </div>
- <div class="oe_kanban_bottom_left">
- <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar pull-left"/>
- <div class="pull-left" groups="base.group_user">
- <field name="priority" widget="priority"/>
- </div>
- </div>
- <div class="oe_kanban_footer_left">
- <t t-raw="record.message_summary.raw_value"/>
- </div>
- </div>
- <div class="oe_clear"></div>
- </div>
- </t>
- </templates>
- </templates>
- </field>
- </record>
- <record model="ir.ui.view" id="inherit_opportunity_tree_view">
- <field name="name">Opportunities Tree</field>
- <field name="model">crm.lead</field>
- <field name="inherit_id" ref="crm.crm_case_tree_view_oppor"/>
- <field name="arch" type="xml">
- <field name="country_id" position="replace">
- <field name="country_id" invisible="1"/>
- </field>
- <field name="date_action" position="replace">
- <field name="date_action" invisible="1"/>
- </field>
- <field name="title_action" position="replace">
- <field name="title_action" invisible="1"/>
- </field>
- </field>
- </record>
- </data>
- </openerp>
|