From c882df5fa1a181d5bfd133d5980993ac43079b72 Mon Sep 17 00:00:00 2001 From: joonhoekim <26rote@gmail.com> Date: Thu, 13 Nov 2025 20:18:45 +0900 Subject: (김준회) 벤더 견적 응답: 통화 선택기 적용, 통화 가져오는 쿼리 명시적 JOIN으로 변경 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/common/selectors/currency/currency-service.ts | 11 +++++++---- components/common/selectors/currency/index.ts | 3 +-- 2 files changed, 8 insertions(+), 6 deletions(-) (limited to 'components/common') diff --git a/components/common/selectors/currency/currency-service.ts b/components/common/selectors/currency/currency-service.ts index c911d6b1..4e73f077 100644 --- a/components/common/selectors/currency/currency-service.ts +++ b/components/common/selectors/currency/currency-service.ts @@ -25,7 +25,7 @@ const FALLBACK_TEST_DATA: Currency[] = [ * - 엔화(JPY): 0 * - 기타: 2 */ -export function getDecimalPlaces(currencyCode: string): number { +function getDecimalPlaces(currencyCode: string): number { const code = currencyCode.toUpperCase() if (code === 'KRW' || code === 'JPY') { return 0 @@ -49,12 +49,15 @@ export async function getCurrencies(): Promise<{ const result = await oracleKnex.raw(` SELECT CD.CD AS CURRENCY_CODE, NM.GRP_DSC AS CURRENCY_NAME - FROM CMCTB_CD CD, CMCTB_CDNM NM - WHERE CD.CD_CLF = NM.CD_CLF + FROM CMCTB_CD CD + INNER JOIN CMCTB_CDNM NM + ON CD.CD_CLF = NM.CD_CLF AND CD.CD = NM.CD AND CD.CD2 = NM.CD2 AND CD.CD3 = NM.CD3 - AND CD.CD_CLF = 'SPB032' + WHERE CD.CD_CLF = 'SPB032' + AND NM.DEL_YN = 'N' + AND CD.DEL_YN = 'N' ORDER BY CD.USR_DF_CHAR_8 ASC, CD.CD ASC `) diff --git a/components/common/selectors/currency/index.ts b/components/common/selectors/currency/index.ts index 1eb0cfbb..59819221 100644 --- a/components/common/selectors/currency/index.ts +++ b/components/common/selectors/currency/index.ts @@ -10,8 +10,7 @@ export { CurrencySelectorMultiDialog } from './currency-selector-multi-dialog' export type { CurrencySelectorMultiDialogProps } from './currency-selector-multi-dialog' export { - getCurrencies, - getDecimalPlaces + getCurrencies } from './currency-service' export type { Currency -- cgit v1.2.3