Use the LoadData
event to get data from a REST service.
|
ID
|
First Name
filter_alt
|
Last Name
filter_alt
|
Title
filter_alt
|
Customers
filter_alt
|
Title Of Courtesy
filter_alt
|
Birth Date
filter_alt
|
Hire Date
filter_alt
|
Address
filter_alt
|
City
filter_alt
|
Region
filter_alt
|
Postal Code
filter_alt
|
Country
filter_alt
|
Home Phone
filter_alt
|
Extension
filter_alt
|
Notes
filter_alt
|
|
---|
1. Set the Data and Count properties.
<RadzenDataGrid Count="@count" Data="@employees"
2. Handle the LoadData event and update the Data and Count backing fields (employees
and count
in this case).
async Task LoadData(LoadDataArgs args)
{
var result = await service.GetEmployees(filter: args.Filter, top: args.Top, skip: args.Skip, orderby: args.OrderBy, count: true);
employees = result.Value.AsODataEnumerable();
count = result.Count;
}
Radzen Blazor Studio is a software development environment that empowers developers to design, build and deploy Blazor applications without the traditional hurdles. Write less code and get more done.
Radzen Blazor Components, © 2018-2024 Radzen.
Source Code licensed under
MIT
Premium Themes
Free Themes