basic ad entity without direction

This commit is contained in:
sbriat
2023-08-18 16:50:55 +02:00
parent db13f4d87e
commit 88326dcf6f
10 changed files with 74 additions and 10 deletions

View File

@@ -5,9 +5,9 @@ import { DefaultParams } from '../core/application/types/default-params.type';
@Injectable()
export class DefaultParamsProvider implements DefaultParamsProviderPort {
constructor(private readonly _configService: ConfigService) {}
constructor(private readonly configService: ConfigService) {}
getParams = (): DefaultParams => ({
GEOROUTER_TYPE: this._configService.get('GEOROUTER_TYPE'),
GEOROUTER_URL: this._configService.get('GEOROUTER_URL'),
GEOROUTER_TYPE: this.configService.get('GEOROUTER_TYPE'),
GEOROUTER_URL: this.configService.get('GEOROUTER_URL'),
});
}

View File

@@ -1,6 +1,8 @@
import { Coordinates } from '../core/application/types/coordinates.type';
import { DirectionEncoderPort } from '../core/application/ports/direction-encoder.port';
import { Injectable } from '@nestjs/common';
@Injectable()
export class PostgresDirectionEncoder implements DirectionEncoderPort {
encode = (coordinates: Coordinates[]): string =>
[