I have a column for weight (in Kg). When the user clicks on it I need to enable them to be able to put in decimal number with 3 places.
The problem I have is at the mome
Several questions (afaik):
n4
but as {0:n4}
.{0:n4} Kg.
decimals
, step
so you should define an editor function.In addition, I don't understand your problems with decimals and round.
What I suggest is define the columns as:
{
field: "weight",
title: "Weight",
width: 40,
editor: numberEditor,
format: '{0:n3} Kg.'
}
(assuming that you want three decimal precision) and define numberEditor
as:
function numberEditor(container, options) {
$('')
.appendTo(container)
.kendoNumericTextBox({
format : "{0:n3}",
decimals: 3,
step : 0.001
});
}