summaryrefslogtreecommitdiff
path: root/lib/basic-contract/agreement-comments
diff options
context:
space:
mode:
authordujinkim <dujin.kim@dtsolution.co.kr>2025-11-25 11:48:21 +0000
committerdujinkim <dujin.kim@dtsolution.co.kr>2025-11-25 11:48:21 +0000
commit6160e8bd61360ada9e8e0574671c38292eaba9e7 (patch)
tree57857b8cd7f1b858deb68622d69feba11fda20a8 /lib/basic-contract/agreement-comments
parent6fcb8eda80c5ccac7eb985d3efb2aaafa0711988 (diff)
(임수민) 준법/gtc 코멘트 수정
Diffstat (limited to 'lib/basic-contract/agreement-comments')
-rw-r--r--lib/basic-contract/agreement-comments/actions.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/basic-contract/agreement-comments/actions.ts b/lib/basic-contract/agreement-comments/actions.ts
index 2f60c3d8..32e9ce4c 100644
--- a/lib/basic-contract/agreement-comments/actions.ts
+++ b/lib/basic-contract/agreement-comments/actions.ts
@@ -2,7 +2,7 @@
import { revalidateTag } from "next/cache";
import db from "@/db/db";
-import { eq, and, desc, inArray, sql } from "drizzle-orm";
+import { eq, and, desc, inArray, sql, isNotNull, ne } from "drizzle-orm";
import { agreementComments, basicContract, vendors, users } from "@/db/schema";
import { saveFile, deleteFile } from "@/lib/file-stroage";
import { sendEmail } from "@/lib/mail/sendEmail";
@@ -62,7 +62,9 @@ export async function getAgreementComments(
.where(
and(
eq(agreementComments.basicContractId, basicContractId),
- eq(agreementComments.isDeleted, false)
+ eq(agreementComments.isDeleted, false),
+ isNotNull(agreementComments.comment),
+ ne(agreementComments.comment, '')
)
)
.orderBy(desc(agreementComments.createdAt));