feat: implement backend label print agent system for remote label rendering and job management
Build and Push Multi-Platform Images / build-and-push (push) Successful in 33s
Build and Push Multi-Platform Images / build-and-push (push) Successful in 33s
This commit is contained in:
@@ -0,0 +1,51 @@
|
||||
import {
|
||||
Entity,
|
||||
PrimaryGeneratedColumn,
|
||||
Column,
|
||||
CreateDateColumn,
|
||||
} from 'typeorm';
|
||||
|
||||
@Entity('label_print_jobs')
|
||||
export class LabelPrintJob {
|
||||
@PrimaryGeneratedColumn()
|
||||
Id!: number;
|
||||
|
||||
@Column({ type: 'varchar', length: 20, default: 'pending' })
|
||||
Status!: 'pending' | 'printed' | 'error';
|
||||
|
||||
@Column({ type: 'mediumblob', nullable: true })
|
||||
LabelImageData!: Buffer | null;
|
||||
|
||||
@Column({ type: 'int' })
|
||||
LabelWidthMm!: number;
|
||||
|
||||
@Column({ type: 'int' })
|
||||
LabelHeightMm!: number;
|
||||
|
||||
@Column({ type: 'int', nullable: true })
|
||||
BarcodeTemplateId!: number | null;
|
||||
|
||||
@Column({ type: 'json', nullable: true })
|
||||
LabelVariables!: Record<string, string> | null;
|
||||
|
||||
@Column({ type: 'datetime', nullable: true })
|
||||
LockedAt!: Date | null;
|
||||
|
||||
@Column({ type: 'varchar', length: 255, nullable: true })
|
||||
LockedByAgent!: string | null;
|
||||
|
||||
@Column({ type: 'datetime', nullable: true })
|
||||
PrintedAt!: Date | null;
|
||||
|
||||
@Column({ type: 'varchar', length: 255, nullable: true })
|
||||
PrintedByAgent!: string | null;
|
||||
|
||||
@Column({ type: 'varchar', length: 255, nullable: true })
|
||||
PrinterName!: string | null;
|
||||
|
||||
@Column({ type: 'text', nullable: true })
|
||||
ErrorMessage!: string | null;
|
||||
|
||||
@CreateDateColumn()
|
||||
CreatedAt!: Date;
|
||||
}
|
||||
Reference in New Issue
Block a user