PURPOSE Clean organization and models linked to Event Online feature introduced in semi stable saas-13.3 at odoo/odoo@981f95bbf4 and odoo/enterprise@14722028ae Also clean website event menu not being available in website event but only in website event track, which implies some extra-code to manage it. In short: merge website_event_online in website_event, website_event_track _(online/session) in website_event_track. RATIONALE _online modules have been added to extend content of website_event and website_event_track without having any impact on those module. First step of cleaning is to move this content directly in base module. track_session module is mainly a rewrite of track module. Second step of cleaning is to move its content directly in website_event_track. SPECIFICATIONS Move website event menu model directly into website event. Website event menu model has been introduced to help dealing with event-specific menus and website menus. This is some kind of glue to synchronize both of them as people could either * update an event (website_menu, website_track) that updates website menus availability; * update menus through website that should update event field value and menu computation; Having a model introduced in website event track forces to have override and code split across website_event, website_event_track, and now also in both _online version of those two as menu management was improved. In this commit we simplify all this code by moving most of menu management code in website_event, leaving only business-specific code (fields and their menus) to sub modules. SPECIFICATIONS: WEBSITE EVENT MENU Make type required as we don't support entries without type. Indeed this model is used to automate menus generation / destruction, and not for hand-made menus. We therefore set type as required and add a cascade ondelete for selection. SPECIFCIATIONS: COMMUNITY MENU Doing this change allows to define community menu in website_event and re-use it in website_event_meet and website_event_track_quiz, removing some unnecessary dependencies. This menu is void in website_event, and displays either meeting rooms (in meet) or quiz points leaderboard (in quiz), or a mix of both if the two features are installed. LINKS Task ID-2319779 COM odoo/odoo#56067 ENT odoo/enterprise#12520 UPG odoo/upgrade#165
52 lines
1.7 KiB
XML
52 lines
1.7 KiB
XML
<?xml version="1.0"?>
|
|
<odoo><data>
|
|
|
|
<record id="website_event_menu_view_search" model="ir.ui.view">
|
|
<field name="name">website.event.menu.view.search</field>
|
|
<field name="model">website.event.menu</field>
|
|
<field name="arch" type="xml">
|
|
<search string="Website Event Menus">
|
|
<field name="menu_id"/>
|
|
<field name="event_id"/>
|
|
<field name="menu_type"/>
|
|
</search>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="website_event_menu_view_form" model="ir.ui.view">
|
|
<field name="name">website.event.menu.view.form</field>
|
|
<field name="model">website.event.menu</field>
|
|
<field name="arch" type="xml">
|
|
<form string="Website Event Menu">
|
|
<sheet>
|
|
<group>
|
|
<field name="menu_id"/>
|
|
<field name="event_id"/>
|
|
<field name="menu_type"/>
|
|
</group>
|
|
</sheet>
|
|
</form>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="website_event_menu_view_tree" model="ir.ui.view">
|
|
<field name="name">website.event.menu.view.tree</field>
|
|
<field name="model">website.event.menu</field>
|
|
<field name="arch" type="xml">
|
|
<tree string="Website Event Menus">
|
|
<field name="menu_id"/>
|
|
<field name="event_id"/>
|
|
<field name="menu_type"/>
|
|
</tree>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="website_event_menu_action" model="ir.actions.act_window">
|
|
<field name="name">Menus</field>
|
|
<field name="res_model">website.event.menu</field>
|
|
<field name="view_mode">tree,form</field>
|
|
</record>
|
|
|
|
</data>
|
|
</odoo>
|