1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
|
import { TechVendorWithAttachments } from "@/db/schema/techVendors";
/**
* 테이블/엑셀에 보여줄 컬럼 한 칸을 어떻게 렌더링할지 결정하는 설정
*/
export interface VendorColumnConfig {
/**
* 기술영업 벤더(TechVendorWithAttachments) 객체의 어느 필드를 표시할지
*/
id: keyof TechVendorWithAttachments;
/** 화면·엑셀에서 보여줄 컬럼명 */
label: string;
/** (선택) 그룹핑/카테고리 */
group?: string;
/** (선택) Excel에서의 헤더 */
excelHeader?: string;
/** (선택) 데이터 타입(예: date, string, number 등), 포맷 지정용 */
type?: string;
}
/**
* 기술영업 벤더 정보 테이블에서
* 어떤 컬럼들을 어떤 순서로 표시할 것인지 정의.
*/
export const techVendorColumnsConfig: VendorColumnConfig[] = [
{
id: "vendorCode",
label: "업체 코드",
excelHeader: "업체 코드",
},
{
id: "vendorName",
label: "업체명",
excelHeader: "업체명",
},
{
id: "techVendorType",
label: "벤더 타입",
excelHeader: "벤더 타입",
type: "string",
},
{
id: "workTypes",
label: "공종",
excelHeader: "공종",
type: "string",
},
{
id: "taxId",
label: "세금 ID",
excelHeader: "세금 ID",
type: "string",
},
{
id: "status",
label: "상태",
excelHeader: "상태",
type: "string",
},
{
id: "address",
label: "주소",
excelHeader: "주소",
},
{
id: "country",
label: "국가",
excelHeader: "국가",
},
{
id: "countryEng",
label: "국가(영문)",
excelHeader: "국가(영문)",
},
{
id: "countryFab",
label: "제조국가",
excelHeader: "제조국가",
},
{
id: "phone",
label: "전화번호",
excelHeader: "전화번호",
},
{
id: "email",
label: "이메일",
excelHeader: "이메일",
},
{
id: "website",
label: "웹사이트",
excelHeader: "웹사이트",
// group: "Metadata",
},
// 에이전트 정보
{
id: "agentName",
label: "에이전트명",
excelHeader: "에이전트명",
group: "에이전트 정보",
},
{
id: "agentEmail",
label: "에이전트 이메일",
excelHeader: "에이전트 이메일",
group: "에이전트 정보",
},
{
id: "agentPhone",
label: "에이전트 번호",
excelHeader: "에이전트 번호",
group: "에이전트 정보",
},
// 대표자 정보
{
id: "representativeName",
label: "대표자명",
excelHeader: "대표자명",
group: "대표자 정보",
},
{
id: "representativeEmail",
label: "대표자 이메일",
excelHeader: "대표자 이메일",
group: "대표자 정보",
},
{
id: "representativePhone",
label: "대표자 전화번호",
excelHeader: "대표자 전화번호",
group: "대표자 정보",
},
{
id: "representativeBirth",
label: "대표자 생년월일",
excelHeader: "대표자 생년월일",
group: "대표자 정보",
},
];
|