mirror of https://github.com/ghostfolio/ghostfolio
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
52 lines
1.3 KiB
52 lines
1.3 KiB
import { transformToBig } from '@ghostfolio/common/class-transformer';
|
|
import {
|
|
AssetProfileIdentifier,
|
|
HistoricalDataItem
|
|
} from '@ghostfolio/common/interfaces';
|
|
import { TimelinePosition } from '@ghostfolio/common/models';
|
|
|
|
import { Big } from 'big.js';
|
|
import { Transform, Type } from 'class-transformer';
|
|
|
|
export class PortfolioSnapshot {
|
|
activitiesCount: number;
|
|
|
|
createdAt: Date;
|
|
|
|
@Transform(transformToBig, { toClassOnly: true })
|
|
@Type(() => Big)
|
|
currentValueInBaseCurrency: Big;
|
|
|
|
errors: AssetProfileIdentifier[];
|
|
|
|
hasErrors: boolean;
|
|
|
|
historicalData: HistoricalDataItem[];
|
|
|
|
@Type(() => TimelinePosition)
|
|
positions: TimelinePosition[];
|
|
|
|
@Transform(transformToBig, { toClassOnly: true })
|
|
@Type(() => Big)
|
|
totalFeesWithCurrencyEffect: Big;
|
|
|
|
@Transform(transformToBig, { toClassOnly: true })
|
|
@Type(() => Big)
|
|
totalInterestWithCurrencyEffect: Big;
|
|
|
|
@Transform(transformToBig, { toClassOnly: true })
|
|
@Type(() => Big)
|
|
totalInvestment: Big;
|
|
|
|
@Transform(transformToBig, { toClassOnly: true })
|
|
@Type(() => Big)
|
|
totalInvestmentWithCurrencyEffect: Big;
|
|
|
|
@Transform(transformToBig, { toClassOnly: true })
|
|
@Type(() => Big)
|
|
totalLiabilitiesWithCurrencyEffect: Big;
|
|
|
|
@Transform(transformToBig, { toClassOnly: true })
|
|
@Type(() => Big)
|
|
totalValuablesWithCurrencyEffect: Big;
|
|
}
|
|
|