Telerik 折线图仅显示一个月



我有一个 telerik 折线图,可以完美地与任何其他数据配合使用,但是,当我发送以下内容时,它只在 10 月绘制图表。 不知道为什么...

创建折线图

$("#leftLine").kendoChart({    
        dataSource: {
            data: ko.toJS(my.line()),
            group: { field: "Grp_Value"},
            sort: {
                field: "MonthTrxDateFirst",
                dir: "asc"
            },
            schema: {
                model: {
                    fields: {
                        date: {
                            type: "date"
                        }
                    }
                }
            }
        },
        legend: {
            position: "top"
        },
        series: [{
            type:"line",
            field: "Pct_Sales"
            //name: "% Strategy Sales"
        }],
        categoryAxis: {
            field: "MonthTrxDateFirst",
            labels: {
                rotation: -90,
                dateFormats:
                    {
                        minutes: "HH:mm",
                        hours: "HH:mm",
                        days: "dd/MM",
                        months: "MMM 'yy",
                        years: "yyyy"
                    }
            }, type: "Date",  baseUnit: "months"  ,              
            crosshair: {
                visible: true
            }
        },
        valueAxis: {
            labels: {
                format: "{0:P1}"
            }
            //,majorUnit: 10000
        },
        tooltip: {
            visible: true,template: "<div >Date: #=kendo.toString(kendo.parseDate(dataItem.MonthTrxDateFirst, 'yyyy-MM-dd'), 'MM/dd/yyyy')# <br/>  "+
            " Sales: #=kendo.format('{0:C}',dataItem.Sales)# <br/> " +
            "Pct Sales: #=kendo.format('{0:P}',dataItem.Pct_Sales)# <br/> " +
            "GP Pct: #=kendo.format('{0:P}',dataItem.GP_Pct)# </div>"
        }
    });

数据此 XML 文件似乎没有任何与之关联的样式信息。文档树如下所示。

