Hi to all,I'm trying to use a chart into a TileLayout.
my code
<
script
id
=
"newcontacts-template"
type
=
"text/x-kendo-template"
>
@(Html.Kendo().Chart<
Portale.Web2.Models.RolePages.ContactCount
>()
.Name("newContactChart")
.Title("Nuovi contatti per provenienza")
.Legend(legend => legend
.Position(ChartLegendPosition.Top)
)
.DataSource(ds => ds.Read(read => read.Action("NewContactRolePage", "Home")))
.Series(series => {
series.Bar(model => model.Count).Name("Nuovo Contatti").CategoryField("Category");
})
.CategoryAxis(axis => axis
//.Labels(labels => labels.Rotation(-90))
.Crosshair(c => c.Visible(true))
)
.ValueAxis(axis => axis.Numeric()
.Labels(labels => labels.Format("{0:N0}"))
)
.Tooltip(tooltip => tooltip
.Visible(true)
.Shared(true)
.Format("{0:N0}")
)
.HtmlAttributes(new { style = "height:100%;width:100%;" })
.ToClientTemplate()
)
</
script
>
<
div
class
=
"row"
>
<
div
class
=
"col"
>
@(Html.Kendo().TileLayout()
.Name("rolepagetilelayout")
.Columns(2)
.Containers(c => {
c.Add().Header(h => h.Text("Nuovi Contatti")).BodyTemplateId("newcontacts-template").ColSpan(2);
})
.Reorderable(true)
.Resizable(true)
.Events(e=>e.Resize("onTileResize"))
)
</
div
>
</
div
>
chart not resized, why?