We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Grid selection doesn't work with remote data and search of a specific column

Thread ID:

Created:

Updated:

Platform:

Replies:

149987 Dec 17,2019 08:58 AM UTC Dec 19,2019 06:38 AM UTC Blazor 5
loading
Tags: Grid
Pascal Botzke
Asked On December 17, 2019 03:42 PM UTC

Hi SyncFusion,

I am build a blazor app using a grid. To simplify my problem I have reduced my problem to different examples you provide.

The selection of a grid row and/or cell doesn't work together with Remote data and search specific column.

For my simplified example I have used:

- https://ej2.syncfusion.com/blazor/documentation/grid/data-binding/#binding-with-odata-v4-services
- https://ej2.syncfusion.com/blazor/documentation/grid/searching/#search-specific-columns
- https://ej2.syncfusion.com/blazor/documentation/grid/selection/

My example, which doesn't work:

@using Syncfusion.EJ2.Blazor.Data
@using Syncfusion.EJ2.Blazor.Grids

         AllowSelection="true" Toolbar="@(new List() { "Search" })">
   
   
   
       
       
       
       
       
   

@code {
    public List Orders { get; set; }

    protected override void OnInitialized()
    {
        Orders = Enumerable.Range(1, 75).Select(x => new Order()
        {
            OrderID = 1000 + x,
            CustomerID = (new string[] { "ALFKI", "ANANTR", "ANTON", "BLONP", "BOLID" })[new Random().Next(5)],
            Freight = 2.1 * x,
            OrderDate = DateTime.Now.AddDays(-x),
        }).ToList();
    }

    public Order GridOrderModel { get; set; }

    public class Order
    {
        public int? OrderID { get; set; }
        public string CustomerID { get; set; }
        public DateTime? OrderDate { get; set; }
        public double? Freight { get; set; }
    }
}

Update: I am using .NET Core 3.1 Blazor Server and Syncfusion.EJ2.Blazor Version 17.3.0.29-beta

Thank you very much!

Kind regards
Pascal


Pascal Botzke
Replied On December 17, 2019 03:43 PM UTC

Hi SyncFusion,

I am build a blazor app using a grid. To simplify my problem I have reduced my problem to different examples you provide.

The selection of a grid row and/or cell doesn't work together with Remote data and search specific column.

For my simplified example I have used:

- https://ej2.syncfusion.com/blazor/documentation/grid/data-binding/#binding-with-odata-v4-services
- https://ej2.syncfusion.com/blazor/documentation/grid/searching/#search-specific-columns
- https://ej2.syncfusion.com/blazor/documentation/grid/selection/

My example, which doesn't work:

@using Syncfusion.EJ2.Blazor.Data
@using Syncfusion.EJ2.Blazor.Grids

<EjsGrid TValue="Order" ModelType="@GridOrder" AllowPaging="true" Height="300" Width="650"
         AllowSelection="true" Toolbar="@(new List<string>() { "Search" })">
    <EjsDataManager Url="https://services.odata.org/V4/Northwind/Northwind.svc/Orders/" Adaptor="Adaptors.ODataV4Adaptor"></EjsDataManager>
    <GridSearchSettings Fields="@(new string[] { "OrderID", "CustomerId" })"></GridSearchSettings>
    <GridColumns>
        <GridColumn Type="ColumnType.CheckBox" Width="50"></GridColumn>
        <GridColumn Field=@nameof(Order.OrderID) HeaderText="Order ID" TextAlign="TextAlign.Right" Width="120"></GridColumn>
        <GridColumn Field=@nameof(Order.CustomerID) HeaderText="Customer Name" Width="150"></GridColumn>
        <GridColumn Field=@nameof(Order.OrderDate) HeaderText=" Order Date" Format="yMd" Type="ColumnType.Date" TextAlign="TextAlign.Right" Width="130"></GridColumn>
        <GridColumn Field=@nameof(Order.Freight) HeaderText="Freight" Format="C2" TextAlign="TextAlign.Right" Width="120"></GridColumn>
    </GridColumns>
</EjsGrid>

@code {
    public List Orders { get; set; }

    protected override void OnInitialized()
    {
        Orders = Enumerable.Range(1, 75).Select(x => new Order()
        {
            OrderID = 1000 + x,
            CustomerID = (new string[] { "ALFKI", "ANANTR", "ANTON", "BLONP", "BOLID" })[new Random().Next(5)],
            Freight = 2.1 * x,
            OrderDate = DateTime.Now.AddDays(-x),
        }).ToList();
    }

    public Order GridOrderModel { get; set; }

    public class Order
    {
        public int? OrderID { get; set; }
        public string CustomerID { get; set; }
        public DateTime? OrderDate { get; set; }
        public double? Freight { get; set; }
    }
}

Update: I am using .NET Core 3.1 Blazor Server and Syncfusion.EJ2.Blazor Version 17.3.0.29-beta

Thank you very much
Kind regards
Pascal

PS: There was a display error to my example code

Pascal Botzke
Replied On December 18, 2019 10:41 AM UTC

Hi SyncFusion,

I found the new Version 17.4.0.39 this morning. My Problem seems to be solved with this version.

But my licence doesn't work any more. We contact you via email for this problem.

Kind Regards
Pascal

Renjith Singh Rajendran [Syncfusion]
Replied On December 18, 2019 01:54 PM UTC

Hi Pascal, 

Thanks for contacting Syncfusion support. 

Query : But my licence doesn't work any more. We contact you via email for this problem. 
We suggest you to refer to the below KB to resolve this problem. 

Please get back to us if you need further assistance. 

Regards, 
Renjith Singh Rajendran. 


Pascal Botzke
Replied On December 18, 2019 02:31 PM UTC

Hi Renjith Singh Rajendran,

thank you for the KB Link. With this I was able to solve the licence problem.

Regards,
Pascal Botzke

Vignesh Natarajan [Syncfusion]
Replied On December 19, 2019 03:39 AM UTC

Hi Pascal,  

Thanks for the update.  

We ae glad to hear that you have resolved your query using our solution.  

Please get back to us if you have further queries.  

Regards, 
Vignesh Natarajan. 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon