Skip to content

Commit

Permalink
Removed unneeded httpParamSerializer
Browse files Browse the repository at this point in the history
  • Loading branch information
VladLasitsa committed Sep 29, 2020
1 parent 9ea4984 commit 3ed2d30
Showing 1 changed file with 11 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ interface LazyScope extends ng.IScope {
[key: string]: any;
}

export function createTableRowDirective($compile: ng.ICompileService, $httpParamSerializer: any) {
export function createTableRowDirective($compile: ng.ICompileService) {
const cellTemplate = template(noWhiteSpace(cellTemplateHtml));
const truncateByHeightTemplate = template(noWhiteSpace(truncateByHeightTemplateHtml));

Expand Down Expand Up @@ -119,21 +119,17 @@ export function createTableRowDirective($compile: ng.ICompileService, $httpParam
)}`;
const globalFilters: any = getServices().filterManager.getGlobalFilters();
const appFilters: any = getServices().filterManager.getAppFilters();
const hash = $httpParamSerializer({
_g: encodeURI(
rison.encode({
filters: globalFilters || [],
})
),
_a: encodeURI(
rison.encode({
columns: $scope.columns,
filters: (appFilters || []).map(esFilters.disableFilter),
})
),
});

return `${path}?${hash}`;
return `${path}?_g=${encodeURI(
rison.encode({
filters: globalFilters || [],
})
)}&_a=${encodeURI(
rison.encode({
columns: $scope.columns,
filters: (appFilters || []).map(esFilters.disableFilter),
})
)}`;
};

// create a tr element that lists the value for each *column*
Expand Down

0 comments on commit 3ed2d30

Please sign in to comment.