fix
This commit is contained in:
@@ -270,6 +270,18 @@ export async function getSitePrices(siteId: number, date: string): Promise<SiteE
|
||||
return Array.isArray(data) ? data : []
|
||||
}
|
||||
|
||||
export async function getSitePricesSlotsRange(
|
||||
siteId: number,
|
||||
fromIso: string,
|
||||
toIso: string,
|
||||
): Promise<SiteEffectivePriceRowDto[]> {
|
||||
const { data } = await client.get<{ slots?: SiteEffectivePriceRowDto[] }>(
|
||||
`/sites/${siteId}/prices/slots`,
|
||||
{ params: { from: fromIso, to: toIso }, timeout: 60_000 },
|
||||
)
|
||||
return Array.isArray(data?.slots) ? data.slots : []
|
||||
}
|
||||
|
||||
export type ForecastPvIntervalRow = {
|
||||
interval_start: string
|
||||
power_w?: number | string | null
|
||||
|
||||
Reference in New Issue
Block a user