Renderer Error with FilterType date

Hi All -

I am getting “Renderer Error” when trying to use “-FilterType date” in UDTableColoumn.

image

The object is in datetime. Has anyone seen this before?

Name          MemberType   Definition                                   
----          ----------   ----------                                   
Equals        Method       bool Equals(System.Object obj)               
GetHashCode   Method       int GetHashCode()                            
GetType       Method       type GetType()                               
ToString      Method       string ToString()                            
Calendar Name NoteProperty string Calendar Name=xxxxx
Date          NoteProperty datetime Date=1/1/2021 12:00:00 AM           
Pattern       NoteProperty string Pattern=xxxxx             
Timezone      NoteProperty string Timezone=xxxxx

I have the same issue.

This should be resolved in 2.1.0. It’s also been fixed in the latest nightly.

Thanks alot adam. I will wait for the official release.

I have upgraded to V2.1.1, but I am still getting the Renderer Error.

I changed to latest UD3.5.0.

Can you share more of your dashboard script?

Likewise over here,

Below some code snippet of my column, the others render good. Eg. select, text, etc.

New-UDTableColumn -Property TijdstipVerwerking -Title "Startdatum" -Render {
	$GrantingPeriodeStart = $EventData.TijdstipVerwerking
	if ($null -ne $GrantingPeriodeStart) {
	    New-UDTypography -Text $GrantingPeriodeStart.ToString().Split(" ")[0]
	}
	else {
	    New-UDTypography -Text "Nog niet verwerkt."
	}
} -IncludeInSearch -Filter -FilterType date

Below the table summary:

New-UDTable -Data $grantedRights -Columns $Columns -ShowFilter -Dense -ShowPagination -PageSize 4

kind regards.
Frederik

In version 2.4.1 getting a render error as well when trying to use the date filter type.
I’ve tried different variations of it, passing the unmodified property (datetime datatype), multiple methods (ToString(), ToLocalTime(), ToShortDateString()), doesn’t seem to like any of them.

This is what it looks like with no applied methods and no filter set on the column.
image

@adam, do you have any examples of using the date filter type?
On the docs page for filters I only see examples for autocomplete and range Table - PowerShell Universal

Are you sure that the data type for LastpasswordChangeDatetime is datetime, and not a string?

Usually it doesn’t show like universaldatetime unless it has been formatted and made a string.

I’m also having the same issue with the date filter on build 2.4.1. The code for my page is this:

New-UDPage -Name "Local Admins Audit" -url "LocalAdmin-Audit" -Content {
    New-UDScrollUp
    $Columns = @(
        New-UDTableColumn -Title "Username" -Property Username -IncludeInSearch -Filter 
        New-UDTableColumn -Title "Computern Name" -Property ComputerName  -IncludeInSearch -Filter 
        New-UDTableColumn -Title "Time Modified" -Property OriginalTimeModified  -IncludeInSearch -Filter -FilterType date
        New-UDTableColumn -Title "Last Modifiedy By" -Property LastModifiedBy  -IncludeInSearch -Filter 
        New-UDTableColumn -Title "Object Type" -Property ObjectType  -IncludeInSearch -Filter  -FilterType select
        New-UDTableColumn -Title "Audit Time" -Property AuditTime -IncludeInSearch -Filter -FilterType date
        New-UDTableColumn -Title "Audit Action" -Property AuditAction  -IncludeInSearch -Filter -FilterType select
    )
    $data = Invoke-RestMethod "http://localhost:5000/LocalAdministrators/Audit"
    $data | Sort-Object -Property AuditTime -Descending
    New-UDTable -Data $data -Columns $Columns -ShowSort -Dense -ShowFilter -ShowSearch -ShowPagination -PageSizeOptions @(10,50,100) -PageSize 10
} -Navigation $NavigationInvoke-RestMethod http://localhost:5000/LocalAdministrators/Audit

Inspecting the data types of the data returned from Invoke-RestMethod shows this:
image

Tracking here: Renderer Error in UDTable when FilterType is set to date · Issue #667 · ironmansoftware/issues · GitHub