Skip to content

Commit

Permalink
WINDUP-797 Change <rule/> back to original icon
Browse files Browse the repository at this point in the history
  • Loading branch information
OndraZizka committed Oct 8, 2015
1 parent 1498086 commit 51d4427
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@ public void execute(Environment env, Map params, TemplateModel[] loopVars, Templ
if (RENDER_TYPE_GLYPH.equals(renderType))
writer.append("<span title='View Rule: " + ruleID + "' class='glyphicon glyphicon-link "+cssClass+"'></span>");
else if (RENDER_TYPE_TAG.equals(renderType))
writer.append("<span title='View Rule: " + ruleID + "' class='"+cssClass+"'>&lt;rule/></span>");
writer.append("<span title='View Rule: " + ruleID + "' class='tag "+cssClass+"'>&lt;rule/></span>");
else
writer.append("<span title='View Rule: " + ruleID + "' class='"+cssClass+"'>"+ ruleID +"</span>");
writer.append("<span title='View Rule: " + ruleID + "' class='plain "+cssClass+"'>"+ ruleID +"</span>");
writer.append("</a>");
}
}
15 changes: 13 additions & 2 deletions reporting/impl/src/main/resources/reports/resources/css/windup.css
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,11 @@ body {
}

.rule-link {
color: #00b800;
color: #008800;
}
.rule-link.floatRight {
padding: 4pt 4pt 0 0;
font-size: 8pt;
}

.feedback-nav {
Expand Down Expand Up @@ -83,7 +87,7 @@ h3.panel-title span.s {
.panel .panel-body .points .number { font-size: 50pt; width: 1.5em; }
.panel .panel-body .info h4 { font-weight: bold; font-size: 11pt; margin: 6pt 0 4pt 0; }
.panel .panel-body .info h4:first-child { margin-top: 0; }
.panel .panel-body .info .rule-link.tag { font-variant-position: super; font-weight: normal; position: relative; top: -0.4ex; left: -0.2em; }
.panel .panel-body .info .rule-link.tag { font-variant-position: super; font-weight: normal; position: relative; top: -0.3ex; }



Expand Down Expand Up @@ -206,3 +210,10 @@ p.windup-contributors {
background: url(../img/styles/tattletale-small-white-icon.png);
}
/** /Navigation **/



/** General rules */
.floatRight {
float: right;
}
Original file line number Diff line number Diff line change
Expand Up @@ -72,13 +72,14 @@
<#list problemSummary.files as file>
<@render_link model=file class="list-group-item"/><#t>
</#list>
<div style="clear: both;"/>
</div>
</td>
<td>${problemSummary.numberFound}</td>
<td>${problemSummary.effortPerIncident}</td>
<td>${problemSummary.numberFound * problemSummary.effortPerIncident}</td>
<td>
<@render_rule_link ruleID=problemSummary.ruleID renderType="glyph"/>
<@render_rule_link renderType="glyph" ruleID=problemSummary.ruleID/>
</td>
</tr>
</#list>
Expand All @@ -90,7 +91,7 @@

<script src="resources/js/jquery-1.10.1.min.js"></script>
<script src="resources/js/bootstrap.min.js"></script>
<script src="resources/js/jquery.tablesorter.min.js"></script>
<script src="resources/js/jquery.tablesorter.min.js"></script>
<script type="text/javascript">
$(document).ready(function () {
$('.problem-link').each(function(index, value) {
Expand All @@ -101,17 +102,17 @@
});
});
// we need this parser because we are using comma to separate thousands
$.tablesorter.addParser({
$.tablesorter.addParser({
id: 'thousands',
is: function(s) {
return true;
},
is: function(s) {
return true;
},
format: function(s) {
return s.replace('$','').replace(/,/g,'');
},
type: 'numeric'
});
$(document).ready(function() {
},
type: 'numeric'
});
$(document).ready(function() {
$("#issues_table").tablesorter({
sortList: [[3,1]],
headers: {
Expand All @@ -121,7 +122,7 @@
3: {sorter:'thousands'}
}
});
});
});
</script>
</body>
</html>
15 changes: 9 additions & 6 deletions reporting/impl/src/main/resources/reports/templates/source.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,10 @@
<div class="panel-heading">
<h3 class="panel-title">Information</h3>
</div>
<div class="panel-body">
<div class="panel-body" style="overflow: auto;">

<div class="points" style="float: left; text-align: center; color: #863333">
<!--<div style="height: 120pt; float:left;"></div> Keeps the minimal height. -->
<div class="points" style="text-align: center; color: #863333; padding-bottom: 1ex;">
<div class="number">${getMigrationEffortPointsForFile(reportModel.sourceFileModel)}</div>
<div>Story points<br/>(estimated)</div>
</div>
Expand All @@ -72,7 +73,7 @@

<#list getTechnologyTagsForFile(reportModel.sourceFileModel).iterator()>
<h4>Technologies</h4>
<div>
<div style="overflow: auto"><!-- "auto" to contain all the tags. -->
<#items as techTag>
<span class="label label-info">${techTag.name}</span>
</#items>
Expand All @@ -85,7 +86,7 @@
<#if item.classification??>
<li>
<em>${item.classification!}</em>
<@render_rule_link renderType='glyph' ruleID=item.ruleID class='rule-link tag'/><#-- Link to the rule -->
<@render_rule_link renderType='glyph' ruleID=item.ruleID class='rule-link floatRight'/><#-- Link to the rule -->
<#if item.description??> - ${item.description}</#if>
<@render_linkable linkable=item layout='ul'/><#-- Link contained in classification -->
</li>
Expand All @@ -101,7 +102,9 @@
</#items>
</ul>
</#list>
</div>

<div style="clear: both;"/><!-- Snaps under the height keeper. Yes, the same effect could be achieved by a table. -->
</div><!-- .info -->
</div>
</div>
</#if>
Expand Down Expand Up @@ -159,7 +162,7 @@
<strong class='notification ${effortPointsToCssClass(hintLine.effort)}'><#t>
${hintLine.title?js_string}<#t>
</strong><#t>
<@render_rule_link renderType='glyph' ruleID=hintLine.ruleID class='rule-link'/><#t>
<@render_rule_link renderType='glyph' ruleID=hintLine.ruleID class='rule-link floatRight'/><#t>
<#t>
</div><#t>
<div class='inline-comment-body'><#t>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
<tr>
<td>
${reportLine.message}
<@render_rule_link ruleID=reportLine.ruleID/>
<@render_rule_link renderType="glyph" ruleID=reportLine.ruleID class="rule-link"/>
</td>
</tr>
</#list>
Expand Down Expand Up @@ -60,6 +60,7 @@
<#list getTagsFromFileClassificationsAndHints(fileModel) as tag>
<span class="label label-info tag">${tag}</span>
</#list>
<div style="clear: both;"/>
</td>

<#-- Issues -->
Expand Down

0 comments on commit 51d4427

Please sign in to comment.