feat: update PowerClamp routes to support historical data retrieval

This commit is contained in:
faris Aljohari
2025-04-24 15:08:54 +03:00
parent 1bdb13846f
commit 72e65882b1
2 changed files with 4 additions and 3 deletions

View File

@ -494,9 +494,10 @@ export class ControllerRoute {
public static readonly ROUTE = 'power-clamp'; public static readonly ROUTE = 'power-clamp';
static ACTIONS = class { static ACTIONS = class {
public static readonly GET_ENERGY_SUMMARY = 'Get power clamp data'; public static readonly GET_ENERGY_SUMMARY =
'Get power clamp historical data';
public static readonly GET_ENERGY_DESCRIPTION = public static readonly GET_ENERGY_DESCRIPTION =
'This endpoint retrieves power clamp data for a specific device.'; 'This endpoint retrieves the historical data of a power clamp device based on the provided parameters.';
}; };
}; };
static DEVICE = class { static DEVICE = class {

View File

@ -17,7 +17,7 @@ export class PowerClampController {
@ApiBearerAuth() @ApiBearerAuth()
@UseGuards(JwtAuthGuard) @UseGuards(JwtAuthGuard)
@Get(':powerClampUuid') @Get(':powerClampUuid/historical')
@ApiOperation({ @ApiOperation({
summary: ControllerRoute.PowerClamp.ACTIONS.GET_ENERGY_SUMMARY, summary: ControllerRoute.PowerClamp.ACTIONS.GET_ENERGY_SUMMARY,
description: ControllerRoute.PowerClamp.ACTIONS.GET_ENERGY_DESCRIPTION, description: ControllerRoute.PowerClamp.ACTIONS.GET_ENERGY_DESCRIPTION,