mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-27 15:30:56 +00:00
19 lines
599 B
TypeScript
19 lines
599 B
TypeScript
import { Controller, Get, Param, ParseUUIDPipe } from "@nestjs/common";
|
|
import { ApiOperation, ApiTags } from "@nestjs/swagger";
|
|
|
|
import { TrackingService } from "./tracking.service";
|
|
|
|
@ApiTags("tracking")
|
|
@Controller("tracking")
|
|
export class TrackingController {
|
|
constructor(private readonly trackingService: TrackingService) {}
|
|
|
|
@Get(":consignmentId")
|
|
@ApiOperation({ summary: "Get the tracking timeline for a consignment" })
|
|
findByConsignment(
|
|
@Param("consignmentId", ParseUUIDPipe) consignmentId: string,
|
|
) {
|
|
return this.trackingService.findByConsignment(consignmentId);
|
|
}
|
|
}
|