Class DataRequest
Represents the data operation information requested by the grid during event-driven data binding.
Inherited Members
Namespace: Syncfusion.Blazor.Grids
Assembly: Syncfusion.Blazor.Grids.dll
Syntax
public class DataRequest
Remarks
An instance of this class is provided through
Request whenever the grid raises
the OnDataLoad event.
The properties of this class describe the current state of the grid, including paging, filtering, sorting, searching, grouping, and aggregate operations. Use this information to retrieve the appropriate records from a custom data source, service, or repository.
Constructors
DataRequest()
Declaration
public DataRequest()
Properties
Aggregates
Gets or sets the aggregate definitions requested by the grid.
Declaration
[JsonPropertyName("aggregates")]
public List<AggregateRequest>? Aggregates { get; set; }
Property Value
| Type | Description |
|---|---|
| List<AggregateRequest> | A List<T> of AggregateRequest objects describing the aggregate operations to perform, or null when no aggregates are requested. |
Remarks
Use these definitions to compute aggregate values and populate AggregatesResult.
Expand
Gets or sets the navigation properties or related entities requested for expansion.
Declaration
[JsonPropertyName("expand")]
public List<string>? Expand { get; set; }
Property Value
| Type | Description |
|---|---|
| List<string> | A List<T> containing expand definitions, or null when no expansions are requested. |
Filter
Gets or sets the filtering criteria requested by the grid.
Declaration
[JsonPropertyName("where")]
public List<FilterRequest>? Filter { get; set; }
Property Value
| Type | Description |
|---|---|
| List<FilterRequest> | A List<T> of FilterRequest objects that describe the active filters, or null when no filtering is applied. |
Remarks
Apply these filter definitions to the underlying data source before returning the requested records.
Group
Gets or sets the grouping configuration requested by the grid.
Declaration
[JsonPropertyName("group")]
public List<string>? Group { get; set; }
Property Value
| Type | Description |
|---|---|
| List<string> | A List<T> containing the grouped field names, or null when grouping is not applied. |
Search
Gets or sets the search criteria requested by the grid.
Declaration
[JsonPropertyName("search")]
public List<SearchRequest>? Search { get; set; }
Property Value
| Type | Description |
|---|---|
| List<SearchRequest> | A List<T> of SearchRequest objects that describe the active search operations, or null when no search is applied. |
Remarks
Apply the specified search criteria before returning the requested records.
Select
Gets or sets the fields selected for the current request.
Declaration
[JsonPropertyName("select")]
public List<string>? Select { get; set; }
Property Value
| Type | Description |
|---|---|
| List<string> | A List<T> containing the selected field names, or null when no field projection is requested. |
Skip
Gets or sets the number of records to skip before returning data.
Declaration
[JsonPropertyName("skip")]
public int Skip { get; set; }
Property Value
| Type | Description |
|---|---|
| int | An int representing the zero-based offset requested by
the grid. The default value is |
Remarks
Use this value together with Take to support paging and virtual scrolling scenarios.
Sort
Gets or sets the sorting criteria requested by the grid.
Declaration
[JsonPropertyName("sort")]
public List<SortRequest>? Sort { get; set; }
Property Value
| Type | Description |
|---|---|
| List<SortRequest> | A List<T> of SortRequest objects that describe the requested sort order, or null when no sorting is applied. |
Remarks
Each item identifies a field and its sort direction.
Take
Gets or sets the maximum number of records to return.
Declaration
[JsonPropertyName("take")]
public int Take { get; set; }
Property Value
| Type | Description |
|---|---|
| int | An int representing the requested page size or virtual
scroll block size. The default value is |
Remarks
Use this value together with Skip when retrieving paged data from an external source.