summaryrefslogtreecommitdiff
path: root/addons/web/static/src/xml/web_calendar.xml
diff options
context:
space:
mode:
authorRomeo Fragomeli <rfr@odoo.com>2020-01-15 10:44:15 +0000
committerPierre Paridans <app@odoo.com>2020-03-31 15:06:35 +0000
commit70ea6739ede926cc5e87e90ac5718bffe8f35d35 (patch)
treeec9cc50d238c425b8492506a91c34024b4fa943c /addons/web/static/src/xml/web_calendar.xml
parent10bc51cf887a663010cf0bb0f9d89a1b5767a70b (diff)
[REF] web: extracts calendar's methods to allow customization
This commit extracts some calendar's event handlers, private methods and templates to create 'hooks' allowing further customization. Task ID: 2092550
Diffstat (limited to 'addons/web/static/src/xml/web_calendar.xml')
-rw-r--r--addons/web/static/src/xml/web_calendar.xml24
1 files changed, 16 insertions, 8 deletions
diff --git a/addons/web/static/src/xml/web_calendar.xml b/addons/web/static/src/xml/web_calendar.xml
index be0d645e45f..e3506321b47 100644
--- a/addons/web/static/src/xml/web_calendar.xml
+++ b/addons/web/static/src/xml/web_calendar.xml
@@ -92,15 +92,23 @@
<t t-name="CalendarView.buttons">
<div class="o_calendar_buttons">
<t t-if="!isMobile">
- <button class="o_calendar_button_prev btn btn-primary" aria-label="Previous" title="Previous"><span class="fa fa-arrow-left"/></button>
- <button class="o_calendar_button_today btn btn-primary">Today</button>
- <button class="o_calendar_button_next btn btn-primary" aria-label="Next" title="Next"><span class="fa fa-arrow-right"/></button>
+ <t t-call="CalendarView.navigation_buttons" />
</t>
- <div class="btn-group">
- <button type="button" class="o_calendar_button_day btn btn-secondary">Day</button>
- <button type="button" class="o_calendar_button_week btn btn-secondary">Week</button>
- <button type="button" class="o_calendar_button_month btn btn-secondary">Month</button>
- </div>
+ <t t-call="CalendarView.scale_buttons" />
+ </div>
+ </t>
+
+ <t t-name="CalendarView.navigation_buttons">
+ <button class="o_calendar_button_prev btn btn-primary" aria-label="Previous" title="Previous"><span class="fa fa-arrow-left"/></button>
+ <button class="o_calendar_button_today btn btn-primary">Today</button>
+ <button class="o_calendar_button_next btn btn-primary" aria-label="Next" title="Next"><span class="fa fa-arrow-right"/></button>
+ </t>
+
+ <t t-name="CalendarView.scale_buttons">
+ <div class="btn-group">
+ <button type="button" class="o_calendar_button_day btn btn-secondary">Day</button>
+ <button type="button" class="o_calendar_button_week btn btn-secondary">Week</button>
+ <button type="button" class="o_calendar_button_month btn btn-secondary">Month</button>
</div>
</t>