Esempio n. 1
0
 private String csvCartolasContent(List<Cartola> cartolas) {
   String csvContent = "Date,Description,Amount,Debit,Credit,Origin,Category,ReconciliationDate\n";
   for (Cartola cartola : cartolas) {
     for (Movement movement : cartola.getMovements()) {
       csvContent =
           csvContent
               + movement.getDate()
               + ","
               + movement.getDescription()
               + ","
               + movement.getAmount()
               + ","
               + movement.getDebit()
               + ","
               + movement.getCredit()
               + ","
               + movement.getOrigin()
               + ","
               + movement.getCategory()
               + ","
               + cartola.getReconciliationDate()
               + "\n";
     }
   }
   return csvContent;
 }
Esempio n. 2
0
 public String csvMovementsContent(List<Movement> movements) {
   String csvContent = "Date,Description,Amount,Debit,Credit,Origin,Category\n";
   for (Movement movement : movements) {
     csvContent =
         csvContent
             + movement.getDate()
             + ","
             + movement.getDescription()
             + ","
             + movement.getAmount()
             + ","
             + movement.getDebit()
             + ","
             + movement.getCredit()
             + ","
             + movement.getOrigin()
             + ","
             + movement.getCategory()
             + "\n";
   }
   return csvContent;
 }