Skip to content

Commit

Permalink
THE-1370 chargement de isAdvanced depuis url et passage en variable g…
Browse files Browse the repository at this point in the history
…lobale
  • Loading branch information
clementdelafontaine committed Oct 2, 2024
1 parent 2e45ab3 commit 92b9a79
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions composables/useStrategyAPI.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,6 @@ export default function() {
const startingParameterShowingNumber = mobile.value ? 10 : parseInt(getURLParameter("nb"));
const startingParameterAdvanced = getURLParameter("avancee");


// Comparer les paramètres actuels avec ceux existants
if (
currentSorting.value === startingParameterTri &&
Expand Down Expand Up @@ -177,11 +176,7 @@ export default function() {
if (currentShowingNumber.value) params["nb"] = currentShowingNumber.value;
if (currentSorting.value) params["tri"] = currentSorting.value;
if (domaine.value) params["domaine"] = domaine.value;
const isAdvanced = useState("isAdvanced");

if(isAdvanced.value) {
params["avancee"] = "true";
}
if (isAdvanced.value) params["avancee"] = isAdvanced.value;

return params;
}
Expand Down Expand Up @@ -233,7 +228,7 @@ export default function() {
function queryAPI() {
updateURLDebounced();

const isAdvanced = useState("isAdvanced");
// const isAdvanced = useState("isAdvanced");

query.value = (typeof query.value === "undefined") ? "*" : query.value;

Expand Down

0 comments on commit 92b9a79

Please sign in to comment.