From f0cf48fc873ad47bea4f7bdc884a8e82a990c8b8 Mon Sep 17 00:00:00 2001 From: Toast Date: Thu, 23 Jan 2025 10:01:47 +0100 Subject: [PATCH] Shows: complete schema --- src/shows/schema/show.schema.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/shows/schema/show.schema.ts b/src/shows/schema/show.schema.ts index 2597c9d..3f98dc4 100644 --- a/src/shows/schema/show.schema.ts +++ b/src/shows/schema/show.schema.ts @@ -1 +1,9 @@ -export class ShowSchema {} +import { Schema } from 'mongoose'; + +export const ShowSchema = new Schema({ + title: { type: String, required: true }, + year: { type: Number, required: true }, + seasons: { type: Number, required: true }, + description: { type: String, required: true }, + genres: [{ type: String, required: true }], +});