refs #5712 hotFix(catalog): undo last fix search_panel
gitea/salix/pipeline/head This commit looks good Details

This commit is contained in:
Alex Moreno 2023-08-22 13:39:57 +02:00
parent a26652045c
commit 5a5e3ebddb
2 changed files with 3 additions and 3 deletions

View File

@ -236,7 +236,7 @@ class Controller extends Section {
tagGroups: this.tagGroups, tagGroups: this.tagGroups,
}; };
return model.addFilter({where: newFilter}, newParams); return model.applyFilter({where: newFilter}, newParams);
} }
openPanel(event) { openPanel(event) {

View File

@ -191,14 +191,14 @@ describe('Order', () => {
describe('applyFilters()', () => { describe('applyFilters()', () => {
it(`should call model applyFilter() method with a new filter`, () => { it(`should call model applyFilter() method with a new filter`, () => {
jest.spyOn(controller.$.model, 'addFilter'); jest.spyOn(controller.$.model, 'applyFilter');
controller._categoryId = 2; controller._categoryId = 2;
controller._typeId = 4; controller._typeId = 4;
controller.applyFilters(); controller.applyFilters();
expect(controller.$.model.addFilter).toHaveBeenCalledWith( expect(controller.$.model.applyFilter).toHaveBeenCalledWith(
{where: {categoryFk: 2, typeFk: 4}}, {where: {categoryFk: 2, typeFk: 4}},
{orderFk: 4, orderBy: controller.getOrderBy(), tagGroups: []}); {orderFk: 4, orderBy: controller.getOrderBy(), tagGroups: []});
}); });