<?xml version="1.0" encoding="UTF-8"?>
<ArrayOfNew_DB2_TimeSeries_PctSales_Result xmlns="http://schemas.datacontract.org/2004/07/SPADash" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.354023</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-01-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.037760</Pct_Sales>
    <Sales>48641.450</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.329960</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-01-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.305261</Pct_Sales>
    <Sales>80316.630</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.305978</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-01-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.000748</Pct_Sales>
    <Sales>59.220</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.336629</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-01-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.004844</Pct_Sales>
    <Sales>229.600</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.347898</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-02-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.042067</Pct_Sales>
    <Sales>217491.380</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.348029</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-02-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.322431</Pct_Sales>
    <Sales>363864.670</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.382086</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-02-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.016862</Pct_Sales>
    <Sales>4907.910</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.425109</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>MRO</Grp_Value>
    <MonthTrxDateFirst>2014-02-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.000948</Pct_Sales>
    <Sales>505.330</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.295025</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-02-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.010681</Pct_Sales>
    <Sales>3290.000</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.320293</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-03-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.111609</Pct_Sales>
    <Sales>626837.430</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.345350</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-03-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.415663</Pct_Sales>
    <Sales>502403.540</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.362625</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-03-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.373628</Pct_Sales>
    <Sales>127139.020</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.394008</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>MRO</Grp_Value>
    <MonthTrxDateFirst>2014-03-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.001207</Pct_Sales>
    <Sales>596.460</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.320835</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-03-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.407147</Pct_Sales>
    <Sales>137094.170</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.331953</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-04-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.101411</Pct_Sales>
    <Sales>592572.460</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.341590</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-04-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.410747</Pct_Sales>
    <Sales>583943.010</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.367940</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-04-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.450946</Pct_Sales>
    <Sales>129825.200</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.372337</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>MRO</Grp_Value>
    <MonthTrxDateFirst>2014-04-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.004888</Pct_Sales>
    <Sales>2885.350</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.321790</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-04-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.471696</Pct_Sales>
    <Sales>168637.830</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.323770</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-05-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.128278</Pct_Sales>
    <Sales>647972.500</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.345029</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-05-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.395531</Pct_Sales>
    <Sales>541736.100</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.413977</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DATACOMM</Grp_Value>
    <MonthTrxDateFirst>2014-05-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.041110</Pct_Sales>
    <Sales>2474.800</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.366580</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-05-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.385904</Pct_Sales>
    <Sales>131753.100</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.453110</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>HVAC/PLUMB/IND</Grp_Value>
    <MonthTrxDateFirst>2014-05-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.026418</Pct_Sales>
    <Sales>2571.720</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.380009</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>MRO</Grp_Value>
    <MonthTrxDateFirst>2014-05-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.059962</Pct_Sales>
    <Sales>26809.340</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.320173</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-05-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.586537</Pct_Sales>
    <Sales>152053.660</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.338931</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-06-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.114699</Pct_Sales>
    <Sales>519673.580</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.343102</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-06-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.485152</Pct_Sales>
    <Sales>602047.070</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.481070</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DATACOMM</Grp_Value>
    <MonthTrxDateFirst>2014-06-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.000139</Pct_Sales>
    <Sales>8.980</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.371727</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-06-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.484368</Pct_Sales>
    <Sales>136750.660</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.381854</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>HVAC/PLUMB/IND</Grp_Value>
    <MonthTrxDateFirst>2014-06-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.087700</Pct_Sales>
    <Sales>10847.080</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.373412</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>MRO</Grp_Value>
    <MonthTrxDateFirst>2014-06-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.470327</Pct_Sales>
    <Sales>202671.230</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.318483</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-06-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.527196</Pct_Sales>
    <Sales>168812.480</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.333249</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-07-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.116096</Pct_Sales>
    <Sales>684988.010</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.343053</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-07-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.490166</Pct_Sales>
    <Sales>632657.490</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.410114</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DATACOMM</Grp_Value>
    <MonthTrxDateFirst>2014-07-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.011413</Pct_Sales>
    <Sales>819.310</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.367737</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-07-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.419142</Pct_Sales>
    <Sales>148110.650</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.382776</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>HVAC/PLUMB/IND</Grp_Value>
    <MonthTrxDateFirst>2014-07-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.125291</Pct_Sales>
    <Sales>15785.270</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.367045</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>MRO</Grp_Value>
    <MonthTrxDateFirst>2014-07-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.448216</Pct_Sales>
    <Sales>292163.290</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.321970</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-07-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.512803</Pct_Sales>
    <Sales>166202.020</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.331511</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-08-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.117252</Pct_Sales>
    <Sales>701765.730</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.344469</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-08-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.464062</Pct_Sales>
    <Sales>659503.760</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.376877</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-08-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.375086</Pct_Sales>
    <Sales>119252.230</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.386056</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>HVAC/PLUMB/IND</Grp_Value>
    <MonthTrxDateFirst>2014-08-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.085056</Pct_Sales>
    <Sales>12308.170</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.374641</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>MRO</Grp_Value>
    <MonthTrxDateFirst>2014-08-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.398732</Pct_Sales>
    <Sales>236158.560</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.322817</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-08-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.569055</Pct_Sales>
    <Sales>161279.320</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.332573</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-09-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.116554</Pct_Sales>
    <Sales>674817.440</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.345736</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-09-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.448292</Pct_Sales>
    <Sales>657833.280</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.631698</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DATACOMM</Grp_Value>
    <MonthTrxDateFirst>2014-09-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.000469</Pct_Sales>
    <Sales>31.170</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.366126</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-09-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.356703</Pct_Sales>
    <Sales>133588.070</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.413377</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>HVAC/PLUMB/IND</Grp_Value>
    <MonthTrxDateFirst>2014-09-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.108217</Pct_Sales>
    <Sales>14713.660</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.367136</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>MRO</Grp_Value>
    <MonthTrxDateFirst>2014-09-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.387933</Pct_Sales>
    <Sales>241323.320</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.311605</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-09-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.572077</Pct_Sales>
    <Sales>208542.220</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.411575</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>blankcustomertype</Grp_Value>
    <MonthTrxDateFirst>2014-10-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.015683</Pct_Sales>
    <Sales>148.260</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.339036</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL</Grp_Value>
    <MonthTrxDateFirst>2014-10-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.123435</Pct_Sales>
    <Sales>742510.690</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.343491</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>COMMERCIAL/RESI</Grp_Value>
    <MonthTrxDateFirst>2014-10-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.496651</Pct_Sales>
    <Sales>767057.640</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.516780</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DATACOMM</Grp_Value>
    <MonthTrxDateFirst>2014-10-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.002760</Pct_Sales>
    <Sales>167.170</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.378926</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>DECOR/HOMEOWNER</Grp_Value>
    <MonthTrxDateFirst>2014-10-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.480457</Pct_Sales>
    <Sales>145768.060</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.402784</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>HVAC/PLUMB/IND</Grp_Value>
    <MonthTrxDateFirst>2014-10-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.175221</Pct_Sales>
    <Sales>19763.290</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.361361</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>MRO</Grp_Value>
    <MonthTrxDateFirst>2014-10-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.434791</Pct_Sales>
    <Sales>268824.030</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.325360</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>RESIDENTIAL</Grp_Value>
    <MonthTrxDateFirst>2014-10-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.460331</Pct_Sales>
    <Sales>180721.030</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>
