Merged PR 928: Clean up Endpoints and build warnings

Related work items: #7944
This commit is contained in:
Robert Bond
2022-10-18 11:02:52 +00:00
38 changed files with 119 additions and 3948 deletions
+9 -3
View File
@@ -40,7 +40,11 @@ export const createContainer = async (containerName) => {
// console.log(`- ${container.name}`); // console.log(`- ${container.name}`);
// } // }
console.log("\n//////////////////\n container name :", containerName); console.log(
"\n//////////////////\n container name :",
containerName,
"\n//////////////////\n"
);
return containerName; return containerName;
}; };
@@ -271,7 +275,9 @@ export const downloadAllProgressFiles = async (
progressBlobObj progressBlobObj
) => { ) => {
console.log( console.log(
"/////////////////////////\n downloading files: " + progressBlobObj "/////////////////////////\n downloading files: " +
progressBlobObj +
"\n/////////////////////////\n"
); );
const creds = new DefaultAzureCredential(); const creds = new DefaultAzureCredential();
@@ -495,7 +501,7 @@ export const getAllProgressBlobs = async (containerName) => {
}); });
} }
console.log("blobObj:", blobObj); //console.log("blobObj:", blobObj);
return blobObj; return blobObj;
}; };
-46
View File
@@ -31,37 +31,6 @@ export const getProviderConfig = () => {
}); });
}; };
export const getGGToken = (tokenURL, authCode, redirectUri) => {
const tokenBody =
"grant_type=authorization_code" +
"&code=" +
authCode +
"&redirect_uri=" +
redirectUri;
const basicAuthBase64 = (ggClientID + ":" + ggClientSecret).toString();
//console.log("base64 " + Base64.encode(basicAuthBase64));
const tokenConfig = {
headers: {
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Basic " + Base64.encode(basicAuthBase64),
},
};
return axios
.post(tokenURL, tokenBody, tokenConfig)
.then((res) => res.data)
.catch((error) => {
// if (error.response) {
// console.log(error.response.data);
// console.log(error.response.status);
// console.log(error.response.headers);
// }
return error.response;
});
};
export const getUserInfo = (userInfoURL, authToken) => { export const getUserInfo = (userInfoURL, authToken) => {
const tokenConfig = { const tokenConfig = {
headers: { headers: {
@@ -78,21 +47,6 @@ export const getUserInfo = (userInfoURL, authToken) => {
}); });
}; };
export const getPortalLogin = (emailAddress, token) => {
var queryUrl =
"contacts?$filter=emailaddress1 eq '" +
emailAddress +
"'&$count=true&$select=emailaddress1,contactid,pinswg_custom_password,yomifullname,firstname,lastname";
return axios
.get(WEBAPI_URL + queryUrl + hashAPIPath(queryUrl), azureHeaders(token))
.then((res) => res.data)
.catch((error) => {
console.log(consoleLogger(error));
//console.log("thiserror", error);
return JSON.stringify(error);
});
};
var Base64 = { var Base64 = {
_keyStr: _keyStr:
"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=", "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",
+16 -1
View File
@@ -761,7 +761,8 @@ export const getAwaitingSubmission = (loggedInUserId) => {
export const getAwaitingSubmissionFromBlob = (containerName) => { export const getAwaitingSubmissionFromBlob = (containerName) => {
console.log( console.log(
"///////////////////////\ngetAwaitingSubmissionFromBlob: " + "///////////////////////\ngetAwaitingSubmissionFromBlob: " +
containerName containerName +
"\n///////////////////////\n"
); );
return axios return axios
.get( .get(
@@ -1400,3 +1401,17 @@ export const getNotice = () => {
console.log("this serror", error); console.log("this serror", error);
}); });
}; };
export const getPortalLogin = (emailAddress) => {
var queryUrl =
"/api/endpoint/getportallogin_api?emailAddress=" + emailAddress;
return axios
.get(BASE_URL + queryUrl)
.then((res) => res.data)
.catch((error) => {
//console.log(consoleLogger(error));
console.log("thiserror", error);
return JSON.stringify(error);
});
};
+2 -21
View File
@@ -117,15 +117,8 @@ const RenderPasswordfield = ({
let Login = (props) => { let Login = (props) => {
let { t } = useTranslation(); let { t } = useTranslation();
const { const { handleSubmit, pristine, reset, submitting, setLoggedInUserId } =
handleSubmit, props;
pristine,
reset,
submitting,
setLoggedInUserId,
GG_CLIENT_ID,
GG_REDIRECT_URI,
} = props;
const { data: session } = useSession(); const { data: session } = useSession();
@@ -135,17 +128,6 @@ let Login = (props) => {
// const [showSpinnerState, setShowSpinnerState] = useState(false); // const [showSpinnerState, setShowSpinnerState] = useState(false);
const [validLoginID, setValidLoginID] = useState(null); const [validLoginID, setValidLoginID] = useState(null);
// console.log(
// "built login url path:",
// props.govGateway.config.authorization_endpoint +
// "?response_type=code&scope=openid&client_id=" +
// GG_CLIENT_ID +
// "&redirect_uri=" +
// GG_REDIRECT_URI +
// "&ui_locales=" +
// (router.locale == "cy" ? "cy" : "en-GB")
// );
// let spinnerState = () => { // let spinnerState = () => {
// showSpinnerState == true // showSpinnerState == true
// ? setShowSpinnerState(false) // ? setShowSpinnerState(false)
@@ -412,7 +394,6 @@ const mapStateToProps = (state) => {
watchedCases: state.watchedCases, watchedCases: state.watchedCases,
myRepresentations: state.myRepresentations, myRepresentations: state.myRepresentations,
awaitingSubmission: state.awaitingSubmission, awaitingSubmission: state.awaitingSubmission,
govGateway: state.govGateway,
}; };
}; };
+2 -6
View File
@@ -12,7 +12,7 @@ import Dns from "./homepage/dns";
const MainHome = (props) => { const MainHome = (props) => {
let { t } = useTranslation(); let { t } = useTranslation();
const { showLogin, GG_REDIRECT_URI, GG_CLIENT_ID, session } = props; const { showLogin, session } = props;
const router = useRouter(); const router = useRouter();
const { locale } = router; const { locale } = router;
@@ -34,11 +34,7 @@ const MainHome = (props) => {
{showLogin == "true" && ( {showLogin == "true" && (
<> <>
<CaseSearch /> <CaseSearch />
<Login <Login session={session} />
GG_CLIENT_ID={GG_CLIENT_ID}
GG_REDIRECT_URI={GG_REDIRECT_URI}
session={session}
/>
</> </>
)}{" "} )}{" "}
<CaseComment /> <CaseComment />
+1 -2
View File
@@ -26,7 +26,6 @@ const MyPortal = (props) => {
console.info("////////////\n" + "logout" + "\n////////////"); console.info("////////////\n" + "logout" + "\n////////////");
destroyCookie({}, "pinsUser"), destroyCookie({}, "pinsUser"),
window.localStorage.clear(), window.localStorage.clear(),
//router.replace(props.ggLogout);
signOut({ callbackUrl: "/logout" }); signOut({ callbackUrl: "/logout" });
}; };
@@ -143,7 +142,7 @@ const MyPortal = (props) => {
</div> </div>
</div> </div>
</main> </main>
<TimeOut ggLogout={props.ggLogout} /> <TimeOut />
</> </>
); );
}; };
+1 -1
View File
@@ -457,7 +457,7 @@ let AboutYou = (props) => {
useEffect(() => { useEffect(() => {
handlePartialUpdate(); handlePartialUpdate();
}, [appellantAgentValue]); });
return ( return (
<form onSubmit={handleSubmit(onHandleSubmit)}> <form onSubmit={handleSubmit(onHandleSubmit)}>
-22
View File
@@ -27,28 +27,6 @@ let BuildSection = (props) => {
const [savingStatus, setSavingStatus] = useState(false); const [savingStatus, setSavingStatus] = useState(false);
useEffect(() => {
progObj = getProgressObj(
formXML,
titleList,
mandatoryFieldsData,
props
);
// const lastIndex = progObj
// .map((whichIsLast) => whichIsLast.allFieldsComplete == true)
// .lastIndexOf(true);
// setCurrentSection(currentSectionSelected + 1);
// pickupWhereLeftOff == true && setCurrentSection(lastIndex + 1),
// setPickupWhereLeftOff(false);
// // lastIndex != currentSectionSelected
// // ? (setCurrentSectionSelected(lastIndex),
// // setPickupWhereLeftOff(true))
// // : setPickupWhereLeftOff(false);
});
let { t } = useTranslation(); let { t } = useTranslation();
const router = useRouter(); const router = useRouter();
+51
View File
@@ -0,0 +1,51 @@
import axios from "axios";
import CryptoJS from "crypto-js";
import _ from "lodash";
import { getToken, azureHeadersPaged, consoleLogger } from "../../../actions";
const WORDKEY = process.env.HASHKEY;
const WEBAPI_URL =
process.env.RELAY_ROOT ||
"https://dev-pedw-ns.servicebus.windows.net/dev-pedw-hc/";
const hashAPIPath = (queryPath) => {
var hashlink = CryptoJS.HmacSHA256(
queryPath,
CryptoJS.enc.Hex.parse(WORDKEY)
);
hashlink = hashlink.toString(CryptoJS.enc.Hex);
return (queryPath.indexOf("?") > -1 ? "&hash=" : "?hash=") + hashlink;
};
export default async function ApiProxy(req, res) {
var emailAddress = req.query.emailAddress;
var token = await getToken();
var queryUrl =
"contacts?$filter=emailaddress1 eq '" +
emailAddress +
"'&$count=true&$select=emailaddress1,contactid,yomifullname,firstname,lastname";
//console.log(req.query);
var apiResponse = _.isEmpty(req.query)
? res.status(400).json()
: typeof emailAddress != "undefined" && emailAddress.length > 0
? axios
.get(
WEBAPI_URL + queryUrl + hashAPIPath(queryUrl),
azureHeadersPaged(token.access_token)
)
.then(({ data }) => {
console.log(data);
res.status(200).json(data);
})
.catch((err) => {
console.log(consoleLogger(err));
res.status(400).json(err);
})
: res.status(400).json();
return apiResponse;
}
@@ -63,7 +63,7 @@ export default async function ApiProxy(req, res) {
? "&$skiptoken=" + ('<cookie pagenumber="' + pageNumber + '" />') ? "&$skiptoken=" + ('<cookie pagenumber="' + pageNumber + '" />')
: ""); : "");
console.log("docu paged: ", queryUrl); //console.log("docu paged: ", queryUrl);
return axios return axios
.get( .get(
@@ -1,41 +0,0 @@
import axios from "axios";
import CryptoJS from "crypto-js";
import { getToken, azureHeaders, consoleLogger } from "../../../actions";
const WORDKEY = process.env.HASHKEY;
const WEBAPI_URL =
process.env.RELAY_ROOT ||
"https://dev-pedw-ns.servicebus.windows.net/dev-pedw-hc/";
const hashAPIPath = (queryPath) => {
var hashlink = CryptoJS.HmacSHA256(
queryPath,
CryptoJS.enc.Hex.parse(WORDKEY)
);
hashlink = hashlink.toString(CryptoJS.enc.Hex);
return (queryPath.indexOf("?") > -1 ? "&hash=" : "?hash=") + hashlink;
};
export default async function ApiProxy(req, res) {
var loggedInUserId = req.query.loggedInUserId;
var token = await getToken();
var queryUrl =
"pinswg_watchlists?$filter= _pinswg_contact_value eq " +
loggedInUserId +
"&$count=true&$orderby=createdon desc";
return axios
.get(
WEBAPI_URL + queryUrl + hashAPIPath(queryUrl),
azureHeaders(token.access_token)
)
.then(({ data }) => {
res.status(200).json(data);
})
.catch((err) => {
console.log(consoleLogger(err));
res.status(400).json(err);
});
}
@@ -17,7 +17,11 @@ ApiProxy.get(async (req, res) => {
var checkquerypath = var checkquerypath =
"/api/file/getawaitingsubmissionfromblob?container=" + containerName; "/api/file/getawaitingsubmissionfromblob?container=" + containerName;
console.log("///////////\ngetawaitingsubmissionblob url :", req.url); console.log(
"///////////////////////\ngetawaitingsubmissionblob url :",
req.url,
"\n///////////////////////\n"
);
// console.log(hashAPIPath(checkquerypath), checkHash); // console.log(hashAPIPath(checkquerypath), checkHash);
// console.log(hashAPIPath(checkquerypath) == "&hash=" + checkHash); // console.log(hashAPIPath(checkquerypath) == "&hash=" + checkHash);
-159
View File
@@ -1,159 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"value": [
{
"@odata.etag": 'W/"547952"',
"lpaname": "Vale of Glamorgan Council",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "21 Courtenay Road",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00017-B8X7N0",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue": "",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary": "",
"caseOfficer": "",
"procedure": "",
"status": "",
"decision": "",
"outcome_document": "",
"caseLinkStatus": "",
"linkedCases": "",
},
"caseDates": {
"start_date": "",
"questionnaireDue": "",
"statementsDue": "",
"interestedPartyCommentsdue": "",
"appellantLPAFinalCommentsdue": "",
"inquiryEvidenceDue": "",
"eventDate": "",
"decisionDate": "",
},
},
{
"@odata.etag": 'W/"547952"',
"lpaname": "Bridgend CBC",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "17 Colin Way",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00016-Y9K9Q0",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary": "",
"caseOfficer": "",
"procedure": "",
"status": "",
"decision": "",
"outcome_document": "",
"caseLinkStatus": "",
"linkedCases": "",
},
"caseDates": {
"start_date": "",
"questionnaireDue": "",
"statementsDue": "",
"interestedPartyCommentsdue": "",
"appellantLPAFinalCommentsdue": "",
"inquiryEvidenceDue": "",
"eventDate": "",
"decisionDate": "",
},
},
{
"@odata.etag": 'W/"547952"',
"lpaname": "Cardiff County Council Planning (A)",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "120 Severn Grove",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00011-K1N0J8",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary": "",
"caseOfficer": "",
"procedure": "",
"status": "",
"decision": "",
"outcome_document": "",
"caseLinkStatus": "",
"linkedCases": "",
},
"caseDates": {
"start_date": "",
"questionnaireDue": "",
"statementsDue": "",
"interestedPartyCommentsdue": "",
"appellantLPAFinalCommentsdue": "",
"inquiryEvidenceDue": "",
"eventDate": "",
"decisionDate": "",
},
},
{
"@odata.etag": 'W/"547952"',
"lpaname": "Cardiff County Council Planning",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "25 Merches Gardens",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00015-L7J9H1",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary": "",
"caseOfficer": "",
"procedure": "",
"status": "",
"decision": "",
"outcome_document": "",
"caseLinkStatus": "",
"linkedCases": "",
},
"caseDates": {
"start_date": "",
"questionnaireDue": "",
"statementsDue": "",
"interestedPartyCommentsdue": "",
"appellantLPAFinalCommentsdue": "",
"inquiryEvidenceDue": "",
"eventDate": "",
"decisionDate": "",
},
},
],
});
};
export default ApiResponse;
-164
View File
@@ -1,164 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"value": [
{
"@odata.etag": "W547952",
"lpaname": "Vale of Glamorgan Council",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "21 Courtenay Road",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00009-W8N6W4",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
{
"@odata.etag": "W547952",
"lpaname": "Bridgend CBC",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "17 Colin Way",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00010-J9W6L5",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
{
"@odata.etag": "W547952",
"lpaname": "Cardiff County Council Planning (A)",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "120 Severn Grove",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00011-K1N0J8",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Conditions - S73 + S79",
"pinswg_appealcasetype": "846040001",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
{
"@odata.etag": "W547952",
"lpaname": "Cardiff County Council Planning",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "25 Merches Gardens",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00012-D9W6S8",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
],
});
};
export default ApiResponse;
-164
View File
@@ -1,164 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"value": [
{
"@odata.etag": 'W/"547952"',
"lpaname": "Vale of Glamorgan Council",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "21 Courtenay Road",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00009-W8N6W4",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
{
"@odata.etag": 'W/"547952"',
"lpaname": "Bridgend CBC",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "17 Colin Way",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00010-J9W6L5",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
{
"@odata.etag": 'W/"547952"',
"lpaname": "Cardiff County Council Planning (A)",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "120 Severn Grove",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00011-K1N0J8",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
{
"@odata.etag": 'W/"547952"',
"lpaname": "Cardiff County Council Planning",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "25 Merches Gardens",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00012-D9W6S8",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
],
});
};
export default ApiResponse;
-17
View File
@@ -1,17 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
data: {
firstname: "Steve",
lastname: "Johnson",
email: "steve@test.co.uk",
telephone: "0000000000",
companygroup: "Test Company",
addressline1: "1 Test Street",
towncity: "TestTown",
county: "Test County",
postcode: "TN12 12N",
},
});
};
export default ApiResponse;
File diff suppressed because it is too large Load Diff
-251
View File
@@ -1,251 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"@odata.context":
"https://devcrm2016.llcdt.gov.wales/DVPINS/api/data/v8.2/$metadata#EntityDefinitions('pinswg_householderappealhas')/Attributes/Microsoft.Dynamics.CRM.PicklistAttributeMetadata(LogicalName,GlobalOptionSet,GlobalOptionSet(Options))/$entity",
"LogicalName": "pinswg_appointedby",
"MetadataId": "3c10eef7-6f85-eb11-aac2-00224800be9c",
"GlobalOptionSet": {
"@odata.type": "#Microsoft.Dynamics.CRM.OptionSetMetadata",
"Options": [
{
"Value": 846040000,
"Label": {
"LocalizedLabels": [
{
"Label": "MHCLG",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"899c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "MHCLG",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"899c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"8b9c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"8b9c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040001,
"Label": {
"LocalizedLabels": [
{
"Label": "Welsh Government",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"8c9c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Welsh Government",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"8c9c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"8e9c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"8e9c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040003,
"Label": {
"LocalizedLabels": [
{
"Label": "Secretary of State for Transport",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"929c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Secretary of State for Transport",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"929c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"949c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"949c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040004,
"Label": {
"LocalizedLabels": [
{
"Label": "BEIS",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"959c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "BEIS",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"959c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"979c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"979c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040005,
"Label": {
"LocalizedLabels": [
{
"Label": "Council",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"989c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Council",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"989c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"9a9c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"9a9c9260-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
],
"MetadataId": "869c9260-3683-eb11-aac0-00224800be9c",
},
});
};
export default ApiResponse;
-157
View File
@@ -1,157 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"@odata.context":
"https://devcrm2016.llcdt.gov.wales/DVPINS/api/data/v8.2/$metadata#EntityDefinitions('pinswg_householderappealhas')/Attributes/Microsoft.Dynamics.CRM.PicklistAttributeMetadata(LogicalName,GlobalOptionSet,GlobalOptionSet(Options))/$entity",
"LogicalName": "pinswg_band",
"MetadataId": "bddafa01-7085-eb11-aac2-00224800be9c",
"GlobalOptionSet": {
"@odata.type": "#Microsoft.Dynamics.CRM.OptionSetMetadata",
"Options": [
{
"Value": 846040000,
"Label": {
"LocalizedLabels": [
{
"Label": "Band 1",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"3d8e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Band 1",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"3d8e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"3f8e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"3f8e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040001,
"Label": {
"LocalizedLabels": [
{
"Label": "Band 2",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"408e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Band 2",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"408e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"428e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"428e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040002,
"Label": {
"LocalizedLabels": [
{
"Label": "Band 3",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"438e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Band 3",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"438e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"458e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"458e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
],
"MetadataId": "3a8e4173-3683-eb11-aac0-00224800be9c",
},
});
};
export default ApiResponse;
-441
View File
@@ -1,441 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"@odata.context":
"https://devcrm2016.llcdt.gov.wales/DVPINS/api/data/v8.2/$metadata#EntityDefinitions('pinswg_householderappealhas')/Attributes/Microsoft.Dynamics.CRM.PicklistAttributeMetadata(LogicalName,GlobalOptionSet,GlobalOptionSet(Options))/$entity",
"LogicalName": "pinswg_casetype",
"MetadataId": "fa824014-7085-eb11-aac2-00224800be9c",
"GlobalOptionSet": {
"@odata.type": "#Microsoft.Dynamics.CRM.OptionSetMetadata",
"Options": [
{
"Value": 846040000,
"Label": {
"LocalizedLabels": [
{
"Label": "Planning Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"fd6d05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Planning Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"fd6d05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"ff6d05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"ff6d05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040001,
"Label": {
"LocalizedLabels": [
{
"Label":
"Listed Building Conservation Area Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"006e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Listed Building Conservation Area Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"006e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"026e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"026e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040002,
"Label": {
"LocalizedLabels": [
{
"Label": "Planning Conditions Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"036e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Planning Conditions Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"036e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"056e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"056e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040003,
"Label": {
"LocalizedLabels": [
{
"Label": "Planning Obligations Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"066e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Planning Obligations Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"066e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"086e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"086e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040004,
"Label": {
"LocalizedLabels": [
{
"Label": "Householder/Minor Commercial Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"096e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Householder/Minor Commercial Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"096e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"0b6e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"0b6e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040005,
"Label": {
"LocalizedLabels": [
{
"Label": "Advertisement Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"0c6e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Advertisement Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"0c6e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"0e6e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"0e6e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040006,
"Label": {
"LocalizedLabels": [
{
"Label":
"Lawful Development Certificate Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"0f6e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Lawful Development Certificate Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"0f6e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"116e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"116e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040007,
"Label": {
"LocalizedLabels": [
{
"Label": "Community Infrastructure Levy Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"126e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Community Infrastructure Levy Appeal",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"126e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"146e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"146e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040008,
"Label": {
"LocalizedLabels": [
{
"Label": "Call-In Application",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"156e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Call-In Application",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"156e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"176e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"176e05d7-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
],
"MetadataId": "fa6d05d7-3683-eb11-aac0-00224800be9c",
},
});
};
export default ApiResponse;
-157
View File
@@ -1,157 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"@odata.context":
"https://devcrm2016.llcdt.gov.wales/DVPINS/api/data/v8.2/$metadata#EntityDefinitions('pinswg_householderappealhas')/Attributes/Microsoft.Dynamics.CRM.PicklistAttributeMetadata(LogicalName,GlobalOptionSet,GlobalOptionSet(Options))/$entity",
"LogicalName": "pinswg_band",
"MetadataId": "bddafa01-7085-eb11-aac2-00224800be9c",
"GlobalOptionSet": {
"@odata.type": "#Microsoft.Dynamics.CRM.OptionSetMetadata",
"Options": [
{
"Value": 846040000,
"Label": {
"LocalizedLabels": [
{
"Label": "Band 1",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"3d8e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Band 1",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"3d8e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"3f8e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"3f8e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040001,
"Label": {
"LocalizedLabels": [
{
"Label": "Band 2",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"408e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Band 2",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"408e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"428e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"428e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040002,
"Label": {
"LocalizedLabels": [
{
"Label": "Band 3",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"438e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Band 3",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"438e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"458e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"458e4173-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
],
"MetadataId": "3a8e4173-3683-eb11-aac0-00224800be9c",
},
});
};
export default ApiResponse;
-204
View File
@@ -1,204 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"@odata.context":
"https://devcrm2016.llcdt.gov.wales/DVPINS/api/data/v8.2/$metadata#EntityDefinitions('pinswg_householderappealhas')/Attributes/Microsoft.Dynamics.CRM.PicklistAttributeMetadata(LogicalName,GlobalOptionSet,GlobalOptionSet(Options))/$entity",
"LogicalName": "pinswg_decision",
"MetadataId": "3e383643-7085-eb11-aac2-00224800be9c",
"GlobalOptionSet": {
"@odata.type": "#Microsoft.Dynamics.CRM.OptionSetMetadata",
"Options": [
{
"Value": 846040000,
"Label": {
"LocalizedLabels": [
{
"Label": "Allowed",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"4de653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Allowed",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"4de653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"4fe653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"4fe653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040001,
"Label": {
"LocalizedLabels": [
{
"Label": "Dismissed",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"50e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Dismissed",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"50e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"52e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"52e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040002,
"Label": {
"LocalizedLabels": [
{
"Label": "Split Decision",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"53e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Split Decision",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"53e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"55e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"55e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040003,
"Label": {
"LocalizedLabels": [
{
"Label": "Invalid",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"56e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Invalid",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"56e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"58e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"58e653f8-3683-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
],
"MetadataId": "4ae653f8-3683-eb11-aac0-00224800be9c",
},
});
};
export default ApiResponse;
-347
View File
@@ -1,347 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"@odata.context":
"https://devcrm2016.llcdt.gov.wales/DVPINS/api/data/v8.2/$metadata#EntityDefinitions('pinswg_householderappealhas')/Attributes/Microsoft.Dynamics.CRM.PicklistAttributeMetadata(LogicalName,GlobalOptionSet,GlobalOptionSet(Options))/$entity",
"LogicalName": "pinswg_decisionbranch",
"MetadataId": "15429e52-7085-eb11-aac2-00224800be9c",
"GlobalOptionSet": {
"@odata.type": "#Microsoft.Dynamics.CRM.OptionSetMetadata",
"Options": [
{
"Value": 846040000,
"Label": {
"LocalizedLabels": [
{
"Label": "The Welsh Ministers",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"a9d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "The Welsh Ministers",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"a9d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"abd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"abd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040001,
"Label": {
"LocalizedLabels": [
{
"Label": "PINS",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"acd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "PINS",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"acd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"aed887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"aed887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040002,
"Label": {
"LocalizedLabels": [
{
"Label": "BEIS",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"afd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "BEIS",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"afd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b1d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b1d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040003,
"Label": {
"LocalizedLabels": [
{
"Label": "Department for Transport",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b2d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "Department for Transport",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b2d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b4d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b4d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040004,
"Label": {
"LocalizedLabels": [
{
"Label": "County Council",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b5d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "County Council",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b5d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b7d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b7d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040005,
"Label": {
"LocalizedLabels": [
{
"Label":
"Department for Transport (Bridges and Ferries)",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b8d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label":
"Department for Transport (Bridges and Ferries)",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"b8d887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"bad887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"bad887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
{
"Value": 846040006,
"Label": {
"LocalizedLabels": [
{
"Label": "MHCLG",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"bbd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "MHCLG",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"bbd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Description": {
"LocalizedLabels": [
{
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"bdd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
],
"UserLocalizedLabel": {
"Label": "",
"LanguageCode": 1033,
"IsManaged": false,
"MetadataId":
"bdd887c2-3783-eb11-aac0-00224800be9c",
"HasChanged": null,
},
},
"Color": "#0000ff",
"IsManaged": false,
"MetadataId": null,
"HasChanged": null,
},
],
"MetadataId": "a6d887c2-3783-eb11-aac0-00224800be9c",
},
});
};
export default ApiResponse;
-161
View File
@@ -1,161 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"@odata.context":
"https://devcrm2016.llcdt.gov.wales/DVPINS/api/data/v8.2/$metadata#accounts(name)",
"@odata.count": 30,
"value": [
{
"@odata.etag": 'W/"547952"',
"name": "Bridgend CBC",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
},
{
"@odata.etag": 'W/"694923"',
"name": "Bishop Landaff High School",
"accountid": "c9389617-82ad-eb11-aac3-00224800be9c",
},
{
"@odata.etag": 'W/"694925"',
"name": "Stanwell High school",
"accountid": "24537624-82ad-eb11-aac3-00224800be9c",
},
{
"@odata.etag": 'W/"762163"',
"name": "Barry Boys High School",
"accountid": "80d99a34-82ad-eb11-aac3-00224800be9c",
},
{
"@odata.etag": 'W/"694929"',
"name": "St Sirus High School",
"accountid": "6d337b5a-82ad-eb11-aac3-00224800be9c",
},
{
"@odata.etag": 'W/"694931"',
"name": "Fitzalan High School",
"accountid": "984d0e75-82ad-eb11-aac3-00224800be9c",
},
{
"@odata.etag": 'W/"757759"',
"name": "Zoe",
"accountid": "41fead24-29ba-eb11-aac4-00224800be9c",
},
{
"@odata.etag": 'W/"755100"',
"name": "Blaenau Gwent County Borough Council",
"accountid": "744c69f4-48da-eb11-aac5-00224800be9c",
},
{
"@odata.etag": 'W/"755102"',
"name": "Caerphilly County Borough Council",
"accountid": "243c0009-49da-eb11-aac5-00224800be9c",
},
{
"@odata.etag": 'W/"757756"',
"name": "Test 2",
"accountid": "bf14b684-8ee0-eb11-aac5-00224800be9c",
},
{
"@odata.etag": 'W/"755104"',
"name": "Bridgend County Borough Council",
"accountid": "c35f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755106"',
"name": "Cardiff Council",
"accountid": "c75f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755108"',
"name": "Carmarthenshire County Council",
"accountid": "c95f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755110"',
"name": "Ceredigion County Council",
"accountid": "cb5f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755112"',
"name": "Conwy County Borough Council",
"accountid": "cd5f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755114"',
"name": "Denbighshire County Council",
"accountid": "cf5f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755116"',
"name": "Flintshire County Council",
"accountid": "d15f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755118"',
"name": "Gwynedd Council",
"accountid": "d35f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755120"',
"name": "Isle of Anglesey County Council",
"accountid": "d55f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755122"',
"name": "Merthyr Tydfil County Borough Council",
"accountid": "d75f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755124"',
"name": "Monmouthshire County Council",
"accountid": "d95f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755126"',
"name": "Neath Port Talbot County Borough Council",
"accountid": "db5f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755128"',
"name": "Newport City Council",
"accountid": "dd5f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755130"',
"name": "Pembrokeshire County Council",
"accountid": "df5f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755132"',
"name": "Powys County Council",
"accountid": "e15f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755134"',
"name": "Rhondda Cynon Taf County Borough Council",
"accountid": "e35f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755136"',
"name": "Swansea Council",
"accountid": "e55f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755138"',
"name": "Torfaen County Borough Council",
"accountid": "e75f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755140"',
"name": "Vale of Glamorgan Council",
"accountid": "e95f6f84-49da-eb11-aabd-00224800d1bd",
},
{
"@odata.etag": 'W/"755142"',
"name": "Wrexham County Borough Council",
"accountid": "eb5f6f84-49da-eb11-aabd-00224800d1bd",
},
],
});
};
export default ApiResponse;
-164
View File
@@ -1,164 +0,0 @@
const ApiResponse = (req, res) => {
res.statusCode = 200;
res.json({
"value": [
{
"@odata.etag": 'W/"547952"',
"lpaname": "Vale of Glamorgan Council",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "21 Courtenay Road",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00009-W8N6W4",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
{
"@odata.etag": 'W/"547952"',
"lpaname": "Bridgend CBC",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "17 Colin Way",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00010-J9W6L5",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
{
"@odata.etag": 'W/"547952"',
"lpaname": "Cardiff County Council Planning (A)",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "120 Severn Grove",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00011-K1N0J8",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
{
"@odata.etag": 'W/"547952"',
"lpaname": "Cardiff County Council Planning",
"accountid": "56e7ef63-7e64-eb11-aaba-00224800be9c",
"address1": "25 Merches Gardens",
"town": "Cardiff",
"postcode": "CF24 0JL",
"reference": "CAS-00012-D9W6S8",
"appellantApplicant": "Mrs Denise Williams",
"pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue":
"Planning Appeal - S78",
"pinswg_appealcasetype": "846040000",
"statuscode@OData.Community.Display.V1.FormattedValue":
"In Progress",
"statuscode": "1",
"caseDetails": {
"casetype": "",
"lpa": "",
"caseSummary":
"Erection of a two-storey chalet style detached dwelling",
"caseOfficer": "Neale Oliver",
"procedure": "Written representations",
"status": "In progress",
"decision": "Allowed",
"outcome_document": "23424Appeal Decision.pdf",
"caseLinkStatus": "not linked",
"linkedCases": "none",
},
"caseDates": {
"start_date": "26-May-21",
"questionnaireDue": "02-Jun-21",
"statementsDue": "30-Jun-21",
"interestedPartyCommentsdue": "30-Jun-21",
"appellantLPAFinalCommentsdue": "4-Jul-21",
"inquiryEvidenceDue": "N/A",
"eventDate": "Date arranged",
"decisionDate": "Not yet decided",
},
},
],
});
};
export default ApiResponse;
-36
View File
@@ -1,36 +0,0 @@
import nextConnect from "next-connect";
import multer from "multer";
const upload = multer({
storage: multer.diskStorage({
destination: "./public/uploads",
filename: (req, file, cb) => cb(null, file.originalname),
}),
});
const apiRoute = nextConnect({
onError(error, req, res) {
console.log("booo", req.data);
res.status(501).json({
error: `Sorry something Happened! ${error.message}`,
});
},
onNoMatch(req, res) {
res.status(405).json({ error: `Method '${req.method}' Not Allowed` });
},
});
apiRoute.use(upload.array("fileList"));
apiRoute.post((req, res) => {
res.status(200).json({ data: "success" });
});
export default apiRoute;
export const config = {
api: {
bodyParser: false, // Disallow body parsing, consume as stream
},
};
+21 -75
View File
@@ -4,13 +4,7 @@ import Head from "next/head";
import { useRouter } from "next/router"; import { useRouter } from "next/router";
import { setCookie } from "nookies"; import { setCookie } from "nookies";
import { connect } from "react-redux"; import { connect } from "react-redux";
import { getNotice, getToken, hashString } from "../actions"; import { getNotice, getToken, hashString, getPortalLogin } from "../actions";
import {
getGGToken,
getPortalLogin,
getProviderConfig,
getUserInfo,
} from "../actions/govgateway";
import CookieBanner from "../components/cookieBanner"; import CookieBanner from "../components/cookieBanner";
import Footer from "../components/footer"; import Footer from "../components/footer";
import Header from "../components/header"; import Header from "../components/header";
@@ -21,7 +15,6 @@ import {
setAccountDetails, setAccountDetails,
setContainerID, setContainerID,
} from "../store/accountDetails/action"; } from "../store/accountDetails/action";
import { getGovGatewayConfig } from "../store/govgateway/action";
import { wrapper } from "../store/store"; import { wrapper } from "../store/store";
import { getSession, useSession, signIn, signOut } from "next-auth/react"; import { getSession, useSession, signIn, signOut } from "next-auth/react";
@@ -32,10 +25,8 @@ const Home = (props) => {
showLogin, showLogin,
showMap, showMap,
loggedInUserId, loggedInUserId,
hasGGCode,
loginEmailStr, loginEmailStr,
loggedInUserEmail, loggedInUserEmail,
ggLocale,
hasLoginCode, hasLoginCode,
noticeContent, noticeContent,
} = props; } = props;
@@ -74,9 +65,7 @@ const Home = (props) => {
}), }),
router.replace({ router.replace({
pathname: pathname:
router.locale == "cy" || ggLocale == "cy" router.locale == "cy" ? "/cy/fymhorth" : "/myportal",
? "/cy/fymhorth"
: "/myportal",
})) }))
: console.log("no value in user id"); : console.log("no value in user id");
@@ -156,16 +145,8 @@ const Home = (props) => {
<div className="govuk-width-container"> <div className="govuk-width-container">
{hasLoginCode ? ( {hasLoginCode ? (
<> <>
<h1> <h1>{t("home:logging-in-heading")}</h1>
{ggLocale == "cy" <h2>{t("home:logging-in-paragraph")}</h2>
? "Mewngofnodi"
: "Logging in"}
</h1>
<h2>
{ggLocale == "cy"
? "Arhoswch os gwelwch yn dda..."
: "Please wait..."}
</h2>
</> </>
) : ( ) : (
<> <>
@@ -174,13 +155,10 @@ const Home = (props) => {
<NoticeBanner noticeContent={noticeContent} /> <NoticeBanner noticeContent={noticeContent} />
)} )}
<Main <Main
ggLocale={ggLocale}
pages={pages} pages={pages}
showLogin={showLogin} showLogin={showLogin}
showMap={showMap} showMap={showMap}
loggedInUserId={loggedInUserId} loggedInUserId={loggedInUserId}
// GG_REDIRECT_URI={props.GG_REDIRECT_URI}
// GG_CLIENT_ID={props.GG_CLIENT_ID}
/> />
</> </>
)} )}
@@ -200,7 +178,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
var relayToken = await getToken(); var relayToken = await getToken();
relayToken = relayToken.access_token; relayToken = relayToken.access_token;
console.log("\n///////////////\nauth sess:", thisSession); console.log("\n////////////////////\nauth sess:", thisSession);
const showLoginCheck = process.env.SHOWLOGIN || false; const showLoginCheck = process.env.SHOWLOGIN || false;
const showMapCheck = process.env.SHOWMAPS || false; const showMapCheck = process.env.SHOWMAPS || false;
@@ -209,13 +187,10 @@ export const getServerSideProps = wrapper.getServerSideProps(
console.log("server side has session:", thisSession != null); console.log("server side has session:", thisSession != null);
// let providerConfig = await getProviderConfig();
let ggLocale = let ggLocale =
typeof query.ui_locales != "undefined" && query.ui_locales; typeof query.ui_locales != "undefined" && query.ui_locales;
console.log("hasloginCode:", hasLoginCode); console.log("hasloginCode:", hasLoginCode + "\n////////////////////\n");
// store.dispatch(getGovGatewayConfig(providerConfig));
const noticeContent = await getNotice(); const noticeContent = await getNotice();
@@ -228,50 +203,22 @@ export const getServerSideProps = wrapper.getServerSideProps(
loginEmailStr = hashString(thisSession.user.email); loginEmailStr = hashString(thisSession.user.email);
store.dispatch(setContainerID(thisSession.user.id)); store.dispatch(setContainerID(thisSession.user.id));
portalUserObj = await getPortalLogin( portalUserObj = await getPortalLogin(thisSession.user.email);
thisSession.user.email, } else {
relayToken console.log("///////////////\nempty session \n///////////////\n");
); }
if (_.has(portalUserObj, "status") != false) { return {
if (portalUserObj.status == 400) { props: {
return { showLogin: showLoginCheck,
redirect: { showMap: showMapCheck,
//destination: "/dns-not-found", hasSession: hasLoginCode,
destination: "/error", loggedInUserId: portalUserObj,
permanent: false, loggedInUserEmail: loginEmailStr,
}, hasLoginCode: hasLoginCode,
}; noticeContent: noticeContent,
} else { },
console.log("loggin user stuff: ", portalUserObj); };
store.dispatch(setAccountDetails(portalUserObj));
}
}
} else {
console.log("empty session");
}
console.log("///////////////\n");
if (ggToken.status == 400) {
return {
redirect: {
destination: "/myportal/error",
permanent: false,
},
};
} else {
return {
props: {
ggLocale: ggLocale,
showLogin: showLoginCheck,
showMap: showMapCheck,
hasSession: hasLoginCode,
loggedInUserId: portalUserObj,
loggedInUserEmail: loginEmailStr,
hasLoginCode: hasLoginCode,
noticeContent: noticeContent,
},
};
}
} }
); );
@@ -287,7 +234,6 @@ const mapStateToProps = (state) => {
watchedCases: state.watchedCases, watchedCases: state.watchedCases,
myRepresentations: state.myRepresentations, myRepresentations: state.myRepresentations,
awaitingSubmission: state.awaitingSubmission, awaitingSubmission: state.awaitingSubmission,
govGateway: state.govGateway,
}; };
}; };
export default connect(mapStateToProps)(Home); export default connect(mapStateToProps)(Home);
+1 -6
View File
@@ -14,7 +14,6 @@ import {
getFilesFromBlob, getFilesFromBlob,
getProgressFromBlob, getProgressFromBlob,
} from "../../actions"; } from "../../actions";
import { getProviderConfig } from "../../actions/govgateway";
import Breadcrumbs from "../../components/breadcrumbs"; import Breadcrumbs from "../../components/breadcrumbs";
import CookieBanner from "../../components/cookieBanner"; import CookieBanner from "../../components/cookieBanner";
import Footer from "../../components/footer"; import Footer from "../../components/footer";
@@ -38,7 +37,6 @@ import {
setFilesForAppeal, setFilesForAppeal,
} from "../../store/appealType/action"; } from "../../store/appealType/action";
import { setForm } from "../../store/formData/action"; import { setForm } from "../../store/formData/action";
import { getGovGatewayConfig } from "../../store/govgateway/action";
import { wrapper } from "../../store/store"; import { wrapper } from "../../store/store";
import { getPartSavedDetails } from "../../components/utils"; import { getPartSavedDetails } from "../../components/utils";
import { getProgressBlobs } from "../../actions/azurestorage"; import { getProgressBlobs } from "../../actions/azurestorage";
@@ -208,7 +206,7 @@ let Home = (props) => {
</div> </div>
<Footer footerLinks={footerLinks} /> <Footer footerLinks={footerLinks} />
</div> </div>
<TimeOut ggLogout={props.govGateway.config.end_session_endpoint} /> <TimeOut />
</div> </div>
); );
}; };
@@ -286,8 +284,6 @@ export const getServerSideProps = wrapper.getServerSideProps(
xmlStr = xmlStr.replace(/> <"/g, "><"); xmlStr = xmlStr.replace(/> <"/g, "><");
xmlStr = xmlStr.toString(); xmlStr = xmlStr.toString();
const providerConfig = await getProviderConfig();
store.dispatch(getGovGatewayConfig(providerConfig));
store.dispatch(setLoggedInUserId(loggedInUser)); store.dispatch(setLoggedInUserId(loggedInUser));
store.dispatch(setLoggedInUserEmail(loggedInUserEmail)); store.dispatch(setLoggedInUserEmail(loggedInUserEmail));
store.dispatch(setAppealLPA(query.lpa)); store.dispatch(setAppealLPA(query.lpa));
@@ -313,7 +309,6 @@ const mapStateToProps = (state) => {
appealType: state.appealType, appealType: state.appealType,
form: state.form, form: state.form,
accountDetails: state.accountDetails, accountDetails: state.accountDetails,
govGateway: state.govGateway,
awaitingSubmission: state.awaitingSubmission, awaitingSubmission: state.awaitingSubmission,
currentView: state.currentView, currentView: state.currentView,
}; };
+1 -6
View File
@@ -4,7 +4,6 @@ import Head from "next/head";
import { useRouter } from "next/router"; import { useRouter } from "next/router";
import { connect } from "react-redux"; import { connect } from "react-redux";
import { getAppealsTypes, getLPA, getPersonalAccount } from "../../actions"; import { getAppealsTypes, getLPA, getPersonalAccount } from "../../actions";
import { getProviderConfig } from "../../actions/govgateway";
import Breadcrumbs from "../../components/breadcrumbs"; import Breadcrumbs from "../../components/breadcrumbs";
import CookieBanner from "../../components/cookieBanner"; import CookieBanner from "../../components/cookieBanner";
import CRMError from "../../components/crmError"; import CRMError from "../../components/crmError";
@@ -13,7 +12,6 @@ import Header from "../../components/header";
import Search from "../../components/search"; import Search from "../../components/search";
import TimeOut from "../../components/timeout"; import TimeOut from "../../components/timeout";
import { setAppealType } from "../../store/appealType/action"; import { setAppealType } from "../../store/appealType/action";
import { getGovGatewayConfig } from "../../store/govgateway/action";
import { setLPA } from "../../store/lpa/action"; import { setLPA } from "../../store/lpa/action";
import { wrapper } from "../../store/store"; import { wrapper } from "../../store/store";
import { getSession, useSession } from "next-auth/react"; import { getSession, useSession } from "next-auth/react";
@@ -61,7 +59,7 @@ const Home = (props) => {
</div> </div>
<Footer footerLinks={footerLinks} /> <Footer footerLinks={footerLinks} />
</div> </div>
<TimeOut ggLogout={props.govGateway.config.end_session_endpoint} /> <TimeOut />
</div> </div>
); );
}; };
@@ -82,8 +80,6 @@ export const getServerSideProps = wrapper.getServerSideProps(
await getAppealsTypes(), await getAppealsTypes(),
await getLPA(), await getLPA(),
]); ]);
const providerConfig = await getProviderConfig();
store.dispatch(getGovGatewayConfig(providerConfig));
// const lpaData = require("../../data/lpa.json"); // const lpaData = require("../../data/lpa.json");
// const appealTypeData = require("../../data/appealtypes.json"); // const appealTypeData = require("../../data/appealtypes.json");
@@ -104,7 +100,6 @@ const mapStateToProps = (state) => {
LPAData: state.LPAData, LPAData: state.LPAData,
//form: state.form, //form: state.form,
accountDetails: state.accountDetails, accountDetails: state.accountDetails,
govGateway: state.govGateway,
}; };
}; };
+2 -6
View File
@@ -27,8 +27,6 @@ import {
setWatchedCasesDetails, setWatchedCasesDetails,
} from "../../store/watchedCases/action"; } from "../../store/watchedCases/action";
import TimeOut from "../../components/timeout"; import TimeOut from "../../components/timeout";
import { getGovGatewayConfig } from "../../store/govgateway/action";
import { getProviderConfig } from "../../actions/govgateway";
const Home = (props) => { const Home = (props) => {
const { footerLinks, pages, watchedCases } = props; const { footerLinks, pages, watchedCases } = props;
@@ -60,7 +58,7 @@ const Home = (props) => {
</div> </div>
<Footer footerLinks={footerLinks} /> <Footer footerLinks={footerLinks} />
</div> </div>
<TimeOut ggLogout={props.govGateway.config.end_session_endpoint} /> <TimeOut />
</div> </div>
); );
}; };
@@ -83,8 +81,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
await getSearchDetails(searchResultsObj), await getSearchDetails(searchResultsObj),
await getDetails(watchedCases, "myWatchedCases"), await getDetails(watchedCases, "myWatchedCases"),
]); ]);
const providerConfig = await getProviderConfig();
store.dispatch(getGovGatewayConfig(providerConfig));
store.dispatch(setSearchResults(searchResultsObj)); store.dispatch(setSearchResults(searchResultsObj));
store.dispatch(setSearchDetails(searchDetailsObj)); store.dispatch(setSearchDetails(searchDetailsObj));
store.dispatch(setWatchedCases(watchedCases)); store.dispatch(setWatchedCases(watchedCases));
@@ -136,7 +133,6 @@ const mapStateToProps = (state) => {
watchedCases: state.watchedCases, watchedCases: state.watchedCases,
myRepresentations: state.myRepresentations, myRepresentations: state.myRepresentations,
awaitingSubmission: state.awaitingSubmission, awaitingSubmission: state.awaitingSubmission,
govGateway: state.govGateway,
}; };
}; };
+1 -2
View File
@@ -72,7 +72,7 @@ const Home = (props) => {
</div> </div>
<Footer footerLinks={footerLinks} /> <Footer footerLinks={footerLinks} />
</div> </div>
<TimeOut ggLogout={props.govGateway.config.end_session_endpoint} /> <TimeOut />
</div> </div>
); );
}; };
@@ -91,7 +91,6 @@ const mapStateToProps = (state) => {
watchedCases: state.watchedCases, watchedCases: state.watchedCases,
myRepresentations: state.myRepresentations, myRepresentations: state.myRepresentations,
awaitingSubmission: state.awaitingSubmission, awaitingSubmission: state.awaitingSubmission,
govGateway: state.govGateway,
}; };
}; };
-9
View File
@@ -16,7 +16,6 @@ import {
getCase, getCase,
} from "../../actions"; } from "../../actions";
import { createContainer } from "../../actions/azurestorage"; import { createContainer } from "../../actions/azurestorage";
import { getProviderConfig } from "../../actions/govgateway";
import Breadcrumbs from "../../components/breadcrumbs"; import Breadcrumbs from "../../components/breadcrumbs";
import CookieBanner from "../../components/cookieBanner"; import CookieBanner from "../../components/cookieBanner";
import Footer from "../../components/footer"; import Footer from "../../components/footer";
@@ -33,7 +32,6 @@ import {
setAwaitingSubmissionFromBlob, setAwaitingSubmissionFromBlob,
setAwaitingSubmissionDetails, setAwaitingSubmissionDetails,
} from "../../store/awaitingSubmission/action"; } from "../../store/awaitingSubmission/action";
import { getGovGatewayConfig } from "../../store/govgateway/action";
import { setMyCases, setMyCasesDetails } from "../../store/myCases/action"; import { setMyCases, setMyCasesDetails } from "../../store/myCases/action";
import { import {
setMyRepresentations, setMyRepresentations,
@@ -54,7 +52,6 @@ const Home = (props) => {
watchedCases, watchedCases,
awaitingSubmission, awaitingSubmission,
accountDetails, accountDetails,
govGateway,
showFileUpload, showFileUpload,
} = props; } = props;
let { t, lang } = useTranslation(); let { t, lang } = useTranslation();
@@ -144,7 +141,6 @@ const Home = (props) => {
watchedCases={watchedCases} watchedCases={watchedCases}
awaitingSubmission={awaitingSubmission} awaitingSubmission={awaitingSubmission}
accountDetails={accountDetails} accountDetails={accountDetails}
ggLogout={govGateway.config.end_session_endpoint}
showFileUpload={showFileUpload} showFileUpload={showFileUpload}
containerID={accountDetails.containerID} containerID={accountDetails.containerID}
/> />
@@ -180,10 +176,6 @@ export const getServerSideProps = wrapper.getServerSideProps(
//Create Storage container for logged in user //Create Storage container for logged in user
await createContainer(thisSession.user.id); await createContainer(thisSession.user.id);
let providerConfig = await getProviderConfig();
store.dispatch(getGovGatewayConfig(providerConfig));
const [ const [
accountDetails, accountDetails,
myCases, myCases,
@@ -315,7 +307,6 @@ const mapStateToProps = (state) => {
watchedCases: state.watchedCases, watchedCases: state.watchedCases,
myRepresentations: state.myRepresentations, myRepresentations: state.myRepresentations,
awaitingSubmission: state.awaitingSubmission, awaitingSubmission: state.awaitingSubmission,
govGateway: state.govGateway,
}; };
}; };
+1 -6
View File
@@ -28,8 +28,6 @@ import {
setWatchedCasesDetails, setWatchedCasesDetails,
} from "../../store/watchedCases/action"; } from "../../store/watchedCases/action";
import TimeOut from "../../components/timeout"; import TimeOut from "../../components/timeout";
import { getGovGatewayConfig } from "../../store/govgateway/action";
import { getProviderConfig } from "../../actions/govgateway";
import { getSession, useSession } from "next-auth/react"; import { getSession, useSession } from "next-auth/react";
import { import {
setAccountDetails, setAccountDetails,
@@ -66,7 +64,7 @@ const Home = (props) => {
</div> </div>
<Footer footerLinks={footerLinks} /> <Footer footerLinks={footerLinks} />
</div> </div>
<TimeOut ggLogout={props.govGateway.config.end_session_endpoint} /> <TimeOut />
</div> </div>
); );
}; };
@@ -104,9 +102,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
await getSearchDetails(searchResultsObj), await getSearchDetails(searchResultsObj),
await getDetails(watchedCases, "myWatchedCases"), await getDetails(watchedCases, "myWatchedCases"),
]); ]);
const providerConfig = await getProviderConfig();
store.dispatch(setAccountDetails(accountDetails)); store.dispatch(setAccountDetails(accountDetails));
store.dispatch(getGovGatewayConfig(providerConfig));
store.dispatch(setSearchResults(searchResultsObj)); store.dispatch(setSearchResults(searchResultsObj));
store.dispatch(setSearchDetails(searchDetailsObj)); store.dispatch(setSearchDetails(searchDetailsObj));
store.dispatch(setSearch(query.q)); store.dispatch(setSearch(query.q));
@@ -160,7 +156,6 @@ const mapStateToProps = (state) => {
myRepresentations: state.myRepresentations, myRepresentations: state.myRepresentations,
awaitingSubmission: state.awaitingSubmission, awaitingSubmission: state.awaitingSubmission,
accountDetails: state.accountDetails, accountDetails: state.accountDetails,
govGateway: state.govGateway,
}; };
}; };
+1 -2
View File
@@ -45,7 +45,7 @@ const Home = (props) => {
</div> </div>
<Footer footerLinks={footerLinks} /> <Footer footerLinks={footerLinks} />
</div> </div>
<TimeOut ggLogout={props.govGateway.config.end_session_endpoint} /> <TimeOut />
</div> </div>
); );
}; };
@@ -72,7 +72,6 @@ const mapStateToProps = (state) => {
myRepresentations: state.myRepresentations, myRepresentations: state.myRepresentations,
awaitingSubmission: state.awaitingSubmission, awaitingSubmission: state.awaitingSubmission,
currentView: state.currentView, currentView: state.currentView,
govGateway: state.govGateway,
}; };
}; };
+1 -6
View File
@@ -15,7 +15,6 @@ import {
getFilesFromBlob, getFilesFromBlob,
getProgressFromBlob, getProgressFromBlob,
} from "../../actions"; } from "../../actions";
import { getProviderConfig } from "../../actions/govgateway";
import Breadcrumbs from "../../components/breadcrumbs"; import Breadcrumbs from "../../components/breadcrumbs";
import CookieBanner from "../../components/cookieBanner"; import CookieBanner from "../../components/cookieBanner";
import Footer from "../../components/footer"; import Footer from "../../components/footer";
@@ -39,7 +38,6 @@ import {
setFilesForAppeal, setFilesForAppeal,
} from "../../store/appealType/action"; } from "../../store/appealType/action";
import { setForm } from "../../store/formData/action"; import { setForm } from "../../store/formData/action";
import { getGovGatewayConfig } from "../../store/govgateway/action";
import { wrapper } from "../../store/store"; import { wrapper } from "../../store/store";
import { getProgressBlobs } from "../../actions/azurestorage"; import { getProgressBlobs } from "../../actions/azurestorage";
import { getSession, useSession } from "next-auth/react"; import { getSession, useSession } from "next-auth/react";
@@ -209,7 +207,7 @@ let Home = (props) => {
<Footer footerLinks={footerLinks} /> <Footer footerLinks={footerLinks} />
</div> </div>
<TimeOut ggLogout={props.govGateway.config.end_session_endpoint} /> <TimeOut />
</div> </div>
); );
}; };
@@ -270,8 +268,6 @@ export const getServerSideProps = wrapper.getServerSideProps(
xmlStr = xmlStr.replace(/> <"/g, "><"); xmlStr = xmlStr.replace(/> <"/g, "><");
xmlStr = xmlStr.toString(); xmlStr = xmlStr.toString();
const providerConfig = await getProviderConfig();
store.dispatch(getGovGatewayConfig(providerConfig));
store.dispatch(setLoggedInUserId(loggedInUser)); store.dispatch(setLoggedInUserId(loggedInUser));
store.dispatch(setLoggedInUserEmail(loggedInUserEmail)); store.dispatch(setLoggedInUserEmail(loggedInUserEmail));
store.dispatch(setAppealLPA(query.lpa)); store.dispatch(setAppealLPA(query.lpa));
@@ -297,7 +293,6 @@ const mapStateToProps = (state) => {
appealType: state.appealType, appealType: state.appealType,
form: state.form, form: state.form,
accountDetails: state.accountDetails, accountDetails: state.accountDetails,
govGateway: state.govGateway,
}; };
}; };
-1
View File
@@ -130,7 +130,6 @@ const mapStateToProps = (state) => {
LPAData: state.LPAData, LPAData: state.LPAData,
form: state.form, form: state.form,
accountDetails: state.accountDetails, accountDetails: state.accountDetails,
govGateway: state.govGateway,
}; };
}; };
+1 -6
View File
@@ -24,8 +24,6 @@ import { setAppealType } from "../../store/appealType/action";
import { setLPA } from "../../store/lpa/action"; import { setLPA } from "../../store/lpa/action";
import { wrapper } from "../../store/store"; import { wrapper } from "../../store/store";
import TimeOut from "../../components/timeout"; import TimeOut from "../../components/timeout";
import { getGovGatewayConfig } from "../../store/govgateway/action";
import { getProviderConfig } from "../../actions/govgateway";
const Home = (props) => { const Home = (props) => {
const { footerLinks, pages, formData, loggedInUserIdent } = props; const { footerLinks, pages, formData, loggedInUserIdent } = props;
@@ -129,7 +127,7 @@ const Home = (props) => {
<Footer footerLinks={footerLinks} /> <Footer footerLinks={footerLinks} />
</div> </div>
<TimeOut ggLogout={props.govGateway.config.end_session_endpoint} /> <TimeOut />
</div> </div>
); );
}; };
@@ -164,11 +162,9 @@ export const getServerSideProps = wrapper.getServerSideProps(
console.log("wewerwe s s", accountDetails); console.log("wewerwe s s", accountDetails);
const providerConfig = await getProviderConfig();
// const lpaData = require("../../data/lpa.json"); // const lpaData = require("../../data/lpa.json");
// const appealTypeData = require("../../data/appealtypes.json"); // const appealTypeData = require("../../data/appealtypes.json");
store.dispatch(getGovGatewayConfig(providerConfig));
store.dispatch(setAppealType(appealTypeData)); store.dispatch(setAppealType(appealTypeData));
store.dispatch(setLPA(lpaData)); store.dispatch(setLPA(lpaData));
store.dispatch(setLoggedInUserId(loggedInUser)); store.dispatch(setLoggedInUserId(loggedInUser));
@@ -190,7 +186,6 @@ const mapStateToProps = (state) => {
LPAData: state.LPAData, LPAData: state.LPAData,
form: state.form, form: state.form,
accountDetails: state.accountDetails, accountDetails: state.accountDetails,
govGateway: state.govGateway,
}; };
}; };
+1 -6
View File
@@ -17,7 +17,6 @@ import awaitingSubmission from "./awaitingSubmission/reducer";
import myCases from "./myCases/reducer"; import myCases from "./myCases/reducer";
import myRepresentations from "./myRepresentations/reducer"; import myRepresentations from "./myRepresentations/reducer";
import watchedCases from "./watchedCases/reducer"; import watchedCases from "./watchedCases/reducer";
import govGateway from "./govgateway/reducer";
//COMBINING ALL REDUCERS //COMBINING ALL REDUCERS
const appReducer = combineReducers({ const appReducer = combineReducers({
@@ -32,7 +31,6 @@ const appReducer = combineReducers({
myCases, myCases,
myRepresentations, myRepresentations,
watchedCases, watchedCases,
govGateway,
form: formReducer, form: formReducer,
}); });
@@ -119,16 +117,13 @@ const makeStore = ({ isServer }) => {
"myCases", "myCases",
"myRepresentations", "myRepresentations",
"watchedCases", "watchedCases",
//"govGateway",
"form", "form",
], ],
version: 1.3, version: 1.4,
storage: storage, storage: storage,
stateReconciler: autoMergeLevel2, // if needed, use a safer storage stateReconciler: autoMergeLevel2, // if needed, use a safer storage
migrate: (state) => { migrate: (state) => {
console.log("Migration Running!"); console.log("Migration Running!");
// console.log(state);
return Promise.resolve(state); return Promise.resolve(state);
}, },
}; };