diff --git a/components/newappeal/buildchecksection.js b/components/newappeal/buildchecksection.js index aa252a3d..6f53e25f 100644 --- a/components/newappeal/buildchecksection.js +++ b/components/newappeal/buildchecksection.js @@ -76,7 +76,6 @@ let BuildCheckSection = (props) => { props={props} key={key} mandatoryFieldsData={mandatoryFieldsData} - props={props} /> ))} diff --git a/components/newappeal/complete.js b/components/newappeal/complete.js index 7989b388..f66f1900 100644 --- a/components/newappeal/complete.js +++ b/components/newappeal/complete.js @@ -15,22 +15,6 @@ import data from "../../data/collections.json"; let CompleteAppeal = (props) => { // un comment to update incident with an appealtype id useEffect(() => { - // console.log(props.appealType.caseReference.incidentid); - // console.log(props.appealType.appealTypeID); - // console.log(props.props.form.appealForm.values); - - // console.log(updateBody); - // console.log( - // getFormCollection( - // "pinswg_" + - // props.appealType.caseReference[ - // "pinswg_appealcasetype@OData.Community.Display.V1.FormattedValue" - // ] - // .replace(/[\s\-\+\(\)\,\&\.]/g, "") - // .toLowerCase() - // ) - // ); - let incidentId = props.appealType.caseReference.incidentid; let updateBody = props.props.form.appealForm.values; @@ -52,7 +36,7 @@ let CompleteAppeal = (props) => { ); updateCase(incidentId, updateBody, updateFormCollection); - }, []); + }, [props.appealType.caseReference, props.props.form.appealForm.values]); const getFormCollection = (formtype) => { const collectionName = jsonpath.query( diff --git a/pages/api/proxy/[...route].js b/pages/api/proxy/[...route].js index 479e5ddc..d8c2e4cc 100644 --- a/pages/api/proxy/[...route].js +++ b/pages/api/proxy/[...route].js @@ -51,7 +51,7 @@ const getSASToken = () => { return token; }; -export default async function (req, res) { +export default async function ApiProxy(req, res) { // console.log(req.method); var updateBody = {