if agent dont change to appellant on submit appeal
This commit is contained in:
+8
-2
@@ -1847,12 +1847,18 @@ export const createContainerProxy = (containerName) => {
|
||||
});
|
||||
};
|
||||
|
||||
export const sendCaseCompleteMessage = async (containerID, caseReference) => {
|
||||
export const sendCaseCompleteMessage = async (
|
||||
containerID,
|
||||
caseReference,
|
||||
typeofinvolvement
|
||||
) => {
|
||||
var queryUrl =
|
||||
"/api/file/createappealcompletemessage_api?container=" +
|
||||
containerID +
|
||||
"&tempcaseref=" +
|
||||
caseReference;
|
||||
caseReference +
|
||||
"&inv=" +
|
||||
typeofinvolvement;
|
||||
|
||||
var config = {
|
||||
method: "get",
|
||||
|
||||
@@ -58,8 +58,6 @@ const AwaitingSubmissionFromBlob = (props) => {
|
||||
return { ...item1, ...item2 };
|
||||
});
|
||||
|
||||
console.log(mergedArray);
|
||||
|
||||
showTopThreeArr = mergedArray;
|
||||
|
||||
showTopThreeArr = sortByISODate(showTopThreeArr, "createdon");
|
||||
|
||||
@@ -96,8 +96,6 @@ const TopThree = (props) => {
|
||||
return { ...item1, ...item2 };
|
||||
});
|
||||
|
||||
console.log(mergedArray);
|
||||
|
||||
showTopThreeArr = mergedArray;
|
||||
|
||||
showTopThreeArr = sortByISODate(showTopThreeArr, "createdon");
|
||||
|
||||
@@ -145,7 +145,9 @@ let BuildCheckSection = (props) => {
|
||||
console.log("have generated pdf:", data);
|
||||
sendCaseCompleteMessage(
|
||||
props.props.accountDetails.containerID,
|
||||
props.appealType.caseReference.ticketnumber
|
||||
props.appealType.caseReference.ticketnumber,
|
||||
props.props.accountDetails.accountDetails
|
||||
.pinswg_typeofinvolvement
|
||||
);
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
@@ -16,6 +16,7 @@ ApiProxy.use(middleware);
|
||||
ApiProxy.get(async (req, res) => {
|
||||
var containerName = req.query.container;
|
||||
var tempCaseRef = req.query.tempcaseref;
|
||||
var typeofinvolvement = req.query.inv;
|
||||
var checkHash = req.query.hash;
|
||||
|
||||
console.log("/////Create Case Message:\n", tempCaseRef, "\n//////////////");
|
||||
@@ -62,15 +63,25 @@ ApiProxy.get(async (req, res) => {
|
||||
getCaseBlob(containerName, tempCaseRef, caseObj).then(() => {
|
||||
let contactId = caseObj["customerid_contact@odata.bind"];
|
||||
contactId = contactId.match(/\(([^)]+)\)/);
|
||||
updateAccount(
|
||||
contactId[1],
|
||||
{
|
||||
"pinswg_typeofinvolvement": 846040001,
|
||||
},
|
||||
true
|
||||
).then((data) => {
|
||||
console.log("uopdated account: ", data);
|
||||
});
|
||||
|
||||
if (typeofinvolvement != 846040000) {
|
||||
updateAccount(
|
||||
contactId[1],
|
||||
{
|
||||
"pinswg_typeofinvolvement": 846040001,
|
||||
},
|
||||
true
|
||||
).then((data) => {
|
||||
console.log(
|
||||
"uopdated account : " +
|
||||
contactId +
|
||||
" \nfrom: " +
|
||||
data.pinswg_typeofinvolvement +
|
||||
"\nto: " +
|
||||
typeofinvolvement
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
createCaseCompleteMessage(containerName, tempCaseRef);
|
||||
return res.status(200).json({
|
||||
|
||||
Reference in New Issue
Block a user