javaredhatjbpmmvelredhat-brms

How do you make a ruleflow-group using JBPM Guided Rules?


I am trying to minimize the amount of code my fellow teammates have to do since they do not know either java or mvel. I am unable to place make them as a Decision Table because we perform calculations in the RHS (then), I am wondering if there is a way to do this in the Guided Rules. See example below

rule "MyRule1"
ruleflow-group "score-calculation"
when
    $case : Case( caseStatus == "LM" , $balance: balance != null, $cValue: cValue!= null, $lValue: lValue!= null)
then
    $case.setScore(($lValue*.001*$balance)/($cValue));
end

rule "MyRule2"
ruleflow-group "score-calculation"
when
    $case : Case( caseStatus == "NP" , $balance: balance != null, $cValue: cValue!= null, $lValue: lValue!= null)
then
    $case.setScore(($lValue*.01*$balance)/($cValue));
end

...etc


Solution

  • I figured out that it is possible to create a formula using the "guided decision table" and "include advanced options" and used the "Business Rule Language action" option when you try to create a column for the table. However, we opted to just have separate Guided Rule files