gustavnavar / Grid.Blazor

Grid component with CRUD for Blazor (client-side and server-side) and ASP.NET Core MVC
GNU Lesser General Public License v2.1
696 stars 134 forks source link

DateTime Widget GridMvcCore #419

Open lhsomoza opened 1 month ago

lhsomoza commented 1 month ago

Net Core 3.1 GridMvcCore 5.0.3

in UI View Grid Column defined as: c.Add(o => o.Date.Date).Filterable(true).Format("{0:dd/MM/yyyy}"); Column shows as: image

The DateTime Widget to filter shows as , when we do not specify SetFilterWidgetType :

image

Datetime picker shows as: image

The problem, If a Date is selected to filter like "2024-07-19", no records are shown. I think is due to the format in the widget, no errors observed, and record exists with date "07/19/2024"

I tried: When adding the "SetFilterWidgetType" , The datetime picker does not show, like: c.Add(o => o.Date.Date).SetFilterWidgetType("DateRangeFilter").Filterable(true).Format("{0:dd/MM/yyyy}"); c.Add(o => o.Date.Date).SetFilterWidgetType("DateTimeFilter").Filterable(true).Format("{0:dd/MM/yyyy}");

Any suggestions, greatly appreciate it.