</ArrayOfNew_DB2_TimeSeries_PctSales_Result>

同样的"问题"以前也咬过我。无论出于何种原因,"折线图"类型假定每个系列分组(在您的情况下,这些是"商业"、"DATACOMM"等(在 X 轴上每个可能的位置都有一个数据点(在您的案例月份(。

发生的情况是您的数据被分组和排序。然后,它采用第一组,恰好是:"blankcustomertype",并获取其所有类别轴可能性,这只有 1 个数据项:

  <New_DB2_TimeSeries_PctSales_Result>
    <GP_Pct>0.411575</GP_Pct>
    <Grp>CustomerType</Grp>
    <Grp_Value>blankcustomertype</Grp_Value>
    <MonthTrxDateFirst>2014-10-01T00:00:00</MonthTrxDateFirst>
    <Pct_Sales>0.015683</Pct_Sales>
    <Sales>148.260</Sales>
    <StdVsException>STRATEGIC</StdVsException>
  </New_DB2_TimeSeries_PctSales_Result>

然后,它使用此数据作为类别 (X( 轴,因此它只有 1 个数据点2014-10-01T00:00:00

所有其他系列

的其余日期将被忽略,因为第一个系列没有这些日期。

我唯一的猜测是,这是出于某种性能原因,因此循环较少。


您可能真正想要的是scatterLine图表类型。

这是一个有效的剑道道场示例(我只是复制/粘贴了您的原始代码并将XML转换为JSON以使其更容易(。

更改的图表选项包括:

$("#leftLine").kendoChart({    
    dataSource: {
        data: data,
        group: { field: "Grp_Value"},
        sort: {
            field: "MonthTrxDateFirst",
            dir: "asc"
        },
        schema: {
            model: {
                fields: {
                    MonthTrxDateFirst: {
                        type: "date"
                    }
                }
            }
        }
    },
    legend: {
        position: "top"
    },
    series: [{
        type:"scatterLine",
        yField: "Pct_Sales",
        xField: "MonthTrxDateFirst"
        //name: "% Strategy Sales"
    }],
    xAxis: {
        labels: {
            rotation: -90,
            dateFormats:
                {
                    minutes: "HH:mm",
                    hours: "HH:mm",
                    days: "dd/MM",
                    months: "MMM 'yy",
                    years: "yyyy"
                }
        }, type: "date",  baseUnit: "months"  ,              
        crosshair: {
            visible: true
        }
    },
    yAxis: {
        labels: {
            format: "{0:P1}"
        }
        //,majorUnit: 10000
    },
    tooltip: {
        visible: true,template: "<div >Date: #=kendo.toString(kendo.parseDate(dataItem.MonthTrxDateFirst, 'yyyy-MM-dd'), 'MM/dd/yyyy')# <br/>  "+
        " Sales: #=kendo.format('{0:C}',dataItem.Sales)# <br/> " +
        "Pct Sales: #=kendo.format('{0:P}',dataItem.Pct_Sales)# <br/> " +
        "GP Pct: #=kendo.format('{0:P}',dataItem.GP_Pct)# </div>"
    }
});

相关内容

  • 没有找到相关文章

最新更新