Skip to content

Commit

Permalink
fix(dashboard): use tenantId in href for WfSpecs (#1165)
Browse files Browse the repository at this point in the history
- we missed one href
- I double checked all the others and good to go
  • Loading branch information
HazimAr authored Nov 27, 2024
1 parent 3e67fa7 commit 956d78a
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { TagIcon } from 'lucide-react'
import { useParams, useRouter } from 'next/navigation'
import { FC, Fragment, useEffect, useState } from 'react'
import { SearchResultProps } from '.'
import LinkWithTenant from '../LinkWithTenant'

export const WfSpecTable: FC<SearchResultProps> = ({ pages = [] }) => {
const router = useRouter()
Expand All @@ -25,17 +26,16 @@ export const WfSpecTable: FC<SearchResultProps> = ({ pages = [] }) => {
<div className="flex max-h-[600px] flex-col overflow-auto">
{wfSpecs.map(wfSpec => (
<Fragment key={wfSpec.name}>
<button
<LinkWithTenant
className="flex items-center gap-3 rounded-md px-2 py-2 hover:bg-gray-100"
key={wfSpec.name}
onClick={() => router.push(`/wfSpec/${wfSpec.name}/${wfSpec.latestVersion}`)}
href={`/wfSpec/${wfSpec.name}/${wfSpec.latestVersion}`}
>
<p>{wfSpec.name}</p>
<div className="flex items-center gap-2 rounded bg-blue-200 px-2 font-mono text-sm text-gray-500">
<TagIcon className="h-4 w-4 fill-none stroke-gray-500 stroke-1" />
Latest: v{wfSpec.latestVersion}
</div>
</button>
</LinkWithTenant>
<Separator />
</Fragment>
))}
Expand Down

0 comments on commit 956d78a

Please sign in to comment.