diff options
author | Trygve Laugstøl <trygvis@inamo.no> | 2012-12-28 16:39:13 +0100 |
---|---|---|
committer | Trygve Laugstøl <trygvis@inamo.no> | 2012-12-28 16:39:13 +0100 |
commit | 54ec271b75dad82da9bd4ee2975a22490d66d6dc (patch) | |
tree | aa72a3a77445f4b0ee238932536e44cb0878089f /src/main/java | |
parent | c9ff3d5495b0229d837fa0ec23486cc7b6b191d0 (diff) | |
download | esper-testing-54ec271b75dad82da9bd4ee2975a22490d66d6dc.tar.gz esper-testing-54ec271b75dad82da9bd4ee2975a22490d66d6dc.tar.bz2 esper-testing-54ec271b75dad82da9bd4ee2975a22490d66d6dc.tar.xz esper-testing-54ec271b75dad82da9bd4ee2975a22490d66d6dc.zip |
o Showing date and build result IN COLOR!
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/io/trygvis/esper/testing/web/resource/CoreResource.java | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/main/java/io/trygvis/esper/testing/web/resource/CoreResource.java b/src/main/java/io/trygvis/esper/testing/web/resource/CoreResource.java index 98b32bb..2f4b77b 100644 --- a/src/main/java/io/trygvis/esper/testing/web/resource/CoreResource.java +++ b/src/main/java/io/trygvis/esper/testing/web/resource/CoreResource.java @@ -6,6 +6,7 @@ import io.trygvis.esper.testing.core.badge.*; import io.trygvis.esper.testing.core.db.*; import io.trygvis.esper.testing.util.sql.*; import io.trygvis.esper.testing.web.*; +import org.joda.time.*; import javax.servlet.http.*; import javax.ws.rs.*; @@ -98,10 +99,9 @@ public class CoreResource extends AbstractResource { public List<BuildJson> run(Daos daos) throws SQLException { List<BuildDto> buildDtos; - if(person != null) { + if (person != null) { buildDtos = daos.buildDao.selectBuildsByPerson(person, page); - } - else { + } else { buildDtos = daos.buildDao.selectBuilds(page); } @@ -130,14 +130,18 @@ public class CoreResource extends AbstractResource { } private BuildJson getBuildJson(Daos daos, BuildDto build) { - return new BuildJson(build.uuid); + return new BuildJson(build.uuid, build.createdDate, build.success); } public static class BuildJson { public final UUID uuid; + public final DateTime date; + public final boolean success; - public BuildJson(UUID uuid) { + public BuildJson(UUID uuid, DateTime date, boolean success) { this.uuid = uuid; + this.date = date; + this.success = success; } } } |