if agent dont change to appellant on submit appeal
This commit is contained in:
@@ -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