From b0863d1586714f52c6f9c318c6ec460d6963f29c Mon Sep 17 00:00:00 2001 From: Akhil Meka Date: Wed, 10 Sep 2025 10:19:33 +0530 Subject: [PATCH] feat: add dueDate field to rts --- src/rts/rts.schema.ts | 3 +++ src/rts/rts.service.ts | 1 + 2 files changed, 4 insertions(+) diff --git a/src/rts/rts.schema.ts b/src/rts/rts.schema.ts index 4bc3f37..b347cf3 100644 --- a/src/rts/rts.schema.ts +++ b/src/rts/rts.schema.ts @@ -43,6 +43,7 @@ const rtsSchema = new mongoose.Schema({ ), status: String, labels: [String], + dueDate: Date, priority: String, createdAt: Date, createdBy: { @@ -69,6 +70,7 @@ const rtsCreateInput = z.object({ permitType: z.string().optional(), labels: z.array(z.string()).optional(), priority: z.string().optional(), + dueDate: z.date().optional(), stage: z .object({ pipeline: z.array( @@ -92,6 +94,7 @@ const rtsUpdateInput = z.object({ permitType: z.string().optional(), labels: z.array(z.string()).optional(), priority: z.string().optional(), + dueDate: z.date().optional(), stage: z .object({ pipeline: z.array( diff --git a/src/rts/rts.service.ts b/src/rts/rts.service.ts index 84cbb23..15c8a09 100644 --- a/src/rts/rts.service.ts +++ b/src/rts/rts.service.ts @@ -160,6 +160,7 @@ export async function listRts( status: 1, labels: 1, priority: 1, + dueDate: 1, taggedUsers: 1, county: { $let: {