Upgrade
This commit is contained in:
parent
2c0a9867b9
commit
f592787ab7
29 changed files with 173 additions and 451 deletions
|
|
@ -14,11 +14,15 @@
|
|||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.drools</groupId>
|
||||
<artifactId>drools-compiler</artifactId>
|
||||
<artifactId>drools-engine-classic</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.eclipse.jdt.core.compiler</groupId>
|
||||
<artifactId>ecj</artifactId>
|
||||
<groupId>org.drools</groupId>
|
||||
<artifactId>drools-model-compiler</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.drools</groupId>
|
||||
<artifactId>drools-ecj</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.kie.kogito</groupId>
|
||||
|
|
@ -44,11 +48,7 @@
|
|||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.6.0</version>
|
||||
<configuration>
|
||||
<source>1.8</source>
|
||||
<target>1.8</target>
|
||||
</configuration>
|
||||
<version>${maven.compiler.version}</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.kie</groupId>
|
||||
|
|
@ -58,4 +58,4 @@
|
|||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
</project>
|
||||
|
|
|
|||
|
|
@ -22,45 +22,27 @@ ruleflow-group "total"
|
|||
$totalBoatTransport : Number( doubleValue > 100 )
|
||||
from accumulate( $s : Step(transportType ==Step.Ship_TransportType) &&
|
||||
TransportCostElement(step ==$s, $value : amount ),
|
||||
init( double total = 0; ),
|
||||
action( total += $value; ),
|
||||
reverse( total -= $value; ),
|
||||
result( total ) )
|
||||
sum($value))
|
||||
$totalTrainTransport : Number( doubleValue > 100 )
|
||||
from accumulate( $s : Step(transportType ==Step.train_TransportType) &&
|
||||
TransportCostElement(step ==$s, $value : amount ),
|
||||
init( double total = 0; ),
|
||||
action( total += $value; ),
|
||||
reverse( total -= $value; ),
|
||||
result( total ) )
|
||||
sum($value) )
|
||||
$totalTruckTransport : Number( doubleValue > 100 )
|
||||
from accumulate( $s : Step(transportType ==Step.truck_TransportType) &&
|
||||
TransportCostElement(step ==$s, $value : amount ),
|
||||
init( double total = 0; ),
|
||||
action( total += $value; ),
|
||||
reverse( total -= $value; ),
|
||||
result( total ) )
|
||||
sum($value) )
|
||||
|
||||
|
||||
|
||||
$totalTransport : Number( doubleValue > 100 )
|
||||
from accumulate( TransportCostElement( $value : amount ),
|
||||
init( double total = 0; ),
|
||||
action( total += $value; ),
|
||||
reverse( total -= $value; ),
|
||||
result( total ) )
|
||||
sum($value) )
|
||||
$totalTaxes : Number( doubleValue > 100 )
|
||||
from accumulate( TaxesCostElement( $value : amount ),
|
||||
init( double total = 0; ),
|
||||
action( total += $value; ),
|
||||
reverse( total -= $value; ),
|
||||
result( total ) )
|
||||
sum($value))
|
||||
$totalHandling : Number( doubleValue > 100 )
|
||||
from accumulate( HandlingCostElement( $value : amount ),
|
||||
init( double total = 0; ),
|
||||
action( total += $value; ),
|
||||
reverse( total -= $value; ),
|
||||
result( total ) )
|
||||
sum($value) )
|
||||
then
|
||||
System.out.println("NumberOfPallets="+$c.getPallets().size());
|
||||
System.out.println("TotalShipTransport="+$totalBoatTransport);
|
||||
|
|
@ -69,4 +51,4 @@ ruleflow-group "total"
|
|||
System.out.println("TotalTransport="+$totalTransport);
|
||||
System.out.println("TotalTaxes="+$totalTaxes);
|
||||
System.out.println("TotalHandling="+$totalHandling);
|
||||
end;
|
||||
end;
|
||||
|
|
|
|||
Loading…
Add table
editor.link_modal.header
Reference in a new issue