[FIX] list should go back to first page on new search
authorXavier Morel <xmo@openerp.com>
Thu, 1 Dec 2011 10:42:33 +0000 (11:42 +0100)
committerXavier Morel <xmo@openerp.com>
Thu, 1 Dec 2011 10:42:33 +0000 (11:42 +0100)
lp bug: https://launchpad.net/bugs/898546 fixed

bzr revid: xmo@openerp.com-20111201104233-kpkywab12mqbkzmu

addons/web/static/src/js/view_list.js

index 53c8d63..8f8215d 100644 (file)
@@ -462,6 +462,7 @@ openerp.web.ListView = openerp.web.View.extend( /** @lends openerp.web.ListView#
      * @param {Object} results results of evaluating domain and process for a search
      */
     do_search: function (domain, context, group_by) {
+        this.page = 0;
         this.groups.datagroup = new openerp.web.DataGroup(
             this, this.model, domain, context, group_by);
         this.groups.datagroup.sort = this.dataset._sort;