[IMP/Fix]Improved group by functionality. (#941)

* Fixed the issue of expand shrink buttons showing on discuss menu.
* Added debounce event when buttons are clicked.
* Fixed the issue of buttons are added in FavoriteMenu.
* Restructured the code to fix other various issue like only display group by expand buttons if group by button is visible. NOTE: Earlier code was not honoring disable_groupby by flag in searchview
This commit is contained in:
Meet Dholakiya
2018-06-08 00:27:22 +05:30
committed by Pedro M. Baeza
parent 8503e0ee28
commit 442f5b7d61
6 changed files with 122 additions and 78 deletions

View File

@@ -1,11 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<template xml:space="preserve">
<t t-extend="SearchView.FavoriteMenu">
<t t-jquery=".o_favorites_menu" t-operation="after">
<div class="toggle_buttons">
<button id="oe_group_by_expand" class="fa fa-expand btn btn-icon"/>
<button id="oe_group_by_reset" class="fa fa-compress btn btn-icon"/>
</div>
</t>
</t>
<div t-name="SearchView.GroupByExpandMenu" class="btn-group">
<button class="btn btn-sm fa fa-expand btn btn-icon o_group_by_expand"
title="Expand"/>
<button class="btn btn-sm fa fa-compress btn btn-icon o_group_by_shrink"
title="Shrink"/>
</div>
</template>