04-23-2014 10:16 AM
creditCheckOk = false;
customerName = "Mr Sathish"
execution.setVariable("customerName ", "Mr Sathish");
out:println "Checking credit for " + customerName + "income" + income + "loanAmount " + loanAmount ;
if((income / 2) > loanAmount) {
creditCheckOk = true;
}
out:println "Checked credit for " + customerName + " outcome is " + creditCheckOk;
public class CreateApplicationTask implements JavaDelegate{
public void execute(DelegateExecution execution){
LoanApplication la = new LoanApplication();
System.out.println("The value of credit check is"+ execution.getVariable("creditCheckOk"));
System.out.println("The value "+execution.getVariable("loanAmount").getClass());
la.setCreditCheckOk((Boolean) execution.getVariable("creditCheckOk"));
la.setCustomerName((String) execution.getVariable("customerName"));
la.setIncome((Long) execution.getVariable("income"));
la.setRequestedAmount((Long) execution.getVariable("loanAmount"));
la.setEmailAddress((String) execution.getVariable("emailAddress"));
execution.setVariable("loanApplication", la);
}
}
System.out.println("The value of credit check is"+ execution.getVariable("creditCheckOk"));
04-23-2014 10:39 AM
04-24-2014 02:18 AM
<scriptTask id="script" scriptFormat="JavaScript" activiti:autoStoreVariables="false/true">
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.