Aug 14, 2016, 9:56 PM
[CLOSED] [#1373] [4.1.0] Grid - Column-renderer-method, HTML-tags are rendered as text.
When using renderer on grid-columns the html-tags are output as text. The Sencha documentation says that the renderer method should return the HTML to be renderered, but now it is not working that way.
@{
var x = Html.X();
var data = new List<object>{
new
{
Name = "Lisa"
},
new
{
Name = "Bart"
},
new
{
Name = "Homer"
},
new
{
Name = "Marge"
}
};
}
@(
x.Grid()
.Columns(
x.Column()
.DataIndex("Name")
.Text("Name")
.Width(50)
.Flex(1)
.Renderer(@"return '<a>'+value+'</a>'")
)
.Store(x.Store()
.AutoDataBind(true)
.Fields(
x.ModelField().Name("Name")
)
.Data(data)
)
)
Here's the output:
Last edited by Daniil; Aug 17, 2016 at 7:25 PM.