I am facing an issue while passing a property from my model to an AJAX form. The boolean value is resolving as "true/false" and causing problems in the process.
$.ajax({
url: '/Projects/SearchTable2',
type: "GET",
data: {
sub_num: @Model.SubmissionNumber,
read_only: @Model.ReadOnly,
}
});
Model.ReadOnly
is resolving to either true or false, leading to an error
Uncaught ReferenceError: False is not defined
upon execution of the code. Is there any workaround for this issue? Or perhaps another method to pass the variable to the Controller method?