feat: 서버 상세 모달 구매일자 필드 추가 및 특정 법인명 제거
This commit is contained in:
@@ -28,6 +28,10 @@ const HW_MODAL_HTML = `
|
|||||||
<label for="hw-자산코드">자산번호/코드</label>
|
<label for="hw-자산코드">자산번호/코드</label>
|
||||||
<input type="text" id="hw-자산코드" required />
|
<input type="text" id="hw-자산코드" required />
|
||||||
</div>
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label for="hw-구매일">구매일자</label>
|
||||||
|
<input type="text" id="hw-구매일" />
|
||||||
|
</div>
|
||||||
<div class="form-group server-only">
|
<div class="form-group server-only">
|
||||||
<label for="hw-용도">용도</label>
|
<label for="hw-용도">용도</label>
|
||||||
<input type="text" id="hw-용도" />
|
<input type="text" id="hw-용도" />
|
||||||
@@ -189,6 +193,7 @@ function fillHwFormData(asset: HardwareAsset) {
|
|||||||
(document.getElementById('hw-RAM') as HTMLInputElement).value = asset.RAM || '';
|
(document.getElementById('hw-RAM') as HTMLInputElement).value = asset.RAM || '';
|
||||||
(document.getElementById('hw-SSD1') as HTMLInputElement).value = asset.SSD1 || '';
|
(document.getElementById('hw-SSD1') as HTMLInputElement).value = asset.SSD1 || '';
|
||||||
(document.getElementById('hw-SSD2') as HTMLInputElement).value = asset.SSD2 || '';
|
(document.getElementById('hw-SSD2') as HTMLInputElement).value = asset.SSD2 || '';
|
||||||
|
(document.getElementById('hw-구매일') as HTMLInputElement).value = asset.구매일 || '';
|
||||||
(document.getElementById('hw-담당자_정') as HTMLInputElement).value = asset.담당자_정 || asset.관리자 || '';
|
(document.getElementById('hw-담당자_정') as HTMLInputElement).value = asset.담당자_정 || asset.관리자 || '';
|
||||||
(document.getElementById('hw-담당자_부') as HTMLInputElement).value = asset.담당자_부 || '';
|
(document.getElementById('hw-담당자_부') as HTMLInputElement).value = asset.담당자_부 || '';
|
||||||
(document.getElementById('hw-품의서명') as HTMLElement).textContent = asset.품의서명 || '';
|
(document.getElementById('hw-품의서명') as HTMLElement).textContent = asset.품의서명 || '';
|
||||||
@@ -289,6 +294,7 @@ export function initHwModal() {
|
|||||||
RAM: (document.getElementById('hw-RAM') as HTMLInputElement).value,
|
RAM: (document.getElementById('hw-RAM') as HTMLInputElement).value,
|
||||||
SSD1: (document.getElementById('hw-SSD1') as HTMLInputElement).value,
|
SSD1: (document.getElementById('hw-SSD1') as HTMLInputElement).value,
|
||||||
SSD2: (document.getElementById('hw-SSD2') as HTMLInputElement).value,
|
SSD2: (document.getElementById('hw-SSD2') as HTMLInputElement).value,
|
||||||
|
구매일: (document.getElementById('hw-구매일') as HTMLInputElement).value,
|
||||||
담당자_정: (document.getElementById('hw-담당자_정') as HTMLInputElement).value,
|
담당자_정: (document.getElementById('hw-담당자_정') as HTMLInputElement).value,
|
||||||
관리자: (document.getElementById('hw-담당자_정') as HTMLInputElement).value,
|
관리자: (document.getElementById('hw-담당자_정') as HTMLInputElement).value,
|
||||||
담당자_부: (document.getElementById('hw-담당자_부') as HTMLInputElement).value,
|
담당자_부: (document.getElementById('hw-담당자_부') as HTMLInputElement).value,
|
||||||
|
|||||||
@@ -609,7 +609,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "GSIM NAS",
|
"용도": "GSIM NAS",
|
||||||
@@ -629,7 +629,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "그래픽스개발팀 데이터 백업 NAS",
|
"용도": "그래픽스개발팀 데이터 백업 NAS",
|
||||||
@@ -649,7 +649,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "공통 GIT 서버",
|
"용도": "공통 GIT 서버",
|
||||||
@@ -669,7 +669,7 @@ export const realServerData = [
|
|||||||
"SSD2": "1TB"
|
"SSD2": "1TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "BUILD 서버",
|
"용도": "BUILD 서버",
|
||||||
@@ -689,7 +689,7 @@ export const realServerData = [
|
|||||||
"SSD2": "10TB"
|
"SSD2": "10TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "HmEG 테스트 서버",
|
"용도": "HmEG 테스트 서버",
|
||||||
@@ -709,7 +709,7 @@ export const realServerData = [
|
|||||||
"SSD2": "1TB"
|
"SSD2": "1TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "산하 ERP 개발서버",
|
"용도": "산하 ERP 개발서버",
|
||||||
@@ -729,7 +729,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "공간정보 신청",
|
"용도": "공간정보 신청",
|
||||||
@@ -749,7 +749,7 @@ export const realServerData = [
|
|||||||
"SSD2": "931GB"
|
"SSD2": "931GB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "AI 관련",
|
"용도": "AI 관련",
|
||||||
@@ -769,7 +769,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "한종 테스트",
|
"용도": "한종 테스트",
|
||||||
@@ -789,7 +789,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "GSIM 언리얼 서버",
|
"용도": "GSIM 언리얼 서버",
|
||||||
@@ -809,7 +809,7 @@ export const realServerData = [
|
|||||||
"SSD2": "8TB"
|
"SSD2": "8TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "AutoCAD 테스트 서버",
|
"용도": "AutoCAD 테스트 서버",
|
||||||
@@ -829,7 +829,7 @@ export const realServerData = [
|
|||||||
"SSD2": "2TB"
|
"SSD2": "2TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "GSIM 테스트 서버",
|
"용도": "GSIM 테스트 서버",
|
||||||
@@ -849,7 +849,7 @@ export const realServerData = [
|
|||||||
"SSD2": "512GB"
|
"SSD2": "512GB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "공간데이터 서버",
|
"용도": "공간데이터 서버",
|
||||||
@@ -869,7 +869,7 @@ export const realServerData = [
|
|||||||
"SSD2": "8 TB"
|
"SSD2": "8 TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "가평 VM 원격 서버",
|
"용도": "가평 VM 원격 서버",
|
||||||
@@ -889,7 +889,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "서버",
|
"storage유형": "서버",
|
||||||
"용도": "GSIM 협업",
|
"용도": "GSIM 협업",
|
||||||
@@ -909,7 +909,7 @@ export const realServerData = [
|
|||||||
"SSD2": "1.88TB"
|
"SSD2": "1.88TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "스토리지",
|
"storage유형": "스토리지",
|
||||||
"용도": "GSIM 협업 스토리지",
|
"용도": "GSIM 협업 스토리지",
|
||||||
@@ -929,7 +929,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "서버",
|
"storage유형": "서버",
|
||||||
"용도": "GSIM META 서버",
|
"용도": "GSIM META 서버",
|
||||||
@@ -949,7 +949,7 @@ export const realServerData = [
|
|||||||
"SSD2": "4TB"
|
"SSD2": "4TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "서버",
|
"storage유형": "서버",
|
||||||
"용도": "GSIM 서버",
|
"용도": "GSIM 서버",
|
||||||
@@ -969,7 +969,7 @@ export const realServerData = [
|
|||||||
"SSD2": "4TB"
|
"SSD2": "4TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "스토리지",
|
"storage유형": "스토리지",
|
||||||
"용도": "GSIM 스토리지",
|
"용도": "GSIM 스토리지",
|
||||||
@@ -989,7 +989,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "서버",
|
"storage유형": "서버",
|
||||||
"용도": "함양-합천 서버",
|
"용도": "함양-합천 서버",
|
||||||
@@ -1009,7 +1009,7 @@ export const realServerData = [
|
|||||||
"SSD2": "10TB"
|
"SSD2": "10TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "서버",
|
"storage유형": "서버",
|
||||||
"용도": "HM MapService 2.0 서버",
|
"용도": "HM MapService 2.0 서버",
|
||||||
@@ -1029,7 +1029,7 @@ export const realServerData = [
|
|||||||
"SSD2": "40 TB"
|
"SSD2": "40 TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "스토리지",
|
"storage유형": "스토리지",
|
||||||
"용도": "HM MapService 2.0 스토리지",
|
"용도": "HM MapService 2.0 스토리지",
|
||||||
@@ -1049,7 +1049,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "서버",
|
"storage유형": "서버",
|
||||||
"용도": "Gitlab Runner",
|
"용도": "Gitlab Runner",
|
||||||
@@ -1069,7 +1069,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "기술개발센터",
|
"법인": "",
|
||||||
"자산코드": "",
|
"자산코드": "",
|
||||||
"storage유형": "서버",
|
"storage유형": "서버",
|
||||||
"용도": "전산모사",
|
"용도": "전산모사",
|
||||||
@@ -1089,7 +1089,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "1",
|
"자산코드": "1",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "NAS 2",
|
"용도": "NAS 2",
|
||||||
@@ -1105,7 +1105,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "2",
|
"자산코드": "2",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "NAS 1",
|
"용도": "NAS 1",
|
||||||
@@ -1121,7 +1121,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "3",
|
"자산코드": "3",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "NAS 4",
|
"용도": "NAS 4",
|
||||||
@@ -1137,7 +1137,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "4",
|
"자산코드": "4",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "NAS 5",
|
"용도": "NAS 5",
|
||||||
@@ -1153,7 +1153,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "5",
|
"자산코드": "5",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "NAS 6",
|
"용도": "NAS 6",
|
||||||
@@ -1169,7 +1169,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "6",
|
"자산코드": "6",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "NAS7",
|
"용도": "NAS7",
|
||||||
@@ -1185,7 +1185,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "7",
|
"자산코드": "7",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "총괄기획실 NAS",
|
"용도": "총괄기획실 NAS",
|
||||||
@@ -1201,7 +1201,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "8",
|
"자산코드": "8",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "한맥 NAS 1",
|
"용도": "한맥 NAS 1",
|
||||||
@@ -1217,7 +1217,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "9",
|
"자산코드": "9",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "한맥 NAS 2",
|
"용도": "한맥 NAS 2",
|
||||||
@@ -1233,7 +1233,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "10",
|
"자산코드": "10",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "한맥 NAS 3",
|
"용도": "한맥 NAS 3",
|
||||||
@@ -1249,7 +1249,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "11",
|
"자산코드": "11",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "NAS 13",
|
"용도": "NAS 13",
|
||||||
@@ -1265,7 +1265,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "12",
|
"자산코드": "12",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "회계",
|
"용도": "회계",
|
||||||
@@ -1281,7 +1281,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "13",
|
"자산코드": "13",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "한맥CAD",
|
"용도": "한맥CAD",
|
||||||
@@ -1297,9 +1297,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "14",
|
"자산코드": "14",
|
||||||
"storage유형": "서버(타워)",
|
"storage유형": "PC",
|
||||||
"용도": "Ai-Cell-Util",
|
"용도": "Ai-Cell-Util",
|
||||||
"상세": "깃티, 매터모스트 등 70여종",
|
"상세": "깃티, 매터모스트 등 70여종",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1313,7 +1313,7 @@ export const realServerData = [
|
|||||||
"SSD2": "8 TB"
|
"SSD2": "8 TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "15",
|
"자산코드": "15",
|
||||||
"storage유형": "PC",
|
"storage유형": "PC",
|
||||||
"용도": "한라CAD",
|
"용도": "한라CAD",
|
||||||
@@ -1329,7 +1329,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "16",
|
"자산코드": "16",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "디자인팀1 NAS",
|
"용도": "디자인팀1 NAS",
|
||||||
@@ -1345,7 +1345,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "17",
|
"자산코드": "17",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "디자인팀2 NAS",
|
"용도": "디자인팀2 NAS",
|
||||||
@@ -1361,9 +1361,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "18",
|
"자산코드": "18",
|
||||||
"storage유형": "서버(미니워크스테이션)",
|
"storage유형": "PC",
|
||||||
"용도": "인사정보 서버",
|
"용도": "인사정보 서버",
|
||||||
"상세": "인사정보 PM",
|
"상세": "인사정보 PM",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1377,9 +1377,9 @@ export const realServerData = [
|
|||||||
"SSD2": "2 TB"
|
"SSD2": "2 TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "19",
|
"자산코드": "19",
|
||||||
"storage유형": "서버(타워)",
|
"storage유형": "PC",
|
||||||
"용도": "BEPs 서버",
|
"용도": "BEPs 서버",
|
||||||
"상세": "BEPs 개발서버, Outline 협업서비스",
|
"상세": "BEPs 개발서버, Outline 협업서비스",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1393,9 +1393,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "20",
|
"자산코드": "20",
|
||||||
"storage유형": "서버(타워)",
|
"storage유형": "PC",
|
||||||
"용도": "Ai-Cell-A100-1",
|
"용도": "Ai-Cell-A100-1",
|
||||||
"상세": "OCR, Local LLM 등 30여종",
|
"상세": "OCR, Local LLM 등 30여종",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1409,9 +1409,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "21",
|
"자산코드": "21",
|
||||||
"storage유형": "서버(타워)",
|
"storage유형": "PC",
|
||||||
"용도": "빌드서버",
|
"용도": "빌드서버",
|
||||||
"상세": "인스톨 쉴드, 지라",
|
"상세": "인스톨 쉴드, 지라",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1425,9 +1425,9 @@ export const realServerData = [
|
|||||||
"SSD2": "4TB"
|
"SSD2": "4TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "22",
|
"자산코드": "22",
|
||||||
"storage유형": "PC\n서버(랙)",
|
"storage유형": "PC",
|
||||||
"용도": "저장소 및 전산모사\n구)스마트건설 서버",
|
"용도": "저장소 및 전산모사\n구)스마트건설 서버",
|
||||||
"상세": "ParaView, CFDCore\n디지털화설문, 검색WIKI 웹서비스",
|
"상세": "ParaView, CFDCore\n디지털화설문, 검색WIKI 웹서비스",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1441,9 +1441,9 @@ export const realServerData = [
|
|||||||
"SSD2": "2TB"
|
"SSD2": "2TB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "23",
|
"자산코드": "23",
|
||||||
"storage유형": "서버(랙)",
|
"storage유형": "서버",
|
||||||
"용도": "IDC 산하ERP서버",
|
"용도": "IDC 산하ERP서버",
|
||||||
"상세": "XR 가상화 메인 서버 → IDC 산하ERP서버",
|
"상세": "XR 가상화 메인 서버 → IDC 산하ERP서버",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1457,9 +1457,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "24",
|
"자산코드": "24",
|
||||||
"storage유형": "스토리지(랙)",
|
"storage유형": "스토리지",
|
||||||
"용도": "WAS Storage",
|
"용도": "WAS Storage",
|
||||||
"상세": "",
|
"상세": "",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1473,9 +1473,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "25",
|
"자산코드": "25",
|
||||||
"storage유형": "서버(랙)",
|
"storage유형": "서버",
|
||||||
"용도": "한맥 백업 서버",
|
"용도": "한맥 백업 서버",
|
||||||
"상세": "가족사 인트라넷 소스 백업 서버",
|
"상세": "가족사 인트라넷 소스 백업 서버",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1489,9 +1489,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "26",
|
"자산코드": "26",
|
||||||
"storage유형": "서버(랙)",
|
"storage유형": "서버",
|
||||||
"용도": "한라 백업 서버",
|
"용도": "한라 백업 서버",
|
||||||
"상세": "한라 웹 소스 및 Miso DB 백업 서버",
|
"상세": "한라 웹 소스 및 Miso DB 백업 서버",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1505,7 +1505,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "27",
|
"자산코드": "27",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "기술개발센터 NAS",
|
"용도": "기술개발센터 NAS",
|
||||||
@@ -1521,7 +1521,7 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "28",
|
"자산코드": "28",
|
||||||
"storage유형": "NAS",
|
"storage유형": "NAS",
|
||||||
"용도": "-",
|
"용도": "-",
|
||||||
@@ -1537,9 +1537,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "29",
|
"자산코드": "29",
|
||||||
"storage유형": "스토리지(랙)",
|
"storage유형": "스토리지",
|
||||||
"용도": "Backup Storage",
|
"용도": "Backup Storage",
|
||||||
"상세": "",
|
"상세": "",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1553,9 +1553,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "30",
|
"자산코드": "30",
|
||||||
"storage유형": "스토리지(랙)",
|
"storage유형": "스토리지",
|
||||||
"용도": "-",
|
"용도": "-",
|
||||||
"상세": "",
|
"상세": "",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1569,9 +1569,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "31",
|
"자산코드": "31",
|
||||||
"storage유형": "서버(랙)",
|
"storage유형": "서버",
|
||||||
"용도": "XR WAS Server",
|
"용도": "XR WAS Server",
|
||||||
"상세": "",
|
"상세": "",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
@@ -1585,9 +1585,9 @@ export const realServerData = [
|
|||||||
"SSD2": ""
|
"SSD2": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"법인": "한맥빌딩",
|
"법인": "",
|
||||||
"자산코드": "32",
|
"자산코드": "32",
|
||||||
"storage유형": "서버(랙)",
|
"storage유형": "서버",
|
||||||
"용도": "WAS Storage",
|
"용도": "WAS Storage",
|
||||||
"상세": "",
|
"상세": "",
|
||||||
"위치": "한맥빌딩(MDF 실)",
|
"위치": "한맥빌딩(MDF 실)",
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ export function renderTable(mainContent: HTMLElement) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function renderHwTable(table: HTMLTableElement, container: HTMLElement, mainContent: HTMLElement) {
|
function renderHwTable(table: HTMLTableElement, container: HTMLElement, mainContent: HTMLElement) {
|
||||||
const list = state.masterData.hw.filter(a => a.type === state.activeSubTab);
|
const fullList = state.masterData.hw.filter(a => a.type === state.activeSubTab);
|
||||||
const tableWrapper = document.createElement('div');
|
const tableWrapper = document.createElement('div');
|
||||||
tableWrapper.className = 'table-container';
|
tableWrapper.className = 'table-container';
|
||||||
|
|
||||||
@@ -37,8 +37,8 @@ function renderHwTable(table: HTMLTableElement, container: HTMLElement, mainCont
|
|||||||
container.appendChild(tableWrapper);
|
container.appendChild(tableWrapper);
|
||||||
mainContent.appendChild(container);
|
mainContent.appendChild(container);
|
||||||
const tbody = document.getElementById('dynamic-tbody')!;
|
const tbody = document.getElementById('dynamic-tbody')!;
|
||||||
if (list.length === 0) { tbody.innerHTML = `<tr><td colspan="17">등록된 자산이 없습니다.</td></tr>`; return; }
|
if (fullList.length === 0) { tbody.innerHTML = `<tr><td colspan="17">등록된 자산이 없습니다.</td></tr>`; return; }
|
||||||
list.forEach((asset, idx) => {
|
fullList.forEach((asset, idx) => {
|
||||||
const tr = document.createElement('tr');
|
const tr = document.createElement('tr');
|
||||||
tr.style.cursor = 'pointer';
|
tr.style.cursor = 'pointer';
|
||||||
tr.innerHTML = `<td>${idx+1}</td><td>${asset.법인}</td><td>${asset.자산코드}</td><td>${asset.사용자||''}</td><td>${asset.위치||''}</td><td>${asset.CPU||''}</td><td>${asset.GPU||''}</td><td>${asset.RAM||''}</td><td>${asset.SSD1||'-'}</td><td>${asset.SSD2||'-'}</td><td>${asset.HDD1||'-'}</td><td>${asset.HDD2||'-'}</td><td>${asset.구매일||''}</td><td>${asset.금액||''}</td><td>${asset.납품업체||''}</td><td style="text-align:center;">${asset.품의서명 ? '<i data-lucide="paperclip" class="text-primary"></i>' : '-'}</td><td><button class="btn btn-outline btn-sm btn-edit">수정</button></td>`;
|
tr.innerHTML = `<td>${idx+1}</td><td>${asset.법인}</td><td>${asset.자산코드}</td><td>${asset.사용자||''}</td><td>${asset.위치||''}</td><td>${asset.CPU||''}</td><td>${asset.GPU||''}</td><td>${asset.RAM||''}</td><td>${asset.SSD1||'-'}</td><td>${asset.SSD2||'-'}</td><td>${asset.HDD1||'-'}</td><td>${asset.HDD2||'-'}</td><td>${asset.구매일||''}</td><td>${asset.금액||''}</td><td>${asset.납품업체||''}</td><td style="text-align:center;">${asset.품의서명 ? '<i data-lucide="paperclip" class="text-primary"></i>' : '-'}</td><td><button class="btn btn-outline btn-sm btn-edit">수정</button></td>`;
|
||||||
@@ -51,42 +51,116 @@ function renderHwTable(table: HTMLTableElement, container: HTMLElement, mainCont
|
|||||||
container.appendChild(tableWrapper);
|
container.appendChild(tableWrapper);
|
||||||
mainContent.appendChild(container);
|
mainContent.appendChild(container);
|
||||||
const tbody = document.getElementById('dynamic-tbody')!;
|
const tbody = document.getElementById('dynamic-tbody')!;
|
||||||
if (list.length === 0) { tbody.innerHTML = `<tr><td colspan="13">등록된 자산이 없습니다.</td></tr>`; return; }
|
if (fullList.length === 0) { tbody.innerHTML = `<tr><td colspan="13">등록된 자산이 없습니다.</td></tr>`; return; }
|
||||||
list.forEach((asset, idx) => {
|
fullList.forEach((asset, idx) => {
|
||||||
const tr = document.createElement('tr');
|
const tr = document.createElement('tr');
|
||||||
tr.style.cursor = 'pointer';
|
tr.style.cursor = 'pointer';
|
||||||
tr.innerHTML = `<td>${idx+1}</td><td>${asset.법인}</td><td>${asset.storage유형||''}</td><td>${asset.자산코드}</td><td>${asset.명칭}</td><td>${asset.위치||''}</td><td>${asset.모델명||''}</td><td>${asset.용량||''}</td><td>${asset.담당자_정||''}</td><td>${asset.IP주소||''}</td><td>${asset.구매일||''}</td><td>${asset.금액||''}</td><td><button class="btn btn-outline btn-sm btn-edit">수정</button></td>`;
|
tr.innerHTML = `<td>${idx+1}</td><td>${asset.법인}</td><td>${asset.storage유형||''}</td><td>${asset.자산코드}</td><td>${asset.명칭}</td><td>${asset.위치||''}</td><td>${asset.모델명||''}</td><td>${asset.용량||''}</td><td>${asset.담당자_정||''}</td><td>${asset.IP주소||''}</td><td>${asset.구매일||''}</td><td>${asset.금액||''}</td><td><button class="btn btn-outline btn-sm btn-edit">수정</button></td>`;
|
||||||
tr.addEventListener('click', (e) => { if (!(e.target as HTMLElement).closest('button')) openStorageModal(asset); });
|
tr.addEventListener('click', (e) => { if (!(e.target as HTMLElement).closest('button')) openStorageModal(asset); });
|
||||||
tbody.appendChild(tr);
|
tbody.appendChild(tr);
|
||||||
});
|
});
|
||||||
} else {
|
} else if (state.activeSubTab === '서버') {
|
||||||
// 서버 또는 전산비품
|
// --- 서버 전용 필터 및 검색 기능 ---
|
||||||
if (state.activeSubTab === '서버') {
|
const filterBar = document.createElement('div');
|
||||||
table.innerHTML = `<thead><tr><th>No</th><th>법인</th><th>자산번호</th><th>유형</th><th>용도</th><th>상세</th><th>설치위치</th><th>담당자</th><th>모델명</th><th>OS</th><th>CPU</th><th>RAM</th><th>Storage</th></tr></thead><tbody id="dynamic-tbody"></tbody>`;
|
filterBar.className = 'search-bar';
|
||||||
} else {
|
|
||||||
table.innerHTML = `<thead><tr><th>No</th><th>법인</th>${state.activeSubTab === '전산비품' ? '<th>유형</th>' : ''}<th>자산코드</th><th>명칭</th><th>위치</th><th>관리자</th><th>구매일</th><th>금액</th><th>관리</th></tr></thead><tbody id="dynamic-tbody"></tbody>`;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
// 법인, 유형, 위치 고유값 추출
|
||||||
|
const corps = Array.from(new Set(fullList.map(a => a.법인))).filter(Boolean).sort();
|
||||||
|
const types = Array.from(new Set(fullList.map(a => a.storage유형))).filter(Boolean).sort();
|
||||||
|
const locations = Array.from(new Set(fullList.map(a => {
|
||||||
|
const loc = String(a.위치 || '');
|
||||||
|
if (loc.startsWith('서관') || loc.startsWith('동관')) return 'IDC';
|
||||||
|
return loc.split(' ')[0]; // 첫 단어 기준 (본사, 지사, 마천사무실 등)
|
||||||
|
}))).filter(Boolean).sort();
|
||||||
|
|
||||||
|
filterBar.innerHTML = `
|
||||||
|
<div class="search-item flex-1">
|
||||||
|
<label>통합 검색 (자산번호/용도/모델명)</label>
|
||||||
|
<input type="text" id="filter-keyword" placeholder="검색어를 입력하세요..." autocomplete="off">
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<label>법인</label>
|
||||||
|
<select id="filter-corp">
|
||||||
|
<option value="">전체 법인</option>
|
||||||
|
${corps.map(c => `<option value="${c}">${c}</option>`).join('')}
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<label>유형</label>
|
||||||
|
<select id="filter-type">
|
||||||
|
<option value="">전체 유형</option>
|
||||||
|
${types.map(t => `<option value="${t}">${t}</option>`).join('')}
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<label>설치위치</label>
|
||||||
|
<select id="filter-location">
|
||||||
|
<option value="">전체 위치</option>
|
||||||
|
${locations.map(l => `<option value="${l}">${l}</option>`).join('')}
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
<button id="btn-reset-filters" class="btn btn-outline btn-reset" title="검색 조건 초기화">
|
||||||
|
<i data-lucide="refresh-ccw" style="width:14px; height:14px;"></i> 필터 초기화
|
||||||
|
</button>
|
||||||
|
`;
|
||||||
|
container.appendChild(filterBar);
|
||||||
|
|
||||||
|
table.innerHTML = `<thead><tr><th>No</th><th>법인</th><th>자산번호</th><th>유형</th><th>용도</th><th>상세</th><th>설치위치</th><th>담당자</th><th>모델명</th><th>OS</th><th>CPU</th><th>RAM</th><th>Storage</th></tr></thead><tbody id="dynamic-tbody"></tbody>`;
|
||||||
tableWrapper.appendChild(table);
|
tableWrapper.appendChild(table);
|
||||||
container.appendChild(tableWrapper);
|
container.appendChild(tableWrapper);
|
||||||
mainContent.appendChild(container);
|
mainContent.appendChild(container);
|
||||||
const tbody = document.getElementById('dynamic-tbody')!;
|
|
||||||
const colCount = state.activeSubTab === '서버' ? 13 : (state.activeSubTab === '전산비품' ? 11 : 10);
|
|
||||||
if (list.length === 0) { tbody.innerHTML = `<tr><td colspan="${colCount}">등록된 자산이 없습니다.</td></tr>`; return; }
|
|
||||||
|
|
||||||
list.forEach((asset, idx) => {
|
const tbody = document.getElementById('dynamic-tbody')!;
|
||||||
|
|
||||||
|
const updateTable = () => {
|
||||||
|
const keyword = (document.getElementById('filter-keyword') as HTMLInputElement).value.toLowerCase().trim();
|
||||||
|
const corp = (document.getElementById('filter-corp') as HTMLSelectElement).value;
|
||||||
|
const type = (document.getElementById('filter-type') as HTMLSelectElement).value;
|
||||||
|
const location = (document.getElementById('filter-location') as HTMLSelectElement).value;
|
||||||
|
|
||||||
|
const filtered = fullList.filter(asset => {
|
||||||
|
const formatAsset = (v: any) => String(v || '').toLowerCase();
|
||||||
|
const matchKeyword = !keyword ||
|
||||||
|
formatAsset(asset.자산코드).includes(keyword) ||
|
||||||
|
formatAsset(asset.용도).includes(keyword) ||
|
||||||
|
formatAsset(asset.상세).includes(keyword) ||
|
||||||
|
formatAsset(asset.모델명).includes(keyword) ||
|
||||||
|
formatAsset(asset.담당자_정).includes(keyword) ||
|
||||||
|
formatAsset(asset.담당자_부).includes(keyword);
|
||||||
|
|
||||||
|
const matchCorp = !corp || asset.법인 === corp;
|
||||||
|
const matchType = !type || asset.storage유형 === type;
|
||||||
|
|
||||||
|
let matchLocation = true;
|
||||||
|
if (location) {
|
||||||
|
const loc = String(asset.위치 || '');
|
||||||
|
if (location === 'IDC') {
|
||||||
|
matchLocation = loc.startsWith('서관') || loc.startsWith('동관');
|
||||||
|
} else {
|
||||||
|
matchLocation = loc.includes(location);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return matchKeyword && matchCorp && matchType && matchLocation;
|
||||||
|
});
|
||||||
|
|
||||||
|
tbody.innerHTML = '';
|
||||||
|
if (filtered.length === 0) {
|
||||||
|
tbody.innerHTML = `<tr><td colspan="13" style="text-align:center; padding: 3rem; color: var(--text-muted);">검색 결과가 없습니다.</td></tr>`;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
filtered.forEach((asset, idx) => {
|
||||||
const tr = document.createElement('tr');
|
const tr = document.createElement('tr');
|
||||||
tr.style.cursor = 'pointer';
|
tr.style.cursor = 'pointer';
|
||||||
const formatInline = (v: any) => String(v || '').replace(/\n/g, ' / ').trim();
|
const formatInline = (v: any) => String(v || '').replace(/\n/g, ' / ').trim();
|
||||||
const getBadge = (text: string, bgColor: string) => `<span style="background:${bgColor}; color:white; font-size:10px; padding:1px 4px; border-radius:3px; font-weight:700; margin-right:4px; display:inline-block; line-height:1.2;">${text}</span>`;
|
const getBadge = (text: string, bgColor: string) => `<span style="background:${bgColor}; color:white; font-size:10px; padding:1px 4px; border-radius:3px; font-weight:700; margin-right:4px; display:inline-block; line-height:1.2;">${text}</span>`;
|
||||||
|
|
||||||
if (state.activeSubTab === '서버') {
|
|
||||||
const mainManager = asset.담당자_정 || '';
|
const mainManager = asset.담당자_정 || '';
|
||||||
const subManager = asset.담당자_부 || '';
|
const subManager = asset.담당자_부 || '';
|
||||||
const managerHtml = [mainManager ? `${getBadge('정', '#1E5149')} ${mainManager}` : '', subManager ? `${getBadge('부', '#9CA3AF')} ${subManager}` : ''].filter(v => v !== '').join(' / ');
|
const managerHtml = [mainManager ? `${getBadge('정', '#1E5149')} ${mainManager}` : '', subManager ? `${getBadge('부', '#9CA3AF')} ${subManager}` : ''].filter(v => v !== '').join(' / ');
|
||||||
const storageInfo = [asset.SSD1, asset.SSD2].filter(v => v && v !== '').join(' / ');
|
const storageInfo = [asset.SSD1, asset.SSD2].filter(v => v && v !== '').join(' / ');
|
||||||
|
|
||||||
// 위치 정보 가공 (서관/동관 -> IDC)
|
|
||||||
let locationHtml = formatInline(asset.위치);
|
let locationHtml = formatInline(asset.위치);
|
||||||
if (locationHtml.startsWith('서관') || locationHtml.startsWith('동관')) {
|
if (locationHtml.startsWith('서관') || locationHtml.startsWith('동관')) {
|
||||||
locationHtml = `IDC(${locationHtml})`;
|
locationHtml = `IDC(${locationHtml})`;
|
||||||
@@ -108,10 +182,42 @@ function renderHwTable(table: HTMLTableElement, container: HTMLElement, mainCont
|
|||||||
<td class="text-nowrap">${formatInline(storageInfo)}</td>
|
<td class="text-nowrap">${formatInline(storageInfo)}</td>
|
||||||
`;
|
`;
|
||||||
tr.addEventListener('click', (e) => { if (!(e.target as HTMLElement).closest('button')) openHwModal(asset); });
|
tr.addEventListener('click', (e) => { if (!(e.target as HTMLElement).closest('button')) openHwModal(asset); });
|
||||||
|
tbody.appendChild(tr);
|
||||||
|
});
|
||||||
|
createIcons({ icons: { RefreshCcw, Paperclip } });
|
||||||
|
};
|
||||||
|
|
||||||
|
const keywordInput = document.getElementById('filter-keyword') as HTMLInputElement;
|
||||||
|
const corpSelect = document.getElementById('filter-corp') as HTMLSelectElement;
|
||||||
|
const typeSelect = document.getElementById('filter-type') as HTMLSelectElement;
|
||||||
|
const locationSelect = document.getElementById('filter-location') as HTMLSelectElement;
|
||||||
|
const resetBtn = document.getElementById('btn-reset-filters') as HTMLButtonElement;
|
||||||
|
|
||||||
|
keywordInput.addEventListener('input', updateTable);
|
||||||
|
corpSelect.addEventListener('change', updateTable);
|
||||||
|
typeSelect.addEventListener('change', updateTable);
|
||||||
|
locationSelect.addEventListener('change', updateTable);
|
||||||
|
resetBtn.addEventListener('click', () => {
|
||||||
|
keywordInput.value = ''; corpSelect.value = ''; typeSelect.value = ''; locationSelect.value = '';
|
||||||
|
updateTable();
|
||||||
|
});
|
||||||
|
|
||||||
|
updateTable();
|
||||||
} else {
|
} else {
|
||||||
|
// 전산비품
|
||||||
|
table.innerHTML = `<thead><tr><th>No</th><th>법인</th>${state.activeSubTab === '전산비품' ? '<th>유형</th>' : ''}<th>자산코드</th><th>명칭</th><th>위치</th><th>관리자</th><th>구매일</th><th>금액</th><th>관리</th></tr></thead><tbody id="dynamic-tbody"></tbody>`;
|
||||||
|
tableWrapper.appendChild(table);
|
||||||
|
container.appendChild(tableWrapper);
|
||||||
|
mainContent.appendChild(container);
|
||||||
|
const tbody = document.getElementById('dynamic-tbody')!;
|
||||||
|
const colCount = state.activeSubTab === '전산비품' ? 11 : 10;
|
||||||
|
if (fullList.length === 0) { tbody.innerHTML = `<tr><td colspan="${colCount}">등록된 자산이 없습니다.</td></tr>`; return; }
|
||||||
|
|
||||||
|
fullList.forEach((asset, idx) => {
|
||||||
|
const tr = document.createElement('tr');
|
||||||
|
tr.style.cursor = 'pointer';
|
||||||
tr.innerHTML = `<td>${idx+1}</td><td>${asset.법인}</td>${state.activeSubTab === '전산비품' ? `<td>${asset.비품유형||'-'}</td>` : ''}<td>${asset.자산코드}</td><td>${asset.명칭}</td><td>${asset.위치}</td><td>${asset.관리자}</td><td>${asset.구매일||''}</td><td>${asset.금액||''}</td><td><button class="btn btn-outline btn-sm btn-edit">수정</button></td>`;
|
tr.innerHTML = `<td>${idx+1}</td><td>${asset.법인}</td>${state.activeSubTab === '전산비품' ? `<td>${asset.비품유형||'-'}</td>` : ''}<td>${asset.자산코드}</td><td>${asset.명칭}</td><td>${asset.위치}</td><td>${asset.관리자}</td><td>${asset.구매일||''}</td><td>${asset.금액||''}</td><td><button class="btn btn-outline btn-sm btn-edit">수정</button></td>`;
|
||||||
tr.addEventListener('click', (e) => { if (!(e.target as HTMLElement).closest('button')) openHwModal(asset); });
|
tr.addEventListener('click', (e) => { if (!(e.target as HTMLElement).closest('button')) openHwModal(asset); });
|
||||||
}
|
|
||||||
tbody.appendChild(tr);
|
tbody.appendChild(tr);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user