我想完全覆盖控制器路线。例如:
@Controller('shipments')
export class ShipmentsController {
@Post('/create')
async find(): Promise<Activities> {
return service.find()
}
}
Run Code Online (Sandbox Code Playgroud)
为了向前面的示例发出请求,URL 将为:http://localhost:8080/shipments/create
我想更改该 URL,而不将控制器移动到另一个类。例如,我希望该特定函数的 URL 为 http://localhost:8080/whatever/i/want。
这可能吗?