1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
|
<?xml version="1.0" encoding="utf-8"?>
<odoo><data>
<record id="crm_team_salesteams_search" model="ir.ui.view">
<field name="name">Sales Teams - Search</field>
<field name="model">crm.team</field>
<field name="arch" type="xml">
<search string="Salesteams Search">
<filter string="Archived" name="inactive" domain="[('active','=',False)]"/>
<field name="name"/>
<field name="user_id"/>
<group expand="0" string="Group By...">
<filter string="Team Leader" name="team_leader" domain="[]" context="{'group_by':'user_id'}"/>
</group>
</search>
</field>
</record>
<record id="crm_team_view_form" model="ir.ui.view">
<field name="name">crm.team.form</field>
<field name="model">crm.team</field>
<field name="arch" type="xml">
<form string="Sales Team">
<sheet>
<div class="oe_button_box" name="button_box"/>
<widget name="web_ribbon" title="Archived" bg_color="bg-danger" attrs="{'invisible': [('active', '=', True)]}"/>
<div class="oe_title">
<label for="name" class="oe_edit_only" string="Sales Team"/>
<h1>
<field name="name" placeholder="Sales Team name..."/>
</h1>
<div name="options_active" />
</div>
<group>
<group name="left">
<field name="active" invisible="1"/>
<field name="user_id" domain="[('share', '=', False)]"/>
<field name="company_id" options="{'no_create': True}" groups="base.group_multi_company"/>
<field name="currency_id" invisible="1"/>
</group>
<group name="right">
</group>
</group>
<notebook>
<page name="members" string="Team Members" >
<field name="member_ids" widget="many2many" options="{'not_delete': True}">
<kanban quick_create="false" create="true" delete="true">
<field name="id"/>
<field name="name"/>
<templates>
<t t-name="kanban-box">
<div class="oe_kanban_global_click" style="max-width: 200px">
<div class="o_kanban_record_top">
<img t-att-src="kanban_image('res.users', 'image_128', record.id.raw_value)" class="oe_avatar oe_kanban_avatar_smallbox o_image_40_cover mb0" alt="Avatar"/>
<div class="o_kanban_record_headings ml8">
<strong class="o_kanban_record_title"><field name="name"/></strong>
</div>
</div>
</div>
</t>
</templates>
</kanban>
</field>
</page>
</notebook>
</sheet>
<div class="oe_chatter">
<field name="message_follower_ids" help="Follow this salesteam to automatically track the events associated to users of this team."/>
<field name="message_ids"/>
</div>
</form>
</field>
</record>
<!-- SALES TEAMS TREE VIEW + MUTI_EDIT -->
<record id="crm_team_view_tree" model="ir.ui.view">
<field name="name">crm.team.tree</field>
<field name="model">crm.team</field>
<field name="field_parent">child_ids</field>
<field name="arch" type="xml">
<tree string="Sales Team" sample="1" multi_edit="1">
<field name="sequence" widget="handle"/>
<field name="name" readonly="1"/>
<field name="active" invisible="1"/>
<field name="user_id" domain="[('share', '=', False)]"/>
<field name="company_id" groups="base.group_multi_company"/>
</tree>
</field>
</record>
<record id="crm_team_view_kanban" model="ir.ui.view">
<field name="name">crm.team.kanban</field>
<field name="model">crm.team</field>
<field name="arch" type="xml">
<kanban class="o_kanban_mobile" sample="1">
<templates>
<t t-name="kanban-box">
<div t-attf-class="oe_kanban_content oe_kanban_global_click">
<div class="row">
<div class="col-6">
<strong><field name="name"/></strong>
</div>
<div class="col-6">
<span class="float-right"><field name="user_id"/></span>
</div>
</div>
</div>
</t>
</templates>
</kanban>
</field>
</record>
<!-- Case Teams Salesteams dashboard view -->
<record id="crm_team_salesteams_view_kanban" model="ir.ui.view" >
<field name="name">crm.team.dashboard</field>
<field name="model">crm.team</field>
<field name="arch" type="xml">
<kanban class="oe_background_grey o_kanban_dashboard o_salesteam_kanban" create="0" sample="1">
<field name="name"/>
<field name="user_id"/>
<field name="member_ids"/>
<field name="color"/>
<field name="currency_id"/>
<field name="is_favorite"/>
<templates>
<t t-name="kanban-box">
<div t-attf-class="#{!selection_mode ? kanban_color(record.color.raw_value) : ''}">
<div t-attf-class="o_kanban_card_header">
<div class="o_kanban_card_header_title">
<div class="o_primary"><field name="name"/></div>
</div>
<div class="o_kanban_manage_button_section">
<a class="o_kanban_manage_toggle_button" href="#"><i class="fa fa-ellipsis-v" role="img" aria-label="Manage" title="Manage"/></a>
</div>
</div>
<div class="container o_kanban_card_content">
<div class="row o_kanban_card_upper_content">
<div class="col-4 o_kanban_primary_left" name="to_replace_in_sale_crm">
<button type="object" class="btn btn-primary" name="action_primary_channel_button"><field name="dashboard_button_name"/></button>
</div>
<div class="col-8 o_kanban_primary_right" style="padding-bottom:0;">
<t name="first_options"/>
<t name="second_options"/>
<t name="third_options"/>
</div>
</div>
<div class="row">
<div class="col-12 o_kanban_primary_bottom">
<t t-call="SalesTeamDashboardGraph"/>
</div>
<div class="col-12 o_kanban_primary_bottom bottom_block">
</div>
</div>
</div><div class="container o_kanban_card_manage_pane dropdown-menu" role="menu">
<div class="row">
<div class="col-4 o_kanban_card_manage_section o_kanban_manage_view">
<div role="menuitem" class="o_kanban_card_manage_title">
<span>View</span>
</div>
</div>
<div class="col-4 o_kanban_card_manage_section o_kanban_manage_new">
<div role="menuitem" class="o_kanban_card_manage_title">
<span>New</span>
</div>
</div>
<div class="col-4 o_kanban_card_manage_section o_kanban_manage_reports">
<div role="menuitem" class="o_kanban_card_manage_title">
<span>Reporting</span>
</div>
</div>
</div>
<div t-if="widget.editable" class="o_kanban_card_manage_settings row" groups="sales_team.group_sale_manager">
<div role="menuitem" aria-haspopup="true" class="col-8">
<ul class="oe_kanban_colorpicker" data-field="color" role="menu"/>
</div>
<div role="menuitem" class="col-4">
<a class="dropdown-item" type="edit">Configuration</a>
</div>
</div>
</div>
</div>
</t>
<t t-name="SalesTeamDashboardGraph">
<div t-if="record.dashboard_graph_data.raw_value" class="o_sales_team_kanban_graph_section">
<field name="dashboard_graph_data" widget="dashboard_graph" t-att-graph_type="'bar'"/>
</div>
</t>
</templates>
</kanban>
</field>
</record>
<!-- Sales Teams Actions -->
<record id="crm_team_salesteams_act" model="ir.actions.act_window">
<field name="name">Sales Teams</field>
<field name="res_model">crm.team</field>
<field name="view_mode">kanban,form</field>
<field name="view_id" ref="crm_team_salesteams_search"/>
<field name="context">{'in_sales_app': True}</field>
<field name="help" type="html">
<p class="o_view_nocontent_smiling_face">
Define a new sales team
</p><p>
Use Sales Teams to organize your sales departments.
Each team will work with a separate pipeline.
</p>
</field>
</record>
<record id="crm_team_salesteams_pipelines_act" model="ir.actions.act_window">
<field name="name">Teams</field>
<field name="res_model">crm.team</field>
<field name="view_mode">kanban,form</field>
<field name="view_id" ref="crm_team_salesteams_search"/>
<field name="context">{}</field>
<field name="help" type="html">
<p class="o_view_nocontent_smiling_face">
Define a new sales team
</p><p>
Use Sales Teams to organize your sales departments.
Each team will work with a separate pipeline.
</p>
</field>
</record>
<record id="sales_team_config_action" model="ir.actions.act_window">
<field name="name">Sales Teams</field>
<field name="res_model">crm.team</field>
<field name="view_mode">tree,form</field>
<field name="context">{}</field>
<field name="view_id" ref="crm_team_salesteams_search"/>
<field name="help" type="html">
<p class="o_view_nocontent_smiling_face">
Define a new sales team
</p><p>
Use Sales Teams to organize your sales departments.
Each team will work with a separate pipeline.
</p>
</field>
</record>
</data>
</odoo>
|