summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
Diffstat (limited to 'app')
-rw-r--r--app/api/(S-ERP)/(ECC)/IF_ECC_EVCP_BIDDING_PROJECT/route.ts11
1 files changed, 7 insertions, 4 deletions
diff --git a/app/api/(S-ERP)/(ECC)/IF_ECC_EVCP_BIDDING_PROJECT/route.ts b/app/api/(S-ERP)/(ECC)/IF_ECC_EVCP_BIDDING_PROJECT/route.ts
index 0c36974f..ba2849a3 100644
--- a/app/api/(S-ERP)/(ECC)/IF_ECC_EVCP_BIDDING_PROJECT/route.ts
+++ b/app/api/(S-ERP)/(ECC)/IF_ECC_EVCP_BIDDING_PROJECT/route.ts
@@ -30,6 +30,7 @@ interface BiddingProject {
txt04?: string;
txt30?: string;
estmPm?: string;
+ shipMHull?: string; // SHIP(조선), HULL(해양) 구분으로, 조선일 경우 NULL, 해양일 경우 'X'
}
interface ProjectSeries {
@@ -279,12 +280,14 @@ async function saveToDatabase(data: RequestData) {
where: eq(biddingProjects.pspid, project.pspid)
});
- // sector 값에 따라 pjtType 결정
+ // shipMHull 값을 기준으로 pjtType 결정
let pjtType: 'SHIP' | 'HULL' | null = null;
- if (project.sector === 'S') {
- pjtType = 'SHIP';
- } else if (project.sector === 'M') {
+ if (project.shipMHull) {
+ // shipMHull 값이 존재하면 해양(HULL)
pjtType = 'HULL';
+ } else {
+ // shipMHull 값이 없으면 조선(SHIP)
+ pjtType = 'SHIP';
}
const projectValues: NewBiddingProject = {