mirror of
https://github.com/ZwareBear/awx.git
synced 2026-05-03 05:11:49 -05:00
Fixed removing host filter search term with encoded character
This commit is contained in:
@@ -140,7 +140,7 @@ export default ['$stateParams', '$scope', '$state', 'GetBasePath', 'QuerySet', '
|
||||
function searchWithoutKey(term) {
|
||||
if($scope.singleSearchParam) {
|
||||
return {
|
||||
[$scope.singleSearchParam]: encodeURIComponent("search=" + term)
|
||||
[$scope.singleSearchParam]: "search=" + encodeURIComponent(term)
|
||||
};
|
||||
}
|
||||
return {
|
||||
@@ -329,6 +329,10 @@ export default ['$stateParams', '$scope', '$state', 'GetBasePath', 'QuerySet', '
|
||||
else {
|
||||
if($scope.singleSearchParam && set[$scope.singleSearchParam] && set[$scope.singleSearchParam].includes("%20and%20")) {
|
||||
let searchParamParts = set[$scope.singleSearchParam].split("%20and%20");
|
||||
// The value side of each paramPart might have been encoded in SmartSearch.splitFilterIntoTerms
|
||||
_.each(searchParamParts, (paramPart, paramPartIndex) => {
|
||||
searchParamParts[paramPartIndex] = decodeURIComponent(paramPart);
|
||||
});
|
||||
var index = searchParamParts.indexOf(value);
|
||||
if (index !== -1) {
|
||||
searchParamParts.splice(index, 1);
|
||||
|
||||
Reference in New Issue
Block a user