frontend / api/analytics/stock / getStockValueOverTime
Function: getStockValueOverTime()
getStockValueOverTime(
p?):Promise<StockValuePoint[]>
Defined in: src/api/analytics/stock.ts:34
Fetch total inventory value over time. Returns array of {date, totalValue}. Empty array on errors.
Parameters
p?
from?
string = ...
supplierId?
string = ...
to?
string = ...
Returns
Promise<StockValuePoint[]>
Example
const points = await getStockValueOverTime({
from: '2025-09-01',
to: '2025-11-30',
supplierId: 'SUP-001'
});
return <LineChart data={points} />;