AnsweredAssumed Answered

14.6 - Multi-line bar charts in dashboard portlets?

Question asked by Beeks on Oct 20, 2015
Latest reply on Oct 21, 2015 by Beeks

Hi all,

 

Has anyone successfully managed to create multi-line bar charts in a dashboard portlet? For example, I'd like to take the area chart for 'Incident Trend by Impact' portlet and change it to a line chart, like this:

 

30days.PNG

 

However I can only get the portlet to display one series, and cannot add a legend or a caption to the X axis unless the chart is expanded. These are not show stoppers, but having mulitple series in one chart is.

 

My XML currently looks like this:

<?xml version="1.0" encoding="UTF-8"?>
<searches>
    <search baseline="Pane" major="1" label="BK 9 Incident Trend By Policy" description="BK 9 Incident Trend By Policy" 
        type="system" category="Dashboard" dictionary="dlp_dashboard" no_settings="true" restricted="false" >
        <parameters>
            <parameter name="name" value="tc_alert_trend_imp_v1_1"/>
            <parameter name="package" value="dlpdash"/>
            <parameter name="type" value="line"/>
            <!--<parameter name="width" value="10" />-->
            <parameter name="caption" value="Test Caption" />
            <parameter name="Caption-x" value="120" />
            <parameter name="caption-y" value="240" />
            <parameter name="options" value="data-labels" />
            <parameter name="lstChartType" value="2" report_value="Line" hidden="false" />
            <parameter name="lstAllowedChartTypes" value="0,1,2,3,4,5,6"/>
            <parameter name="caption" value="Test caption" />
 <!--           <parameter name="drilldown" value="Events By Time/Policy"/> -->
 <!--           <parameter name="lstDrilldown" value="3"/> -->
            
            <parameter name="txtAttributes" value="ValueAxisType:Date" hidden="false" />
        </parameters>
        <results>
          <column name="Day" type="text" label="Date" hidden="true" />
          <column name="High" type="numeric" label="High" hidden="false" display="true"/>
          <!-- <column name="Medium" type="numeric" label="Medium" display="true" />-->
          <!-- <column name="Low" type="numeric" label="Low" hidden="false" display="true" /> -->
          <!-- <column name="NotSet" type="numeric" label="Not Set" hidden="false" display="true" /> -->
          <!--<column name="ID" label="ID" type="id" primary_key="true" hidden="true" display="false" /> -->
       </results>
    </search>
</searches>

 

Which works as expected, one line is displayed:

Capture2.PNG

 

However once I modify the query to return multiple severities based by date, nothing is plotted:

capture3.PNG

Modified the XML to expect the new columns with no luck:

<?xml version="1.0" encoding="UTF-8"?>
<searches>
    <search baseline="Pane" major="1" label="BK 9 Incident Trend By Policy" description="BK 9 Incident Trend By Policy" 
        type="system" category="Dashboard" dictionary="dlp_dashboard" no_settings="true" restricted="false" >
        <parameters>
            <parameter name="name" value="tc_alert_trend_imp_v1_1"/>
            <parameter name="package" value="dlpdash"/>
            <parameter name="type" value="line"/>
            <!--<parameter name="width" value="10" />-->
            <parameter name="caption" value="Test Caption" />
            <parameter name="Caption-x" value="120" />
            <parameter name="caption-y" value="240" />
            <parameter name="options" value="data-labels" />
            <parameter name="lstChartType" value="2" report_value="Line" hidden="false" />
            <parameter name="lstAllowedChartTypes" value="0,1,2,3,4,5,6"/>
            <parameter name="caption" value="Test caption" />
 <!--           <parameter name="drilldown" value="Events By Time/Policy"/> -->
 <!--           <parameter name="lstDrilldown" value="3"/> -->
            
            <parameter name="txtAttributes" value="ValueAxisType:Date" hidden="false" />
        </parameters>
        <results>
          <column name="Day" type="text" label="Date" hidden="true" />
          <column name="High" type="numeric" label="High" hidden="false" display="true"/>
          <column name="Medium" type="numeric" label="Medium" display="true" />
          <column name="Low" type="numeric" label="Low" hidden="false" display="true" />
          <column name="NotSet" type="numeric" label="Not Set" hidden="false" display="true" />
          <!--<column name="ID" label="ID" type="id" primary_key="true" hidden="true" display="false" /> -->
       </results>
    </search>
</searches>

 

I also tried adding an identity key, but that didn't help. What am I doing wrong here? Is this a defect? Has anyone successfully plotted more than one line on a line chrat (type 2)

Outcomes