refactor: replace deep imports with native node aliases (WealthLedger/backend#165) (#193)
This commit was merged in pull request #193.
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
import { Injectable } from '@nestjs/common';
|
||||
|
||||
import type { TbankBond } from '../../../../../integrations/tbank/tbank.api';
|
||||
import type { TbankBond } from '#src/integrations/tbank/tbank.api';
|
||||
|
||||
import { formatDecimal } from '#src/common/decimal';
|
||||
import { decimal } from '#src/integrations/tbank/decimal';
|
||||
|
||||
import { formatDecimal } from '../../../../../common/decimal';
|
||||
import { decimal } from '../../../../../integrations/tbank/decimal';
|
||||
import { CatalogDiscoveryService } from '../../application/catalog-discovery.service';
|
||||
import { timestamp } from '../../application/instrument-market';
|
||||
import {
|
||||
@@ -14,7 +15,8 @@ import {
|
||||
|
||||
type IdentifiedBond = TbankBond & { uid: string };
|
||||
|
||||
import { ISO_DATE_LENGTH, ISO_DATE_START } from '../../../../../common/time';
|
||||
import { ISO_DATE_LENGTH, ISO_DATE_START } from '#src/common/time';
|
||||
|
||||
import { money } from '../infrastructure/bond-money.mapper';
|
||||
|
||||
const MIN_LOT_EXCLUSIVE = 0;
|
||||
|
||||
@@ -5,19 +5,20 @@ import {
|
||||
divide,
|
||||
formatDecimal,
|
||||
multiply,
|
||||
} from '../../../../../common/decimal';
|
||||
import { ISO_DATE_LENGTH, ISO_DATE_START } from '../../../../../common/time';
|
||||
import { isTbankProtocolValue, TbankCouponType } from '../../../../../integrations/tbank/tbank-protocol';
|
||||
} from '#src/common/decimal';
|
||||
import { ISO_DATE_LENGTH, ISO_DATE_START } from '#src/common/time';
|
||||
import { isTbankProtocolValue, TbankCouponType } from '#src/integrations/tbank/tbank-protocol';
|
||||
import {
|
||||
TbankAccessService,
|
||||
type TbankBond,
|
||||
type TbankCoupon,
|
||||
tbankSourceNeedsRefresh,
|
||||
} from '../../../../../integrations/tbank/tbank.api';
|
||||
} from '#src/integrations/tbank/tbank.api';
|
||||
import {
|
||||
ForecastService,
|
||||
PortfolioService,
|
||||
} from '../../../portfolio/portfolio.api';
|
||||
} from '#src/modules/investments/portfolio/portfolio.api';
|
||||
|
||||
import {
|
||||
CatalogEnrichmentService,
|
||||
type CatalogPayload,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Injectable } from '@nestjs/common';
|
||||
|
||||
import type { TbankBond } from '../../../../../integrations/tbank/tbank.api';
|
||||
import type { TbankBond } from '#src/integrations/tbank/tbank.api';
|
||||
|
||||
import {
|
||||
add,
|
||||
@@ -9,9 +9,10 @@ import {
|
||||
formatDecimal,
|
||||
multiply,
|
||||
subtract,
|
||||
} from '../../../../../common/decimal';
|
||||
import { ISO_DATE_LENGTH, ISO_DATE_START } from '../../../../../common/time';
|
||||
import { decimal } from '../../../../../integrations/tbank/decimal';
|
||||
} from '#src/common/decimal';
|
||||
import { ISO_DATE_LENGTH, ISO_DATE_START } from '#src/common/time';
|
||||
import { decimal } from '#src/integrations/tbank/decimal';
|
||||
|
||||
import { CandleService } from '../../application/candle.service';
|
||||
import {
|
||||
CatalogEnrichmentService,
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import type { PortfolioDto } from '../../../portfolio/portfolio.api';
|
||||
import type { PortfolioDto } from '#src/modules/investments/portfolio/portfolio.api';
|
||||
|
||||
import { instrumentPosition } from '../../application/instrument-position';
|
||||
import { bondCoupons, bondMetrics } from './bond-income.service';
|
||||
import { bondQuote } from './bond-market.service';
|
||||
jest.mock('../../../../../prisma/prisma.service', () => ({
|
||||
jest.mock('#src/prisma/prisma.service', () => ({
|
||||
PrismaService: class {},
|
||||
}));
|
||||
const time = (value: string) => ({ seconds: String(Date.parse(value) / 1000) });
|
||||
|
||||
Reference in New Issue
Block a user