mirror of
https://gitlab.com/mobicoop/v3/service/matcher.git
synced 2026-01-01 08:32:41 +00:00
extract carpool informations from geography module
This commit is contained in:
@@ -16,17 +16,11 @@ export class RouteMapper
|
||||
{
|
||||
toResponse = (entity: RouteEntity): RouteResponseDto => {
|
||||
const response = new RouteResponseDto();
|
||||
response.driverDistance = entity.getProps().driverDistance
|
||||
? Math.round(entity.getProps().driverDistance as number)
|
||||
response.distance = entity.getProps().distance
|
||||
? Math.round(entity.getProps().distance as number)
|
||||
: undefined;
|
||||
response.driverDuration = entity.getProps().driverDuration
|
||||
? Math.round(entity.getProps().driverDuration as number)
|
||||
: undefined;
|
||||
response.passengerDistance = entity.getProps().passengerDistance
|
||||
? Math.round(entity.getProps().passengerDistance as number)
|
||||
: undefined;
|
||||
response.passengerDuration = entity.getProps().passengerDuration
|
||||
? Math.round(entity.getProps().passengerDuration as number)
|
||||
response.duration = entity.getProps().duration
|
||||
? Math.round(entity.getProps().duration as number)
|
||||
: undefined;
|
||||
response.fwdAzimuth = Math.round(entity.getProps().fwdAzimuth);
|
||||
response.backAzimuth = Math.round(entity.getProps().backAzimuth);
|
||||
|
||||
Reference in New Issue
Block a user