Skip to content

Is there a way to get querystring parameters in a template as in pnp modern search with getUrlParameter? #86

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
FLXNBC opened this issue Mar 13, 2023 · 3 comments
Assignees
Labels
documentation Improvements or additions to documentation enhancement New feature or request Next Release An issue that will be fixed or a new feature that will be added to one of the next versions of the s

Comments

@FLXNBC
Copy link

FLXNBC commented Mar 13, 2023

I would like to know if there is a way in Aequos to get querystring parameters in Handlebars template? There is an helper that exist on pnp modern search « getUrlParameter » but looks like it’s not working on Aequos.

Any thoughts?

@Laul0
Copy link
Collaborator

Laul0 commented Mar 13, 2023

Hi @FLXNBC,

Thank you for your question.
It depends on the purpose of your use case. You can use the following:

  • @root.inputQueryText to display or reuse the query string from the search box
  • Any tokens based on the filters, verticals, or context to retrieve parameters
  • Token to retrieve parameters from the URL is {QueryString.<ParameterName>} as mentioned to the documentation

Hoping these information will help you

@Laul0 Laul0 added documentation Improvements or additions to documentation Needs: Author Feedback Awaiting response from the original poster of the issue. labels Mar 13, 2023
@Laul0 Laul0 self-assigned this Mar 14, 2023
@FLXNBC
Copy link
Author

FLXNBC commented Mar 17, 2023

Thanks @Laul0 ! Perhaps, I'm missing something as the tokens seems to work only on the search query configuration and not on the handlebars template.

The @root.inputQueryText works well but only for one parameter, in our case we can have multiple parameters and won't work with the @root.inputQueryText except if we put everything in the same parameter with a separator.

Are you planning the add the helper "getUrlParameter", that exist on pnp modern search, to AEQUOS?

@Laul0 Laul0 added enhancement New feature or request Next Release An issue that will be fixed or a new feature that will be added to one of the next versions of the s and removed Needs: Author Feedback Awaiting response from the original poster of the issue. labels Mar 19, 2023
@Laul0
Copy link
Collaborator

Laul0 commented Mar 19, 2023

Hi @FLXNBC,

Thank you for your feedback.
You can access all Handlebars Helpers + some additional are included in MDV.

We let you know that nothing has been planned yet. We added it to our backlog and the team will prioritize it.
This issue will be closed automatically once the helper will be implemented in the solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request Next Release An issue that will be fixed or a new feature that will be added to one of the next versions of the s
Projects
None yet
Development

No branches or pull requests

2 participants