updated to remove obsolete token calls
This commit is contained in:
+5
-21
@@ -185,8 +185,6 @@ export const getBasicDNSSearch = (token, searchString) => {
|
||||
};
|
||||
|
||||
export const getBasicDNSSearchPaged = (pageNumber) => {
|
||||
var token = getToken();
|
||||
|
||||
var queryUrl =
|
||||
"/api/proxy/incidents?$select=numberofchildincidents,_accountid_value,_customerid_value,_pinswg_associatedlpa_value,_ownerid_value,pinswg_appealcasetype,statuscode,ticketnumber,title, _primarycontactid_value&$expand=primarycontactid($select=fullname)&$filter=pinswg_appealcasetype eq 846040011 and pinswg_publishtoweb eq true&$orderby=createdon desc&$count=true" +
|
||||
(typeof pageNumber != "undefined"
|
||||
@@ -254,8 +252,6 @@ export const getAdvancedSearch = (token, searchString) => {
|
||||
|
||||
export const getAdvancedSearchPaged = (searchString, pageNumber) => {
|
||||
//console.log(searchString);
|
||||
var token = getToken();
|
||||
|
||||
var queryString = "";
|
||||
|
||||
queryString +=
|
||||
@@ -390,7 +386,6 @@ export const getSearchDocumentHistory = (token, documentID) => {
|
||||
|
||||
export const getSearchDocumentDetailsPaged = (incidentID, pageNumber) => {
|
||||
console.log(incidentID);
|
||||
var token = getToken();
|
||||
|
||||
var queryUrl =
|
||||
"/api/proxy/pinswg_documents?$count=true&$filter=_pinswg_documentids_value eq " +
|
||||
@@ -410,8 +405,6 @@ export const getSearchDocumentDetailsPaged = (incidentID, pageNumber) => {
|
||||
};
|
||||
|
||||
export const getSearchDocumentHistoryPaged = (documentID, pageNumber) => {
|
||||
var token = getToken();
|
||||
|
||||
var queryUrl =
|
||||
"/api/proxy/pinswg_documenthistories?$count=true&$select=_pinswg_documentid_value,pinswg_createddate,pinswg_state,pinswg_fileexists,statecode,pinswg_publisheddate&$filter=_pinswg_documentid_value eq " +
|
||||
documentID +
|
||||
@@ -503,8 +496,6 @@ export const getBasicDNSSearchDetails = (token, appealType, caseReference) => {
|
||||
};
|
||||
|
||||
export const getBasicDNSSearchDetailsPaged = (caseReference) => {
|
||||
var token = getToken();
|
||||
|
||||
var queryUrl =
|
||||
"/api/proxy/pinswg_dnses?$filter=pinswg_name eq '" +
|
||||
caseReference +
|
||||
@@ -537,9 +528,9 @@ export const getLinkedCases = (parentIncidentid) => {
|
||||
|
||||
export const getFormData = (token, whichForm) => {
|
||||
var queryUrl =
|
||||
"systemforms?$select=formid,name,formxml,type,objecttypecode&$filter=(objecttypecode%20eq%20%27pinswg_" +
|
||||
"systemforms?$select=formid,name,formxml,type,objecttypecode&$filter=(objecttypecode eq 'pinswg_" +
|
||||
whichForm +
|
||||
"%27and%20type%20eq%202)&$count=true&$top=201";
|
||||
"' and type eq 2)&$count=true&$top=201";
|
||||
return axios
|
||||
.get(WEBAPI_URL + queryUrl + hashAPIPath(queryUrl), azureHeaders(token))
|
||||
.then((res) => res.data)
|
||||
@@ -652,10 +643,7 @@ export const getAppealID = (
|
||||
|
||||
console.log("proxy url ", queryUrl);
|
||||
return axios
|
||||
.get(
|
||||
WEBAPI_URL + queryUrl + hashAPIPath(queryUrl),
|
||||
azureHeaders(getToken())
|
||||
)
|
||||
.get(queryUrl + hashAPIPath(queryUrl))
|
||||
.then((res) => {
|
||||
var appealID = res.data.value[0][primaryAttribute];
|
||||
return appealID;
|
||||
@@ -695,14 +683,14 @@ export const createCase = (token, appealTypeId, lpaID, contactid) => {
|
||||
|
||||
var config = {
|
||||
method: "post",
|
||||
url: queryUrl + hashAPIPath(queryUrl),
|
||||
url: WEBAPI_URL + queryUrl + hashAPIPath(queryUrl),
|
||||
headers: {
|
||||
"OData-MaxVersion": "4.0",
|
||||
"OData-Version": "4.0",
|
||||
"Accept": "application/json;odata.metadata=none",
|
||||
"Prefer": 'odata.include-annotations="*",return=representation',
|
||||
"Content-Type": "application/json",
|
||||
"ServiceBusAuthorization": token,
|
||||
"Authorization": "Bearer " + token,
|
||||
},
|
||||
data: data,
|
||||
};
|
||||
@@ -745,7 +733,6 @@ export const updateCase = async (
|
||||
"Accept": "application/json;odata.metadata=none",
|
||||
"Prefer": 'odata.include-annotations="*",return=representation',
|
||||
"Content-Type": "application/json",
|
||||
"Authorization": getToken(),
|
||||
},
|
||||
data: data,
|
||||
};
|
||||
@@ -815,7 +802,6 @@ export const deleteMyRepresentations = (myRepresentationsID) => {
|
||||
"Accept": "application/json;odata.metadata=none",
|
||||
"Prefer": 'odata.include-annotations="*",return=representation',
|
||||
"Content-Type": "application/json",
|
||||
"Authorization": getToken(),
|
||||
},
|
||||
};
|
||||
// console.log(config);
|
||||
@@ -894,7 +880,6 @@ export const createWatchedCases = (formValues) => {
|
||||
"Accept": "application/json;odata.metadata=none",
|
||||
"Prefer": 'odata.include-annotations="*",return=representation',
|
||||
"Content-Type": "application/json",
|
||||
"Authorization": getToken(),
|
||||
},
|
||||
data: data,
|
||||
};
|
||||
@@ -920,7 +905,6 @@ export const deleteWatchedCases = (watchedCaseID) => {
|
||||
"Accept": "application/json;odata.metadata=none",
|
||||
"Prefer": 'odata.include-annotations="*",return=representation',
|
||||
"Content-Type": "application/json",
|
||||
"Authorization": getToken(),
|
||||
},
|
||||
};
|
||||
// console.log(config);
|
||||
|
||||
Reference in New Issue
Block a user