update client after struct change

This commit is contained in:
Adam 2024-11-15 20:13:26 -05:00
parent a4ec55ae23
commit 59214e4d12

View file

@ -51,10 +51,10 @@ pub fn JudgingView() -> impl IntoView {
}); });
// Select card group // Select card group
for group in judge_round.get_untracked().unwrap().cards_to_judge { for entry in judge_round.get_untracked().unwrap().entries {
for card in &group { for card in &entry.cards_to_judge {
if card.uuid == card_clicked() { if card.uuid == card_clicked() {
set_selected_cards.update(|cards| cards.extend(group)); set_selected_cards.update(|cards| cards.extend(entry.cards_to_judge));
break; break;
} }
} }
@ -123,12 +123,13 @@ pub fn JudgingView() -> impl IntoView {
<div class="flex flex-nowrap overflow-scroll lg:inline-flex lg:flex-wrap lg:justify-center lg:overflow-none"> <div class="flex flex-nowrap overflow-scroll lg:inline-flex lg:flex-wrap lg:justify-center lg:overflow-none">
{judge_round() {judge_round()
.unwrap() .unwrap()
.cards_to_judge .entries
.into_iter() .into_iter()
.map(|group| { .map(|entries| {
view! { view! {
<div class="inline-flex flex-wrap"> <div class="inline-flex flex-wrap">
{group {entries
.cards_to_judge
.into_iter() .into_iter()
.map(|card| { .map(|card| {
view! { view! {