added in double quotes for single in query

This commit is contained in:
2024-03-07 09:45:50 +00:00
parent 25d611b3e4
commit f434fcf4f8
10 changed files with 16 additions and 5 deletions
+1 -1
View File
@@ -25,7 +25,7 @@ let AdvancedSearch = (props) => {
const { LPAData, onSubmit, handleSubmit } = props; const { LPAData, onSubmit, handleSubmit } = props;
console.log("props here:", props.props); //console.log("props here:", props.props);
const appealOptionsObj = _.isEmpty(props) const appealOptionsObj = _.isEmpty(props)
? [{}] ? [{}]
+2 -1
View File
@@ -68,7 +68,8 @@ let CompleteAppeal = (props) => {
); );
console.log("patching////////"); console.log("patching////////");
patchCase(incidentId); //
//patchCase(incidentId);
}, [ }, [
props.appealType.caseReference, props.appealType.caseReference,
props.props.form.appealForm.values, props.props.form.appealForm.values,
+1 -1
View File
@@ -10,7 +10,7 @@ export default function Search(props) {
const router = useRouter(); const router = useRouter();
const { locale } = router; const { locale } = router;
console.log("props here:", props.myportal || false); //console.log("props here:", props.myportal || false);
return ( return (
<main <main
+1 -2
View File
@@ -749,8 +749,7 @@ const SearchResults = (props) => {
getSearchPageResults(1, orderByState, fieldSortState); getSearchPageResults(1, orderByState, fieldSortState);
setLoginToWatch(false); setLoginToWatch(false);
} else { } else {
console.log("or am in here"); //console.log("or am in here");
setLoginToWatch(false); setLoginToWatch(false);
} }
}, [ }, [
@@ -79,6 +79,7 @@ export default async function ApiProxy(req, res) {
: ""; : "";
//console.log(queryString); //console.log(queryString);
queryString = queryString.replace(/\'/g, "''");
var queryUrl = var queryUrl =
"incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=" + "incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=" +
@@ -113,6 +113,8 @@ export default async function ApiProxy(req, res) {
? " statuscode eq " + searchString.statuscode + " and" ? " statuscode eq " + searchString.statuscode + " and"
: ""; : "";
queryString = queryString.replace(/\'/g, "''");
var queryUrl = var queryUrl =
"incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=" + "incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=" +
queryString + queryString +
@@ -43,6 +43,8 @@ export default async function ApiProxy(req, res) {
var searchString = req.query.searchString; var searchString = req.query.searchString;
var token = await getToken(); var token = await getToken();
searchString = searchString.replace(/\'/g, "''");
var queryUrl = var queryUrl =
"incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=(contains(title, '" + "incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=(contains(title, '" +
searchString + searchString +
+2
View File
@@ -42,6 +42,8 @@ export default async function ApiProxy(req, res) {
var searchString = req.query.searchString; var searchString = req.query.searchString;
var token = await getToken(); var token = await getToken();
searchString = searchString.replace(/\'/g, "''");
var queryUrl = var queryUrl =
"incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=(contains(title, '" + "incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=(contains(title, '" +
searchString + searchString +
@@ -76,6 +76,8 @@ export default async function ApiProxy(req, res) {
var fieldSort = req.query.fieldSort; var fieldSort = req.query.fieldSort;
var showNumberOfRecords = req.query.showNumberOfRecords; var showNumberOfRecords = req.query.showNumberOfRecords;
searchString = searchString.replace(/\'/g, "''");
var queryUrl = var queryUrl =
"incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=(contains(title, '" + "incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=(contains(title, '" +
searchString + searchString +
@@ -25,6 +25,8 @@ export default async function ApiProxy(req, res) {
var searchString = req.query.searchString; var searchString = req.query.searchString;
var token = await getToken(); var token = await getToken();
searchString = searchString.replace(/\'/g, "''");
var queryUrl = var queryUrl =
"incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=(contains(title, '" + "incidents?$select=description,numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value,pinswg_lpareference&$expand=primarycontactid($select=fullname)&$filter=(contains(title, '" +
searchString + searchString +