chore: fmt

This commit is contained in:
Michael Abebe
2026-05-12 16:50:18 +03:00
parent 4540d35215
commit 1c5ee19388
181 changed files with 1492 additions and 1100 deletions

View File

@@ -1,35 +1,41 @@
import { BaseEntity } from '@edr/api-common';
import { Freight } from '@edr/types';
import { Column, Entity } from 'typeorm';
import { BaseEntity } from "@edr/api-common";
import { Freight } from "@edr/types";
import { Column, Entity } from "typeorm";
@Entity({ name: 'bookings' })
@Entity({ name: "bookings" })
export class Booking extends BaseEntity {
@Column({ name: 'reference', type: 'varchar', length: 64, unique: true })
@Column({ name: "reference", type: "varchar", length: 64, unique: true })
reference!: string;
@Column({ name: 'customer_id', type: 'uuid' })
@Column({ name: "customer_id", type: "uuid" })
customerId!: string;
@Column({ name: 'train_id', type: 'uuid', nullable: true })
@Column({ name: "train_id", type: "uuid", nullable: true })
trainId?: string | null;
@Column({
name: 'status',
type: 'enum',
name: "status",
type: "enum",
enum: Freight.BookingStatus,
default: Freight.BookingStatus.Draft,
})
status!: Freight.BookingStatus;
@Column({ name: 'scheduled_date', type: 'timestamptz' })
@Column({ name: "scheduled_date", type: "timestamptz" })
scheduledDate!: Date;
@Column({ name: 'total_amount', type: 'numeric', precision: 14, scale: 2, default: 0 })
@Column({
name: "total_amount",
type: "numeric",
precision: 14,
scale: 2,
default: 0,
})
totalAmount!: number;
@Column({
name: 'payment_status',
type: 'enum',
name: "payment_status",
type: "enum",
enum: Freight.PaymentStatus,
default: Freight.PaymentStatus.Pending,
})