Skip to content

Commit

Permalink
fix ticket in round pages
Browse files Browse the repository at this point in the history
  • Loading branch information
harryob committed Oct 17, 2024
1 parent 4969fe4 commit e1b5f78
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/components/ticketmodal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -111,15 +111,17 @@ const TicketDetail = (props: {
const { tickets, ticket, round } = props;

const relevantTickets = tickets.filter(
(tick) => tick.ticketId == ticket && round && tick.roundId == round
(tick) => tick.ticketId == ticket && (round ? tick.roundId == round : true)
);

return (
<div className="flex flex-col pt-7 gap-2">
<div className="flex flex-row justify-center">
<LinkColor>
<Link to={`/Ticket/${round}`}>Round {round}</Link>
</LinkColor>
{round && (
<LinkColor>
<Link to={`/Ticket/${round}`}>Round {round}</Link>
</LinkColor>
)}
</div>
{relevantTickets.map((ticket) => (
<div key={ticket.id}>
Expand Down

0 comments on commit e1b5f78

Please sign in to comment.