37 lines
971 B
TypeScript
37 lines
971 B
TypeScript
import { ApiProperty } from '@nestjs/swagger';
|
|
|
|
export class PrintDataDto {
|
|
@ApiProperty({
|
|
example: [
|
|
'--------------------------------',
|
|
' TESTE DE IMPRESSAO ',
|
|
'--------------------------------',
|
|
],
|
|
description: 'Lista de linhas de texto para imprimir',
|
|
})
|
|
lines: string[];
|
|
|
|
@ApiProperty({
|
|
required: false,
|
|
enum: ['left', 'center', 'right'],
|
|
example: 'center',
|
|
description: 'Alinhamento do texto',
|
|
})
|
|
alignment?: 'left' | 'center' | 'right';
|
|
|
|
@ApiProperty({
|
|
required: false,
|
|
example: false,
|
|
description: 'Se verdadeiro, imprime de cabeça para baixo (se suportado)',
|
|
})
|
|
upsideDown?: boolean;
|
|
|
|
@ApiProperty({
|
|
required: false,
|
|
example: 'tcp://10.1.119.13',
|
|
description:
|
|
'Interface da impressora. Obrigatorio ao usar /printer/print; ignorado ao usar /printer/:printerName/print. Ex: tcp://ip:porta ou printer:NomeDaImpressora',
|
|
})
|
|
printerInterface?: string;
|
|
}
|