[MOV][IMP] event: improve some views and event main menus definitions
PURPOSE This commit is part of ticket model support directly in event application. SPECIFICATIONS In this commit we move menu definitions in their own file. It eases views split and move, as otherwise there are dependencies between files that are complicated to solve. Better to have menus defined in a main file, and updating them at will afterwards. We also improve menus sequences and groups, as some were missing or badly defined. Registration tree view is slightly updated to include phone and mobile numbers as those are used notably for communication. They are hidden by default like email. Finally a small tweak of event kanban view is performed, notably to have a better display with dependencies installed. We ensure all cards have the same height. LINKS Task ID 2177281 Community PR #43488 Co-Authored-By: Thibault Delavallée <tde@odoo.com> Co-Authored-By: Stéphane Debauche <std@odoo.com>
This commit is contained in:
co-authored by
Stéphane Debauche
parent
97a7cce164
commit
623a226beb
@@ -21,6 +21,7 @@ Key Features
|
||||
'data': [
|
||||
'security/event_security.xml',
|
||||
'security/ir.model.access.csv',
|
||||
'views/event_menu_views.xml',
|
||||
'views/event_views.xml',
|
||||
'views/event_stage_views.xml',
|
||||
'report/event_event_templates.xml',
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
.o_kanban_view.o_event_kanban_view {
|
||||
.o_kanban_record {
|
||||
min-height: 140px;
|
||||
}
|
||||
.o_kanban_content {
|
||||
min-height: 130px;
|
||||
|
||||
.o_event_fontweight_500 {
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,41 @@
|
||||
<?xml version="1.0"?>
|
||||
<odoo><data>
|
||||
|
||||
<!-- MAIN MENU -->
|
||||
<menuitem name="Events"
|
||||
id="event_main_menu"
|
||||
sequence="65"
|
||||
groups="event.group_event_user"
|
||||
web_icon="event,static/description/icon.png"/>
|
||||
|
||||
<!-- HEADER: EVENTS -->
|
||||
<menuitem name="Events"
|
||||
id="menu_event_event"
|
||||
sequence="1"
|
||||
parent="event.event_main_menu"
|
||||
groups="event.group_event_user"/>
|
||||
|
||||
<!-- HEADER: REPORTING -->
|
||||
<menuitem name="Reporting"
|
||||
id="menu_reporting_events"
|
||||
sequence="50"
|
||||
parent="event_main_menu"
|
||||
groups="event.group_event_manager"/>
|
||||
|
||||
<!-- HEADER: CONFIGURATION -->
|
||||
<menuitem name="Configuration"
|
||||
id="menu_event_configuration"
|
||||
sequence="99"
|
||||
parent="event_main_menu"
|
||||
groups="event.group_event_user"/>
|
||||
<menuitem name="Event Categories"
|
||||
id="menu_event_type"
|
||||
sequence="1"
|
||||
parent="menu_event_configuration"/>
|
||||
<menuitem name="Mail Schedulers"
|
||||
id="menu_event_mail_schedulers"
|
||||
sequence="10"
|
||||
parent="menu_event_configuration"
|
||||
groups="base.group_no_one"/>
|
||||
|
||||
</data></odoo>
|
||||
@@ -2,10 +2,6 @@
|
||||
<odoo>
|
||||
<data>
|
||||
|
||||
<!-- Main menu items -->
|
||||
<menuitem name="Events" id="event_main_menu" sequence="65" groups="event.group_event_user" web_icon="event,static/description/icon.png"/>
|
||||
<menuitem parent="event_main_menu" id="menu_reporting_events" sequence="99" groups="event.group_event_manager" name="Reporting"/>
|
||||
|
||||
<!-- EVENT.TYPE VIEWS -->
|
||||
<record model="ir.ui.view" id="view_event_type_form">
|
||||
<field name="name">event.type.form</field>
|
||||
@@ -158,9 +154,9 @@
|
||||
<field name="res_model">event.type</field>
|
||||
</record>
|
||||
|
||||
<menuitem id="menu_event_configuration" name="Configuration" parent="event_main_menu"
|
||||
sequence="100"/>
|
||||
<menuitem name="Event Categories" id="menu_event_type" action="action_event_type" parent="menu_event_configuration"/>
|
||||
<record id="menu_event_type" model="ir.ui.menu">
|
||||
<field name="action" ref="event.action_event_type"/>
|
||||
</record>
|
||||
|
||||
<!-- EVENT.REGISTRATION ACTIONS -->
|
||||
<record id="act_event_registration_from_event" model="ir.actions.act_window">
|
||||
@@ -348,8 +344,8 @@
|
||||
<field name="activity_state"/>
|
||||
<templates>
|
||||
<t t-name="kanban-box">
|
||||
<div t-attf-class="p-0 {{!selection_mode ? 'oe_kanban_color_' + kanban_getcolor(record.color.raw_value) : ''}} oe_kanban_card oe_kanban_global_click">
|
||||
<div class="o_kanban_content p-0 m-0 position-relative row d-flex">
|
||||
<div t-attf-class="d-flex flex-column p-0 {{!selection_mode ? 'oe_kanban_color_' + kanban_getcolor(record.color.raw_value) : ''}} oe_kanban_card oe_kanban_global_click">
|
||||
<div class="o_kanban_content p-0 m-0 position-relative row d-flex flex-fill">
|
||||
<div class="col-3 bg-primary p-2 text-center d-flex flex-column justify-content-center">
|
||||
<div t-esc="record.date_begin.raw_value.getDate()" class="o_event_fontsize_20"/>
|
||||
<div>
|
||||
@@ -475,7 +471,9 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<menuitem name="Events" id="menu_event_event" action="action_event_view" parent="event.event_main_menu" />
|
||||
<record id="event.menu_event_event" model="ir.ui.menu">
|
||||
<field name="action" ref="event.action_event_view"/>
|
||||
</record>
|
||||
<menuitem name="Events"
|
||||
id="event_event_menu_pivot_report"
|
||||
action="event_event_action_pivot"
|
||||
@@ -494,6 +492,8 @@
|
||||
<field name="partner_id"/>
|
||||
<field name="name"/>
|
||||
<field name="email" optional="hide"/>
|
||||
<field name="phone" optional="hide"/>
|
||||
<field name="mobile" optional="hide"/>
|
||||
<field name="event_id" />
|
||||
<field name="origin" optional="hide"/>
|
||||
<field name="state" readonly="0"/>
|
||||
@@ -726,6 +726,8 @@
|
||||
<field name="res_model">event.mail</field>
|
||||
</record>
|
||||
|
||||
<menuitem name="Mail Schedulers" id="menu_event_mail_schedulers" action="action_event_mail" parent="menu_event_configuration" groups="base.group_no_one"/>
|
||||
<record id="menu_event_mail_schedulers" model="ir.ui.menu">
|
||||
<field name="action" ref="event.action_event_mail"/>
|
||||
</record>
|
||||
</data>
|
||||
</odoo>
|
||||
|
||||
Reference in New Issue
Block a user