wip
This commit is contained in:
@@ -20,6 +20,7 @@ import {
|
||||
type LeagueAdminProtestsViewModel,
|
||||
} from '@/lib/presenters/LeagueAdminPresenter';
|
||||
import type { LeagueConfigFormModel } from '@gridpilot/racing/application';
|
||||
import type { LeagueSummaryViewModel } from '@/lib/presenters/LeagueAdminPresenter';
|
||||
import { LeagueBasicsSection } from './LeagueBasicsSection';
|
||||
import { LeagueStructureSection } from './LeagueStructureSection';
|
||||
import { LeagueScoringSection } from './LeagueScoringSection';
|
||||
@@ -37,13 +38,7 @@ import { AlertTriangle, CheckCircle, Clock, XCircle, Flag, Calendar, User, Dolla
|
||||
type JoinRequest = LeagueJoinRequestViewModel;
|
||||
|
||||
interface LeagueAdminProps {
|
||||
league: {
|
||||
id: string;
|
||||
ownerId: string;
|
||||
settings: {
|
||||
pointsSystem: string;
|
||||
};
|
||||
};
|
||||
league: LeagueSummaryViewModel;
|
||||
onLeagueUpdate?: () => void;
|
||||
}
|
||||
|
||||
@@ -83,7 +78,7 @@ export default function LeagueAdmin({ league, onLeagueUpdate }: LeagueAdminProps
|
||||
useEffect(() => {
|
||||
async function loadOwner() {
|
||||
try {
|
||||
const summary = await loadLeagueOwnerSummary(league);
|
||||
const summary = await loadLeagueOwnerSummary({ ownerId: league.ownerId });
|
||||
setOwnerSummary(summary);
|
||||
} catch (err) {
|
||||
console.error('Failed to load league owner:', err);
|
||||
|
||||
Reference in New Issue
Block a user