@fdm-monster/server
Version:
FDM Monster is a bulk OctoPrint, Klipper, PrusaLink and BambuLab manager to set up, configure and monitor 3D printers. Our aim is to provide neat overview over your farm.
63 lines (62 loc) • 3.4 kB
JavaScript
import { __decorateMetadata } from "../_virtual/_@oxc-project_runtime@0.129.0/helpers/decorateMetadata.js";
import { __decorate } from "../_virtual/_@oxc-project_runtime@0.129.0/helpers/decorate.js";
import { Printer } from "./printer.entity.js";
import { User } from "./user.entity.js";
import { Column, CreateDateColumn, Entity, Index, ManyToOne, PrimaryGeneratedColumn } from "typeorm";
//#region src/entities/printer-maintenance-log.entity.ts
var _ref, _ref2;
let PrinterMaintenanceLog = class PrinterMaintenanceLog {
id;
createdAt;
createdBy;
createdByUser;
createdByUserId;
printer;
printerId;
printerName;
printerUrl;
metadata;
completed;
completedAt;
completedByUser;
completedByUserId;
completedBy;
};
__decorate([PrimaryGeneratedColumn(), __decorateMetadata("design:type", Number)], PrinterMaintenanceLog.prototype, "id", void 0);
__decorate([CreateDateColumn(), __decorateMetadata("design:type", typeof (_ref = typeof Date !== "undefined" && Date) === "function" ? _ref : Object)], PrinterMaintenanceLog.prototype, "createdAt", void 0);
__decorate([Column({ nullable: false }), __decorateMetadata("design:type", String)], PrinterMaintenanceLog.prototype, "createdBy", void 0);
__decorate([ManyToOne(() => User, {
onDelete: "SET NULL",
nullable: true
}), __decorateMetadata("design:type", Object)], PrinterMaintenanceLog.prototype, "createdByUser", void 0);
__decorate([Column({ nullable: true }), __decorateMetadata("design:type", Object)], PrinterMaintenanceLog.prototype, "createdByUserId", void 0);
__decorate([ManyToOne(() => Printer, {
onDelete: "SET NULL",
nullable: true
}), __decorateMetadata("design:type", Object)], PrinterMaintenanceLog.prototype, "printer", void 0);
__decorate([Column({ nullable: true }), __decorateMetadata("design:type", Object)], PrinterMaintenanceLog.prototype, "printerId", void 0);
__decorate([Column({ nullable: false }), __decorateMetadata("design:type", String)], PrinterMaintenanceLog.prototype, "printerName", void 0);
__decorate([Column({ nullable: false }), __decorateMetadata("design:type", String)], PrinterMaintenanceLog.prototype, "printerUrl", void 0);
__decorate([Column({
nullable: false,
type: "json",
default: "{}"
}), __decorateMetadata("design:type", Object)], PrinterMaintenanceLog.prototype, "metadata", void 0);
__decorate([Column({
nullable: false,
default: false
}), __decorateMetadata("design:type", Boolean)], PrinterMaintenanceLog.prototype, "completed", void 0);
__decorate([Column({ nullable: true }), __decorateMetadata("design:type", typeof (_ref2 = typeof Date !== "undefined" && Date) === "function" ? _ref2 : Object)], PrinterMaintenanceLog.prototype, "completedAt", void 0);
__decorate([ManyToOne(() => User, {
onDelete: "SET NULL",
nullable: true
}), __decorateMetadata("design:type", Object)], PrinterMaintenanceLog.prototype, "completedByUser", void 0);
__decorate([Column({ nullable: true }), __decorateMetadata("design:type", Object)], PrinterMaintenanceLog.prototype, "completedByUserId", void 0);
__decorate([Column({ nullable: true }), __decorateMetadata("design:type", String)], PrinterMaintenanceLog.prototype, "completedBy", void 0);
PrinterMaintenanceLog = __decorate([Entity(), Index(["printerId"], {
unique: true,
where: "completed = 0"
})], PrinterMaintenanceLog);
//#endregion
export { PrinterMaintenanceLog };
//# sourceMappingURL=printer-maintenance-log.entity.js.map