How can I correctly send the status of a checkbox to Django using hx-vals? I attempted the following method:
hx-vals='{
"solved": "document.querySelector("input[name="solved"]").checked",
"comment": "document.querySelector("input[name="comment"]").checked",
"no_solution": "document.querySelector("input[name="no_solution"]").checked",
}'
In the Django views, I expected to retrieve the values like this:
filter_solved = request.GET.get("solved") == 'true'
However, I couldn’t make this work. How can I fix this?
Ty!!!