Skip to content

Commit

Permalink
[BUGFIX] Use urldecode() for search term in ajax preview
Browse files Browse the repository at this point in the history
Before this commit a searchterm with a space like "foo bar" was shown as "foo%20bar" in preview diagram
  • Loading branch information
einpraegsam committed Nov 8, 2024
1 parent af9de68 commit f434f27
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Classes/Controller/AnalysisController.php
Original file line number Diff line number Diff line change
Expand Up @@ -544,7 +544,7 @@ public function detailSearchAjaxPage(ServerRequestInterface $request): ResponseI
);
$standaloneView->assignMultiple([
'searches' => $this->searchRepository->findByFilter($filter),
'searchterm' => $request->getQueryParams()['searchterm'],
'searchterm' => urldecode($request->getQueryParams()['searchterm']),
'searchData' => GeneralUtility::makeInstance(SearchDataProvider::class, $filter),
]);
$response = GeneralUtility::makeInstance(JsonResponse::class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ <h3 class="panel-title">
</tbody>
</table>

<button style="margin-top: 15px" class="btn btn-primary pull-right" data-lux-linkmock-event="detailsearch{searchterm}"><f:translate key="LLL:EXT:lux/Resources/Private/Language/locallang_db.xlf:module.detail.detail">show</f:translate></button>
<button style="margin-top: 15px" class="btn btn-primary pull-right" data-lux-linkmock-event="detailsearch{searchterm -> f:format.urlencode()}"><f:translate key="LLL:EXT:lux/Resources/Private/Language/locallang_db.xlf:module.detail.detail">show</f:translate></button>
</f:then>
<f:else>
<f:render partial="Miscellaneous/NoValues" arguments="{_all}"/>
Expand Down

0 comments on commit f434f27

Please sign in to comment.