wip
This commit is contained in:
@@ -10,7 +10,7 @@ import {
|
||||
type LeagueDriverSeasonStatsDTO,
|
||||
} from '@gridpilot/racing';
|
||||
import {
|
||||
getGetLeagueDriverSeasonStatsQuery,
|
||||
getGetLeagueDriverSeasonStatsUseCase,
|
||||
getDriverRepository,
|
||||
getLeagueMembershipRepository
|
||||
} from '@/lib/di-container';
|
||||
@@ -32,12 +32,13 @@ export default function LeagueStandingsPage() {
|
||||
|
||||
const loadData = useCallback(async () => {
|
||||
try {
|
||||
const getLeagueDriverSeasonStatsQuery = getGetLeagueDriverSeasonStatsQuery();
|
||||
const getLeagueDriverSeasonStatsUseCase = getGetLeagueDriverSeasonStatsUseCase();
|
||||
const driverRepo = getDriverRepository();
|
||||
const membershipRepo = getLeagueMembershipRepository();
|
||||
|
||||
const leagueStandings = await getLeagueDriverSeasonStatsQuery.execute({ leagueId });
|
||||
setStandings(leagueStandings);
|
||||
await getLeagueDriverSeasonStatsUseCase.execute({ leagueId });
|
||||
const standingsViewModel = getLeagueDriverSeasonStatsUseCase.presenter.getViewModel();
|
||||
setStandings(standingsViewModel);
|
||||
|
||||
const allDrivers = await driverRepo.findAll();
|
||||
const driverDtos: DriverDTO[] = allDrivers
|
||||
|
||||
Reference in New Issue
Block a user