[FIX] fixes searchbar navigation (web client)
authorGéry Debongnie <ged@odoo.com>
Thu, 19 Jun 2014 10:43:25 +0000 (12:43 +0200)
committerGéry Debongnie <ged@odoo.com>
Thu, 19 Jun 2014 10:43:25 +0000 (12:43 +0200)
the code handling the keydown events was moved, but the variable this
was not adjusted accordingly, resulting in a broken navigation.

It is now possible to press LEFT and RIGHT again to move the focus
between facets.

addons/web/static/src/js/search.js

index 1f61620..30b381d 100644 (file)
@@ -331,11 +331,11 @@ instance.web.SearchView = instance.web.Widget.extend(/** @lends instance.web.Sea
         'keydown .oe_searchview_input, .oe_searchview_facet': function (e) {
             switch(e.which) {
             case $.ui.keyCode.LEFT:
-                this.focusPreceding(this);
+                this.focusPreceding(e.target);
                 e.preventDefault();
                 break;
             case $.ui.keyCode.RIGHT:
-                this.focusFollowing(this);
+                this.focusFollowing(e.target);
                 e.preventDefault();
                 break;
             }