initial upload

This commit is contained in:
Kai Waggeling 2025-05-17 16:23:48 +02:00
parent ac114da487
commit 7c1cfdff51
63 changed files with 6883 additions and 0 deletions

36
sequelize/queue.model.mjs Normal file
View file

@ -0,0 +1,36 @@
import {
DataTypes
} from 'sequelize';
import {
DBLogger,
LabelDB
} from './db_conn.mjs'
import {
Printer
} from "./printer.model.mjs";
export const Queue = LabelDB.define('queue', {
id: {
type: DataTypes.UUID,
defaultValue: DataTypes.UUIDV4,
primaryKey: true
},
name: {
type: DataTypes.STRING,
allowNull: false
},
auto_print: {
type: DataTypes.BOOLEAN,
defaultValue: false,
allowNull: false
}
}, {
timestamps: false
});
Queue.belongsTo(Printer);
Printer.hasMany(Queue);