Skip to content

Commit 1f437b3

Browse files
authored
Merge pull request #409 from devforth/feature/AdminForth/772/i-use-cloudflare-managed-waf-r
fix: remove multiple URL encoding from filters
2 parents 023e77c + 197e18a commit 1f437b3

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

adminforth/spa/src/views/ListView.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,7 @@ async function init() {
412412
return {
413413
field,
414414
operator,
415-
value: JSON.parse(decodeURIComponent(route.query[k] as string))
415+
value: JSON.parse((route.query[k] as string))
416416
}
417417
});
418418
if (filters.length) {
@@ -494,7 +494,7 @@ watch(() => filtersStore.filters, async (to, from) => {
494494
const currentQ = currentQuery();
495495
filtersStore.filters.forEach(f => {
496496
if (f.value !== undefined && f.value !== null && f.value !== '') {
497-
query[`filter__${f.field}__${f.operator}`] = encodeURIComponent(JSON.stringify(f.value));
497+
query[`filter__${f.field}__${f.operator}`] = (JSON.stringify(f.value));
498498
}
499499
});
500500
// set every key in currentQ which starts with filter_ to undefined if it is not in query

0 commit comments

Comments
 (0)