Freigabe #4

Merged
bjoernpoettker merged 23 commits from Freigabe into main 2026-06-16 14:49:23 +00:00
Showing only changes of commit 4016802c1e - Show all commits
@@ -60,19 +60,19 @@ export class LabelPrintAgentController {
// Agent: nächsten Job abholen (Polling)
@Get('jobs/next')
async getNextJob(@Query('agentId') agentId: string, @Res({ passthrough: true }) res: Response) {
async getNextJob(@Query('agentId') agentId: string, @Res() res: Response) {
const job = await this.service.claimNextJob(agentId ?? 'unknown');
if (!job) {
res.status(HttpStatus.NO_CONTENT).send();
return;
}
return {
res.status(HttpStatus.OK).json({
jobId: String(job.Id),
labelImageBase64: job.LabelImageData ? job.LabelImageData.toString('base64') : null,
labelImageContentType: 'image/png',
labelWidthMm: job.LabelWidthMm,
labelHeightMm: job.LabelHeightMm,
};
});
}
// Agent: Bild separat abrufen