I have an attribute on a ctd that displays a simple css progress bar. The attribute is a discrete dropdown with numbers 1-8 as the choices. Based on the choice, the progress bar displays on the coverpage and dashboard. That works fine. My issue is when pulling this attribute on a process report, it displays the progress bar PLUS the number chosen. I've struggled with this and can't seem to find the reason. Here is the code I've placed in my custom template path.
Any help is greatly appreciated!!!
<!-- code added to processReportResults_catCell.shtml -->
<ISPECT>if(getAttributeValue("CA_ValueType",atd)== "Discrete")
<ISPECT>show("showCOATValueAsProgressInReport.shtml")</ISPECT>
</ISPECT>
<!-- Custom template showCOATValueAsProgressInReport.shtml -->
<ISPECT>String sValue = getAttributeValue(theAttribute)</ISPECT>
<ISPECT>if (sValue=="1")
<ISPECT>show("progress_1.shtml")</ISPECT>
</ISPECT>
<ISPECT>else if (sValue=="2")
<ISPECT>show("progress_2.shtml")</ISPECT>
</ISPECT>
<ISPECT>else if (sValue=="3")
<ISPECT>show("progress_3.shtml")</ISPECT>
</ISPECT>
<ISPECT>else if (sValue=="4")
<ISPECT>show("progress_4.shtml")</ISPECT>
</ISPECT>
<ISPECT>else if (sValue=="5")
<ISPECT>show("progress_5.shtml")</ISPECT>
</ISPECT>
<ISPECT>else if (sValue=="6")
<ISPECT>show("progress_6.shtml")</ISPECT>
</ISPECT>
<ISPECT>else if (sValue=="7")
<ISPECT>show("progress_7.shtml")</ISPECT>
</ISPECT>
<ISPECT>else if (sValue=="8")
<ISPECT>show("progress_8.shtml")</ISPECT>
</ISPECT>
<!-- Example of "progress" display templates -->
<!-- progress_1.shtml -->
<!--
<style type="text/css" media="screen">
div.progress-container {
border: 1px solid #ccc;
width: 100px;
margin: 2px 5px 2px 0;
padding: 1px;
float: left;
background: white;
}
div.progress-container > div {
background-color: #ACE97C;
height: 12px
}
</style>
<div class="progress-container">
<div style="width: 12%; background: #83F52C">12%</div>
</div>
-->