summaryrefslogtreecommitdiff
path: root/lib/bidding/pre-quote/service.ts
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bidding/pre-quote/service.ts')
-rw-r--r--lib/bidding/pre-quote/service.ts5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/bidding/pre-quote/service.ts b/lib/bidding/pre-quote/service.ts
index bf7a4538..c34f6f9e 100644
--- a/lib/bidding/pre-quote/service.ts
+++ b/lib/bidding/pre-quote/service.ts
@@ -663,6 +663,8 @@ export async function getPrItemsForBidding(biddingId: number) {
// SPEC 문서 조회 (PR 아이템에 연결된 문서들)
export async function getSpecDocumentsForPrItem(prItemId: number) {
try {
+ console.log('getSpecDocumentsForPrItem called with prItemId:', prItemId)
+
const specDocs = await db
.select({
id: biddingDocuments.id,
@@ -678,10 +680,11 @@ export async function getSpecDocumentsForPrItem(prItemId: number) {
.where(
and(
eq(biddingDocuments.prItemId, prItemId),
- eq(biddingDocuments.documentType, 'specification')
+ eq(biddingDocuments.documentType, 'spec_document')
)
)
+ console.log('getSpecDocumentsForPrItem result:', specDocs)
return specDocs
} catch (error) {
console.error('Failed to get spec documents for PR item:', error)