4.1.6.20: International Participants Summary

#set($ireport = $report.getInternationalParticipantsReport()) #set($D = "$amps;")
#foreach($group in $ireport.getReportGroups()) #if($group.getCount() > 0) #set($label = $group.getLabel()) #foreach($hit in $group.getHitTracker()) #set($order = $group.load($hit)) #set($cartitem = $order.getItems().get(0)) ###set($classlist = $cartitem.getProduct().get("classlist")) ###set($classdata = $ireport.loadObjectByField("learningGroup","id",$classlist)) #set($classlist = $order.getValues("learninggroup").get(0)) #set($classdata = $ireport.loadObjectByField("learningGroup","id",$classlist)) #set($product = $cartitem.getProduct()) #set($method = "") #set($vouchernumber = "N/A") #set($vouchervalue = "N/A") #if($order.getPaymentMethod().getType() == "prepaidcode") #set($method = "Voucher") #set($vouchernumber = $order.get("prepaid")) #set($vouchervalue = $order.getSubTotal()) #elseif($order.getPaymentMethod().getType() == "creditcard") #set($method = $order.getPaymentMethod().getCreditCardType()) #end #set($price = "N/A") #if($product.getPriceSupport().getRetailPrice()) #set($price = $product.getPriceSupport().getRetailPrice()) $group.addMoney("price",$price) #end ####need to break this up into sub-groups: Canada and Not Canada ####set($country = $ireport.getDisplayValue("userprofile","id",$order.getCustomer().getId(), "country","N/A")) #set($country = $order.get("billing-country")) #set($studentid = $ireport.getDisplayValue("userprofile","id",$order.getCustomer().getId(), "studentid","N/A")) $group.incrementUniqueCount("studentid",$studentid) $group.incrementUniqueCount("country",$country) $group.incrementUniqueCount("classid",$cartitem.getSku()) $group.addMoney("tax",$order.getTax()) $group.addMoney("total",$order.getTotalPrice()) #if($vouchervalue != "N/A") $group.addMoney("voucher",$vouchervalue) #end $group.addMoneyAsString("discount","0") #if($velocityCount == 1) #else #end #end #end #end $ireport.generateSummary()
Country Student ID Last Name First Name Class ID Class Name Start Date End Date Class Value Order # Payment Date Payment Method Payment Amount HST Owing Discount Amount Discount Issuer Voucher Number Voucher Amount
$country $studentid $order.getCustomer().getLastName() $order.getCustomer().getFirstName() $!classdata.id $!classdata.name $!context.getDate($classdata.startdate) $!context.getDate($classdata.enddate) $price $order.getId() $context.getDate($order.getDate()) $method $order.getTotalPrice() $order.getTax() ${D}0.00 ${D}0.00 N/A $vouchernumber $vouchervalue
$group.getMoney("price","0") $group.getMoney("total","0") $group.getMoney("tax","0") $group.getMoney("owing","0") $group.getMoney("discount","0") $group.getMoney("voucher","0")
$ireport.getMoney("price","0") $ireport.getMoney("total","0") $ireport.getMoney("tax","0") $ireport.getMoney("owing","0") $ireport.getMoney("discount","0") $ireport.getMoney("voucher","0")