Hello!
I want to be able to change the value in a columns by calling this function MappingBoolToText.
If the passed argument is true I return "Ja" else return "Nej"
Function MappingBoolToText(value)
{
return value ? 'Ja' : 'Nej';
}
I have tried to call this function from here
$("#grid").kendoGrid(
{
dataSource: this.datasource,
height: 550,
sortable: true,
columns: [
{
field: "Name",
title: "Namn"
},
{
field: "EmployeeNr",
title: "AD"
},
{
field: "RequireR1",
title: "Krav R1"
},
{
field: "RequireR2",
title: "Krav R2"
},
{
field: "SalaryR1",
title: "Lön R1"
},
{
field: "SalaryR2",
title: "Lön R2"
},
{
field: "IsGroupAdmin",
title: "Koncernadmin",
fomat: MappingBoolToText(value)
},
{
field: "IsCompanyAdmin",
title: "Bolagadmin",
fomat: MappingBoolToText(value)
}
]
});