Merge branch 'master' of https://bitbucket.org/venbainformationtechnology/smc_cet_financials_backend
This commit is contained in:
commit
7987e3376b
@ -69,21 +69,29 @@ exports.MenuList = (req, res) => {
|
|||||||
.then(EntitiesData => {
|
.then(EntitiesData => {
|
||||||
let data = [];
|
let data = [];
|
||||||
EntitiesData.forEach((value, key)=>{
|
EntitiesData.forEach((value, key)=>{
|
||||||
// instancesid = value.dataValues.process_instance_id;
|
var camunda_status;
|
||||||
// taskid = camundaHelper.financialsListOfProcessInstances(instancesid); console.log(taskid)
|
instancesid = value.dataValues.process_instance_id;
|
||||||
// camunda_status = camundaHelper.financialsFormVariables(taskid);
|
// taskid = camundaHelper.financialsListOfProcessInstances(instancesid);
|
||||||
|
// taskid.then(function(result){
|
||||||
|
// formVariable = camundaHelper.financialsFormVariables(result);
|
||||||
|
// formVariable.then(function(form_result){
|
||||||
|
// camunda_status = JSON.parse(form_result);
|
||||||
|
// obj_data = { ...value.dataValues ,status:camunda_status , statementsmasterrData:MasterData }
|
||||||
|
// data.push(obj_data);
|
||||||
|
// });
|
||||||
|
// });
|
||||||
obj_data = { ...value.dataValues , statementsmasterrData:MasterData }
|
obj_data = { ...value.dataValues , statementsmasterrData:MasterData }
|
||||||
|
|
||||||
data.push(obj_data);
|
data.push(obj_data);
|
||||||
|
|
||||||
}); // end of EntitiesData foreach
|
}); // end of EntitiesData foreach
|
||||||
|
|
||||||
|
setTimeout(()=>{
|
||||||
// below code for overall sum object push process
|
// below code for overall sum object push process
|
||||||
sum_data = { ...{'losid':losid,'bizname':"Consolidated Financials Summary",'is_consolidated_api_call':1} , statementsmasterrData:MasterData };
|
sum_data = { ...{'losid':losid,'bizname':"Consolidated Financials Summary",'is_consolidated_api_call':1} , statementsmasterrData:MasterData };
|
||||||
data.push(sum_data);
|
data.push(sum_data);
|
||||||
|
|
||||||
// send respose to FE
|
// send respose to FE
|
||||||
res.send({'status':200,'message':"success",'data':data});
|
res.send({'status':200,'message':"success",'data':data});
|
||||||
|
},5000)
|
||||||
}); // end of findall EntitiesData
|
}); // end of findall EntitiesData
|
||||||
}); // end of findall masters datas
|
}); // end of findall masters datas
|
||||||
} // end of starter function if condition
|
} // end of starter function if condition
|
||||||
@ -714,7 +722,6 @@ exports.camunda = async (req, res) => {
|
|||||||
instancesid = "33f6a13d-272f-11ec-a4f4-42010a800002";
|
instancesid = "33f6a13d-272f-11ec-a4f4-42010a800002";
|
||||||
const taskid = camundaHelper.financialsListOfProcessInstances(instancesid);
|
const taskid = camundaHelper.financialsListOfProcessInstances(instancesid);
|
||||||
taskid.then(function(result){
|
taskid.then(function(result){
|
||||||
|
|
||||||
const formVariable = camundaHelper.financialsFormVariables(result);
|
const formVariable = camundaHelper.financialsFormVariables(result);
|
||||||
formVariable.then(function(form_result){ camunda_status = form_result });
|
formVariable.then(function(form_result){ camunda_status = form_result });
|
||||||
});
|
});
|
||||||
|
|||||||
@ -50,7 +50,12 @@ const URL = process.env.CAMUNDA_URL
|
|||||||
}, function (error, response, body){
|
}, function (error, response, body){
|
||||||
let data = body;
|
let data = body;
|
||||||
task_id = data[0].id;
|
task_id = data[0].id;
|
||||||
|
if(task_id)
|
||||||
|
{
|
||||||
resolve(task_id);
|
resolve(task_id);
|
||||||
|
}
|
||||||
|
else{ resolve(false); }
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user