Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

- total sum, not per users

- hack in providers that might help
  • Loading branch information...
commit a545fa97941fcdfee957d688da76650ac96c34d0 1 parent f748101
Tomasz Szymanski szimano authored
13 timesheet-exporter/src/main/java/pl/softwaremill/timesheet_exporter/printer/ConsoleReportPrinter.java
View
@@ -22,19 +22,18 @@ public void printReport(Multimap<User, DataRow> reportData) {
Set<User> users = reportData.keySet();
+ float totalSum = 0f;
+
for (User user : users) {
- float sumPerUser = 0f;
for (DataRow dataRow : reportData.get(user)) {
System.out.println(ToCsv.toCSV(dataRow, settings.getFields()));
- sumPerUser += dataRow.getTimeSpent();
- }
-
- if (settings.getSum()) {
- System.out.println("Sum = " + sumPerUser);
+ totalSum += dataRow.getTimeSpent();
}
}
-
+ if (settings.getSum()) {
+ System.out.println("Sum = " + totalSum);
+ }
}
}
2  timesheet-exporter/src/main/resources/META-INF/services/javax.ws.rs.ext.Providers
View
@@ -1,7 +1,7 @@
+org.jboss.resteasy.plugins.providers.jaxb.XmlJAXBContextFinder
org.jboss.resteasy.plugins.providers.jaxb.JAXBXmlSeeAlsoProvider
org.jboss.resteasy.plugins.providers.jaxb.JAXBXmlRootElementProvider
org.jboss.resteasy.plugins.providers.jaxb.JAXBElementProvider
org.jboss.resteasy.plugins.providers.jaxb.JAXBXmlTypeProvider
org.jboss.resteasy.plugins.providers.jaxb.CollectionProvider
org.jboss.resteasy.plugins.providers.jaxb.MapProvider
-org.jboss.resteasy.plugins.providers.jaxb.XmlJAXBContextFinder
Please sign in to comment.
Something went wrong with that request. Please try again.