Need help troubleshooting an issue with dynamic pages

I’ve got a dynamic page defined like so:

$clientDynamicPage = New-UDPage  -Url "/clients/:client" -endpoint {
    New-UDCard -Title "test" -content {$clientname}


However, in the same dashboard on the main page, I have an item with a URL pointing to: “/clients/$clientName”

foreach($object in $cache:objArr)

            $url = $($object.companyName).replace(" ","-")

            $presentationArray += [PSCustomObject]@{
            CompanyName      = New-UDLink -url "/clients/$url" -Text "$($object.companyName)"
            UserDelta        = New-UDElement -Tag 'div' -Attributes @{style = @{color = $usercolor}} -content {$object.userDelta}
            WorkstationDelta = New-UDElement -Tag 'div' -Attributes @{style = @{color = $workstationcolor}} -content {$object.workstationDelta}
            SpareDelta       = New-UDElement -Tag 'div' -Attributes @{style = @{color = $sparecolor}} -content {$object.sparedelta}
            ServerDelta      = New-UDElement -Tag 'div' -Attributes @{style = @{color = $servercolor}} -content {$object.ServerDelta}
            ExceptionDelta   = New-UDElement -Tag 'div' -Attributes @{style = @{color = $exceptionColor}} -content {$object.exceptionDelta}
            ReassignDelta    = New-UDElement -Tag 'div' -Attributes @{style = @{color = $reassignColor}} -content {$object.reassignDelta}                

    $presentationArray | out-UDtabledata -property @("companyName", "UserDelta","WorkstationDelta","SpareDelta","ServerDelta","ExceptionDelta","ReassignDelta")

When I click this link I’m taken to what appears to be the right URL, but the page is just white and empty.

Am I missing a step somewhere?

Are you running 2.3? There is a bug with dynamic pages that was found.

Your script looks correct.

1 Like

I actually did just update before I wrote that script. I’ll revert back to previous and see if it works – thanks for the reply @adam!

Yep, rolling back from 2.30 to 2.21 resolved that issue. Thanks again

1 Like