diff options
| author | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-07-21 07:54:26 +0000 |
|---|---|---|
| committer | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-07-21 07:54:26 +0000 |
| commit | 14f61e24947fb92dd71ec0a7196a6e815f8e66da (patch) | |
| tree | 317c501d64662d05914330628f867467fba78132 /lib/techsales-rfq/vendor-response/detail/quotation-tabs.tsx | |
| parent | 194bd4bd7e6144d5c09c5e3f5476d254234dce72 (diff) | |
(최겸)기술영업 RFQ 담당자 초대, 요구사항 반영
Diffstat (limited to 'lib/techsales-rfq/vendor-response/detail/quotation-tabs.tsx')
| -rw-r--r-- | lib/techsales-rfq/vendor-response/detail/quotation-tabs.tsx | 166 |
1 files changed, 83 insertions, 83 deletions
diff --git a/lib/techsales-rfq/vendor-response/detail/quotation-tabs.tsx b/lib/techsales-rfq/vendor-response/detail/quotation-tabs.tsx index 2e2f5d70..7af50b24 100644 --- a/lib/techsales-rfq/vendor-response/detail/quotation-tabs.tsx +++ b/lib/techsales-rfq/vendor-response/detail/quotation-tabs.tsx @@ -1,84 +1,84 @@ -"use client" - -import * as React from "react" -import { useRouter, useSearchParams } from "next/navigation" -import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs" -import { ProjectInfoTab } from "./project-info-tab" -import { QuotationResponseTab } from "./quotation-response-tab" -import { CommunicationTab } from "./communication-tab" - -interface QuotationData { - id: number - status: string - totalPrice: string | null - currency: string | null - validUntil: Date | null - remark: string | null - rfq: { - id: number - rfqCode: string | null - materialCode: string | null - dueDate: Date | null - status: string | null - remark: string | null - biddingProject?: { - id: number - pspid: string | null - projNm: string | null - sector: string | null - projMsrm: string | null - ptypeNm: string | null - } | null - createdByUser?: { - id: number - name: string | null - email: string | null - } | null - } | null - vendor: { - id: number - vendorName: string - vendorCode: string | null - } | null -} - -interface TechSalesQuotationTabsProps { - quotation: QuotationData - defaultTab?: string -} - -export function TechSalesQuotationTabs({ quotation, defaultTab = "project" }: TechSalesQuotationTabsProps) { - const router = useRouter() - const searchParams = useSearchParams() - const currentTab = searchParams?.get("tab") || defaultTab - - const handleTabChange = (value: string) => { - const params = new URLSearchParams(searchParams?.toString() || "") - params.set("tab", value) - router.push(`?${params.toString()}`, { scroll: false }) - } - - return ( - <Tabs value={currentTab} onValueChange={handleTabChange} className="h-full flex flex-col"> - <TabsList className="grid w-full grid-cols-3"> - <TabsTrigger value="project">프로젝트 및 RFQ 정보</TabsTrigger> - <TabsTrigger value="quotation">견적 응답</TabsTrigger> - <TabsTrigger value="communication">커뮤니케이션</TabsTrigger> - </TabsList> - - <div className="flex-1 mt-4 overflow-hidden"> - <TabsContent value="project" className="h-full m-0"> - <ProjectInfoTab quotation={quotation} /> - </TabsContent> - - <TabsContent value="quotation" className="h-full m-0"> - <QuotationResponseTab quotation={quotation} /> - </TabsContent> - - <TabsContent value="communication" className="h-full m-0"> - <CommunicationTab quotation={quotation} /> - </TabsContent> - </div> - </Tabs> - ) +"use client"
+
+import * as React from "react"
+import { useRouter, useSearchParams } from "next/navigation"
+import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs"
+import { ProjectInfoTab } from "./project-info-tab"
+import { QuotationResponseTab } from "./quotation-response-tab"
+import { CommunicationTab } from "./communication-tab"
+
+interface QuotationData {
+ id: number
+ status: string
+ totalPrice: string | null
+ currency: string | null
+ validUntil: Date | null
+ remark: string | null
+ rfq: {
+ id: number
+ rfqCode: string | null
+ materialCode: string | null
+ dueDate: Date | null
+ status: string | null
+ remark: string | null
+ biddingProject?: {
+ id: number
+ pspid: string | null
+ projNm: string | null
+ sector: string | null
+ projMsrm: string | null
+ ptypeNm: string | null
+ } | null
+ createdByUser?: {
+ id: number
+ name: string | null
+ email: string | null
+ } | null
+ } | null
+ vendor: {
+ id: number
+ vendorName: string
+ vendorCode: string | null
+ } | null
+}
+
+interface TechSalesQuotationTabsProps {
+ quotation: QuotationData
+ defaultTab?: string
+}
+
+export function TechSalesQuotationTabs({ quotation, defaultTab = "project" }: TechSalesQuotationTabsProps) {
+ const router = useRouter()
+ const searchParams = useSearchParams()
+ const currentTab = searchParams?.get("tab") || defaultTab
+
+ const handleTabChange = (value: string) => {
+ const params = new URLSearchParams(searchParams?.toString() || "")
+ params.set("tab", value)
+ router.push(`?${params.toString()}`, { scroll: false })
+ }
+
+ return (
+ <Tabs value={currentTab} onValueChange={handleTabChange} className="h-full flex flex-col">
+ <TabsList className="grid w-full grid-cols-3">
+ <TabsTrigger value="project">프로젝트 및 RFQ 정보</TabsTrigger>
+ <TabsTrigger value="quotation">견적 응답</TabsTrigger>
+ <TabsTrigger value="communication">커뮤니케이션</TabsTrigger>
+ </TabsList>
+
+ <div className="flex-1 mt-4 overflow-hidden">
+ <TabsContent value="project" className="h-full m-0">
+ <ProjectInfoTab quotation={quotation} />
+ </TabsContent>
+
+ <TabsContent value="quotation" className="h-full m-0">
+ <QuotationResponseTab quotation={quotation} />
+ </TabsContent>
+
+ <TabsContent value="communication" className="h-full m-0">
+ <CommunicationTab quotation={quotation} />
+ </TabsContent>
+ </div>
+ </Tabs>
+ )
}
\ No newline at end of file |
