web_notify: add feature to reload current view

This commit is contained in:
Guewen Baconnier
2018-06-27 14:39:47 +02:00
committed by Yannick Vaucher
parent b8e1337079
commit 8d3f2749e4
8 changed files with 138 additions and 12 deletions

View File

@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<templates id="template" xml:space="preserve">
<t t-name="Notification.reload">
<div class="o_notification_reload" t-if="widget.options.show_reload">
<a href="#" class="o_view_reload">
<span class="fa fa-refresh"/> Reload current view
</a>
</div>
</t>
<t t-extend="Notification">
<t t-jquery=".o_notification_content" t-operation="after">
<t t-call="Notification.reload"/>
</t>
</t>
<t t-extend="Warning">
<t t-jquery=".o_notification_content" t-operation="after">
<t t-call="Notification.reload"/>
</t>
</t>
</templates>