RenderCheckbox values should not be limited to Id property

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
4 yıl önce
Hi,

When we use RenderCheckBox in datatable  then we have to use Id as property to bind value because of then

case RenderCheckBox checkBox:
                    <text>
                    render: function (data, type, row, meta) {
                        return (data === 'true')
                            ? '<input name="@checkBox.Name" value="' + row.Id + '" type="checkbox" class="checkboxGroups" checked="checked" />'
                            : '<input name="@checkBox.Name" value="' + row.Id + '" type="checkbox" class="checkboxGroups" />';
                    },
                    </text>
                    break;
in _Table.Definition.cshtml.

I think, it should not be limited to Id property.
We are unable to use another model property to bind values in checkboxes.
There should be another parameter pass from RenederCheckBox to use in row.PropertyName.

What do you think?
4 yıl önce
Thanks a lot! I created a work item here.
4 yıl önce
Done. Please see this commit.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.