Good morning,
I'm working on an web application and I was wondering the best way to go about initializing a prefiltered grid. Users see a flowchart of different statuses of a product, if they click on one of the statuses I would like it to go to the grid that I have with the status column filtered with the status that they selected.
I thought the best way to do this would be to create a separate method in the controller for each status, but that seemed a little clunky.
I currently have the status column as
columns.Bound(c => c.Status).Width(150)
.Title(
"Status"
)
.Filterable(filterable => filterable
.Cell(cell => cell
.ShowOperators(
false
)
.InputWidth(150)
.Operator(
"contains"
)
.SuggestionOperator(FilterType.Contains)
.Template(
"statusFilter"
)
)
);
function
statusFilter (element) {
element.element.kendoDropDownList({
dataSource: {
dataType:
"json"
,
transport: {
read:
"@Url.Action("
Status_Filter
", "
Controller
")"
}
},
optionLabel:
"--Select Status--"
});
}
Would I need to change how I have my filtering? Would you know how to do this?