From 535de26b9cf3242c04543d6891d78352b9593a60 Mon Sep 17 00:00:00 2001
From: dujinkim
Date: Tue, 11 Nov 2025 09:22:58 +0000
Subject: (최겸) 구매 수정사항 개발
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
lib/rfq-last/quotation-compare-view.tsx | 46 +++++++--------------------------
1 file changed, 10 insertions(+), 36 deletions(-)
(limited to 'lib/rfq-last/quotation-compare-view.tsx')
diff --git a/lib/rfq-last/quotation-compare-view.tsx b/lib/rfq-last/quotation-compare-view.tsx
index 3bb27b55..7a4fd751 100644
--- a/lib/rfq-last/quotation-compare-view.tsx
+++ b/lib/rfq-last/quotation-compare-view.tsx
@@ -70,7 +70,6 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
const [selectedResponse, setSelectedResponse] = React.useState(null);
const [selectedVendorName, setSelectedVendorName] = React.useState("");
const [selectedContractType, setSelectedContractType] = React.useState<"PO" | "CONTRACT" | "BIDDING" | "">("");
- const [selectionReason, setSelectionReason] = React.useState("");
const [cancelReason, setCancelReason] = React.useState("");
const [isSubmitting, setIsSubmitting] = React.useState(false);
const router = useRouter()
@@ -323,11 +322,6 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
return;
}
- if (!selectionReason.trim()) {
- toast.error("선정 사유를 입력해주세요.");
- return;
- }
-
setIsSubmitting(true);
try {
const vendor = data.vendors.find(v => v.vendorId === parseInt(selectedVendorId));
@@ -348,8 +342,8 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
vendorCode: vendor.vendorCode,
totalAmount: latestResponse.totalAmount,
currency: latestResponse.currency,
- selectionReason: selectionReason,
- priceRank: latestResponse.rank || 0,
+ selectionReason: "",
+ priceRank: 0,
hasConditionDifferences: latestResponse.conditionDifferences.hasDifferences,
criticalDifferences: latestResponse.conditionDifferences.criticalDifferences,
});
@@ -357,7 +351,6 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
if (result.success) {
toast.success("업체가 성공적으로 선정되었습니다.");
setShowSelectionDialog(false);
- setSelectionReason("");
router.refresh()
} else {
throw new Error(result.error || "업체 선정 중 오류가 발생했습니다.");
@@ -410,24 +403,25 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
)}
-
+ */}
>
) : (
선정 금액: {formatAmount(selectedVendor.totalAmount, selectedVendor.currency)}
선정일: {selectedVendor.selectionDate ? format(new Date(selectedVendor.selectionDate), "yyyy년 MM월 dd일", { locale: ko }) : "-"}
- 선정 사유: {selectedVendor.selectionReason || "-"}
{selectedVendor.contractNo && (
<>
@@ -508,6 +501,7 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
setSelectedContractType("PO");
setShowContractDialog(true);
}}
+ disabled={data.rfqInfo.rfqCode?.startsWith("I")}
className="gap-1 bg-green-600 hover:bg-green-700 text-xs"
>
@@ -929,7 +923,7 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
{/* 납기일 */}
- | 납기일 |
+ PR납기 요청일 |
{data.vendors.map((vendor) => {
const latestResponse = vendor.responses[0];
return (
@@ -1245,36 +1239,17 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
)}
-
- 가격 순위
-
- #{latestResponse?.rank || 0}
-
-
{latestResponse?.conditionDifferences.hasDifferences && (
- 제시 조건과 차이가 있습니다. 선정 사유를 명확히 기재해주세요.
+ 제시 조건과 차이가 있습니다.
)}
-
-
-
);
})()}
@@ -1284,7 +1259,6 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
variant="outline"
onClick={() => {
setShowSelectionDialog(false);
- setSelectionReason("");
}}
disabled={isSubmitting}
>
@@ -1292,7 +1266,7 @@ export function QuotationCompareView({ data }: QuotationCompareViewProps) {
--
cgit v1.2.3