Open csidirop opened 1 year ago
Same for the tx_dlf_pagegrid[controller]=PageGrid
query string.
They turn up when:
Navigation
: Navigate pages
http://localhost/viewer?tx_dlf[id]=4&tx_dlf[page]=1
->
http://localhost/viewer?tx_dlf[id]=4&tx_dlf[page]=2&tx_dlf_navigation[controller]=Navigation
PageGrid
: Change PageGrid overview pages:
http://localhost/viewer?tx_dlf[double]=0&tx_dlf[id]=4&tx_dlf[page]=2&tx_dlf[pagegrid]=1
->
http://localhost/viewer?tx_dlf[double]=0&tx_dlf[id]=4&tx_dlf[page]=97&tx_dlf[pagegrid]=1&tx_dlf_pagegrid[controller]=PageGrid
With v4.x we got so many additional query parameters. Are they really necessary?
If we take a look to the query we get when we use the search, we see a bunch of parameters:
https://dfg-viewer.bib.uni-mannheim.de/suche
?tx_dlf_search[__referrer][@extension]=Dlf
&tx_dlf_search[__referrer][@controller]=Search
&tx_dlf_search[__referrer][@action]=main
&tx_dlf_search[__referrer][arguments]=YToxOntzOjE1OiJzZWFyY2hQYXJhbWV0ZXIiO2E6OTp7czo4OiJkYXRlRnJvbSI7czowOiIiO3M6NjoiZGF0ZVRvIjtzOjA6IiI7czo4OiJleHRGaWVsZCI7YToxOntpOjA7czo2OiJhdXRob3IiO31zOjExOiJleHRPcGVyYXRvciI7YToxOntpOjA7czozOiJBTkQiO31zOjg6ImV4dFF1ZXJ5IjthOjE6e2k6MDtzOjA6IiI7fXM6ODoiZnVsbHRleHQiO3M6MToiMCI7czo1OiJvcmRlciI7czowOiIiO3M6Nzoib3JkZXJCeSI7czowOiIiO3M6NToicXVlcnkiO3M6ODoiTWFubmhlaW0iO31969db09da5b5f75948dff937d18ee16a08f2c88cd
&tx_dlf_search[__referrer][@request]={"@extension":"Dlf","@controller":"Search","@action":"main"}13ddc0bfc4e80a1e63dbd1da4ed39c1e26b02400
&tx_dlf_search[__trustedProperties]={"searchParameter":{"query":1,"fulltext":1,"extOperator":[1],"extField":[1],"extQuery":[1],"dateFrom":1,"dateTo":1,"orderBy":1,"order":1}}5bee1462075d5c39baa454157aa020bd81e354e3
&tx_dlf_search[searchParameter][query]=Mannheim
&tx_dlf_search[searchParameter][fulltext]=0
&tx_dlf_search[searchParameter][extOperator][0]=AND
&tx_dlf_search[searchParameter][extField][0]=author
&tx_dlf_search[searchParameter][extQuery][0]=
&tx_dlf_search[searchParameter][dateFrom]=1600-01-01
&tx_dlf_search[searchParameter][dateTo]=2024-02-01
&tx_dlf_search[searchParameter][orderBy]=
&tx_dlf_search[searchParameter][order]=
We can remove all tx_dlf_search[__referrer]
parameters and still get the same result. When we next take a look to tx_dlf_search[__trustedProperties]
we will see, that some parameter are already covert by tx_dlf_search[searchParameter]
. And even if not, I really don't know what they are for because they all set to true (or 1
) even if its not the case. See tx_dlf_search[__trustedProperties]={"searchParameter":{ [...]"fulltext":1
against &tx_dlf_search[searchParameter][fulltext]=0
when fulltext search is not selected. So removing tx_dlf_search[__trustedProperties]
gives me still the same result.
This is the final url
https://dfg-viewer.bib.uni-mannheim.de/suche?
tx_dlf_search[searchParameter][query]=Mannheim
&tx_dlf_search[searchParameter][fulltext]=0
&tx_dlf_search[searchParameter][extOperator][0]=AND
&tx_dlf_search[searchParameter][extField][0]=author
&tx_dlf_search[searchParameter][extQuery][0]=
&tx_dlf_search[searchParameter][dateFrom]=1600-01-01
&tx_dlf_search[searchParameter][dateTo]=2024-02-01
&tx_dlf_search[searchParameter][orderBy]=
&tx_dlf_search[searchParameter][order]=
which is a lot shorter and easier to read.
In comparison presentation v3.x had not one parameter.
Description
Since v.4 there is a new query string added to the url. For me in my tests it is always
tx_dlf_navigation[controller]=Navigation
. Since Im using the DFG-Viewer on top I believe this is unnecessary. If i understood correctly, it has something to do with https://github.com/kitodo/kitodo-presentation/blob/4.x/Resources/Private/Templates/Navigation/Main.htmlMy questions:
Reproduction
Steps to reproduce the behaviour:
Or
Or
Environment