Skip to content

Instantly share code, notes, and snippets.

@mrbusche
Created March 19, 2014 14:29
Show Gist options
  • Save mrbusche/9642772 to your computer and use it in GitHub Desktop.
Save mrbusche/9642772 to your computer and use it in GitHub Desktop.
var activityHistory = billingHistory.getBillingAccountDTOs()[1].getActivityItemDTOList();
// sort the array descending
var start = getTickCount();
arraySort(activityHistory,
function (history1, history2){
return compare(history1.getActivityEffectiveDate(), history2.getActivityEffectiveDate());
}
);
//try to find a batch Number
var batchNumber = '';
for ( var history in activityHistory ) {
if (history.getTransactionStatus() == 'RC') {
batchNumber = history.getTransactionNumber();
break;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment