continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From batkin...@apache.org
Subject svn commit: r1660772 - in /continuum/trunk/continuum-webapp/src/main: java/org/apache/maven/continuum/web/action/BuildResultAction.java webapp/WEB-INF/jsp/buildResult.jsp webapp/css/continuum.css
Date Thu, 19 Feb 2015 00:05:34 GMT
Author: batkinson
Date: Thu Feb 19 00:05:34 2015
New Revision: 1660772

URL: http://svn.apache.org/r1660772
Log:
[CONTINUUM-1309] Result page does not show build output for canceled builds

Modified:
    continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java
    continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/buildResult.jsp
    continuum/trunk/continuum-webapp/src/main/webapp/css/continuum.css

Modified: continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java?rev=1660772&r1=1660771&r2=1660772&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java
(original)
+++ continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java
Thu Feb 19 00:05:34 2015
@@ -311,4 +311,14 @@ public class BuildResultAction
     {
         return buildResult.getState() == ContinuumProjectState.BUILDING;
     }
+
+    public boolean isBuildSuccessful()
+    {
+        return buildResult.getState() == ContinuumProjectState.OK;
+    }
+
+    public boolean isShowBuildError()
+    {
+        return !isBuildSuccessful() && !StringUtils.isEmpty( buildResult.getError()
);
+    }
 }

Modified: continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/buildResult.jsp
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/buildResult.jsp?rev=1660772&r1=1660771&r2=1660772&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/buildResult.jsp (original)
+++ continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/buildResult.jsp Thu Feb 19
00:05:34 2015
@@ -328,26 +328,25 @@
           <s:a href="%{surefireReportUrl}"><s:text name="buildResult.generatedReports.surefire"/></s:a>
         </s:if>
 
-        <s:if test="buildResult.state == 4">
+        <s:if test="showBuildError">
           <h4><s:text name="buildResult.buildError"/></h4>
           <div class="cmd-output pre-wrap"><s:property value="buildResult.error"/></div>
         </s:if>
-        <s:else>
-          <h4><s:text name="buildResult.buildOutput"/></h4>
-          <p>
-            <span id="noBuildOutput">
-              <s:text name="buildResult.noOutput"/>
-            </span>
-            <div id="buildOutput" style="display: none;">
-              <s:url id="buildOutputTextUrl" action="buildOutputText">
-                <s:param name="projectId" value="projectId"/>
-                <s:param name="buildId" value="buildId"/>
-              </s:url>
-              <s:a href="%{buildOutputTextUrl}"><s:text name="buildResult.buildOutput.text"/></s:a>
-              <div id="outputArea" class="cmd-output pre-wrap"><s:property value="buildOutput"/></div>
-            </div>
-          </p>
-        </s:else>
+
+        <h4><s:text name="buildResult.buildOutput"/></h4>
+        <p>
+          <span id="noBuildOutput">
+            <s:text name="buildResult.noOutput"/>
+          </span>
+          <div id="buildOutput" style="display: none;">
+            <s:url id="buildOutputTextUrl" action="buildOutputText">
+              <s:param name="projectId" value="projectId"/>
+              <s:param name="buildId" value="buildId"/>
+            </s:url>
+            <s:a href="%{buildOutputTextUrl}"><s:text name="buildResult.buildOutput.text"/></s:a>
+            <div id="outputArea" class="cmd-output cmd-window pre-wrap"><s:property
value="buildOutput"/></div>
+          </div>
+        </p>
       </div>
     </body>
   </s:i18n>

Modified: continuum/trunk/continuum-webapp/src/main/webapp/css/continuum.css
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/webapp/css/continuum.css?rev=1660772&r1=1660771&r2=1660772&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp/src/main/webapp/css/continuum.css (original)
+++ continuum/trunk/continuum-webapp/src/main/webapp/css/continuum.css Thu Feb 19 00:05:34
2015
@@ -24,7 +24,7 @@ td.tdLabel {
 
 .cmd-output {
   width:100%;
-  height:500px;
+  max-height:500px;
   overflow:auto;
   border-style: solid;
   border-width: 1px;
@@ -32,6 +32,10 @@ td.tdLabel {
   font-family: monospace;
 }
 
+.cmd-window {
+  height:500px;
+}
+
 .cmd-loading {
   background: url(/images/wait.gif) 5px 479px no-repeat;
   background-size: 16px 16px;



Mime
View raw message