diff --git a/server/src/db/config.ts b/server/src/db/config.ts index 52d0cf78f39e98008276150c696025fbf1e257c5..5df5092aeb67b2daaea8b13a1a0d7e238c30f91b 100644 --- a/server/src/db/config.ts +++ b/server/src/db/config.ts @@ -1,11 +1,11 @@ import { Dialect, Sequelize } from "sequelize"; const envVars = { - dbName : process.env.DB_NAME, - dbUser : process.env.DB_USER, - dbHost : process.env.DB_HOST, - dbDriver : process.env.DB_DRIVER as Dialect, - dbPassword : process.env.DB_PASSWORD, + dbName: process.env.DB_NAME, + dbUser: process.env.DB_USER, + dbHost: process.env.DB_HOST, + dbDriver: process.env.DB_DRIVER as Dialect, + dbPassword: process.env.DB_PASSWORD, } if (!envVars.dbName || !envVars.dbUser || !envVars.dbHost || !envVars.dbDriver || !envVars.dbPassword) { diff --git a/server/src/db/models/Boat.ts b/server/src/db/models/Boat.ts index b67160a03dbd7718e08493999ae18f1c0d2795b8..b093e3a6b9edff7ea17f6108772783fa42efd1ad 100644 --- a/server/src/db/models/Boat.ts +++ b/server/src/db/models/Boat.ts @@ -9,8 +9,8 @@ interface BoatAttributes { seats: number; } -export interface BoatAttributesInput extends Optional<BoatAttributes, "id"> {} -export interface BoatAttributesOutput extends Required<BoatAttributes> {} +export interface BoatAttributesInput extends Optional<BoatAttributes, "id"> { } +export interface BoatAttributesOutput extends Required<BoatAttributes> { } class Boat extends Model<BoatAttributes> implements BoatAttributes { public id!: number; public name!: string; diff --git a/server/src/db/models/CheckIn.ts b/server/src/db/models/CheckIn.ts index 5c3290cfb54e04d3f18f6380a167efc9077054c3..5c1f55294eea18c93147c6c70876b8b4dc0b311f 100644 --- a/server/src/db/models/CheckIn.ts +++ b/server/src/db/models/CheckIn.ts @@ -1,4 +1,5 @@ -import sequelizeConnection from "../seqConnection";import { DataTypes, Model, Optional } from "sequelize"; +import sequelizeConnection from "../seqConnection"; +import { DataTypes, Model, Optional } from "sequelize"; interface CheckInAttributes { id: number; @@ -10,8 +11,8 @@ interface CheckInAttributes { note: string; } export interface CheckInAttributesInput - extends Optional<CheckInAttributes, "id"> {} -export interface CheckInAttributesOutput extends Required<CheckInAttributes> {} + extends Optional<CheckInAttributes, "id"> { } +export interface CheckInAttributesOutput extends Required<CheckInAttributes> { } class CheckIn extends Model<CheckInAttributes> implements CheckInAttributes { public id!: number; public checkin: Date; diff --git a/server/src/db/models/Customer.ts b/server/src/db/models/Customer.ts index 77d843d8329de6faa427ae025af2608ea4ff578f..2e34c72e9e8cbe2044661b63ec2c66ab7da6102e 100644 --- a/server/src/db/models/Customer.ts +++ b/server/src/db/models/Customer.ts @@ -1,4 +1,5 @@ -import sequelizeConnection from "../seqConnection";import { DataTypes, Model, Optional } from "sequelize"; +import sequelizeConnection from "../seqConnection"; +import { DataTypes, Model, Optional } from "sequelize"; interface CustomerAttributes { id: number; diff --git a/server/src/db/models/Worker.ts b/server/src/db/models/Worker.ts index a616985930eeabfd0634052a404584a96fec1b73..eabcde02399e81830272a2c964d4af2665715525 100644 --- a/server/src/db/models/Worker.ts +++ b/server/src/db/models/Worker.ts @@ -1,4 +1,5 @@ -import sequelizeConnection from "../seqConnection";import { DataTypes, Model, Optional } from "sequelize"; +import sequelizeConnection from "../seqConnection"; +import { DataTypes, Model, Optional } from "sequelize"; interface WorkerAttributes { email: string; @@ -7,8 +8,8 @@ interface WorkerAttributes { password: string; role: string; } -export interface WorkerInput extends Optional<WorkerAttributes, "email"> {} -export interface WorkerOutput extends Required<WorkerAttributes> {} +export interface WorkerInput extends Optional<WorkerAttributes, "email"> { } +export interface WorkerOutput extends Required<WorkerAttributes> { } class Worker extends Model<WorkerAttributes> implements WorkerAttributes { public email!: string; public firstName: string; diff --git a/server/src/server.ts b/server/src/server.ts index a23a5bf5e9725c399e78e6202220b86c98bc1d75..81b4e1b2fa2bd2355a502e52ca0ee64c11977907 100644 --- a/server/src/server.ts +++ b/server/src/server.ts @@ -11,7 +11,7 @@ let init = async () => { //app.use(apiRouter); const port = process.env.PORT || 4000; app.listen(port, () => console.log(`Server listening on port: ${port}`)); - app.get("/",(req, res) => res.send("hello in server")) + app.get("/", (req, res) => res.send("hello in server")) }; init().then(() => { });