feat: update UI title, restore guide functionality, and simplify server list view
This commit is contained in:
@@ -50,16 +50,16 @@ export const state: AppState = {
|
||||
export async function loadMasterDataFromDB() {
|
||||
try {
|
||||
const endpoints = [
|
||||
{ key: 'pc', url: 'http://localhost:3000/api/pc' },
|
||||
{ key: 'server', url: 'http://localhost:3000/api/server' },
|
||||
{ key: 'storage', url: 'http://localhost:3000/api/storage' },
|
||||
{ key: 'equip', url: 'http://localhost:3000/api/equip' },
|
||||
{ key: 'mobile', url: 'http://localhost:3000/api/mobile' },
|
||||
{ key: 'subSw', url: 'http://localhost:3000/api/sw/sub' },
|
||||
{ key: 'permSw', url: 'http://localhost:3000/api/sw/perm' },
|
||||
{ key: 'cloud', url: 'http://localhost:3000/api/cloud' },
|
||||
{ key: 'swUsers', url: 'http://localhost:3000/api/sw-users' },
|
||||
{ key: 'logs', url: 'http://localhost:3000/api/logs' }
|
||||
{ key: 'pc', url: 'http://172.16.40.100:3000/api/pc' },
|
||||
{ key: 'server', url: 'http://172.16.40.100:3000/api/server' },
|
||||
{ key: 'storage', url: 'http://172.16.40.100:3000/api/storage' },
|
||||
{ key: 'equip', url: 'http://172.16.40.100:3000/api/equip' },
|
||||
{ key: 'mobile', url: 'http://172.16.40.100:3000/api/mobile' },
|
||||
{ key: 'subSw', url: 'http://172.16.40.100:3000/api/sw/sub' },
|
||||
{ key: 'permSw', url: 'http://172.16.40.100:3000/api/sw/perm' },
|
||||
{ key: 'cloud', url: 'http://172.16.40.100:3000/api/cloud' },
|
||||
{ key: 'swUsers', url: 'http://172.16.40.100:3000/api/sw-users' },
|
||||
{ key: 'logs', url: 'http://172.16.40.100:3000/api/logs' }
|
||||
];
|
||||
|
||||
const results = await Promise.all(endpoints.map(e => fetch(e.url)));
|
||||
@@ -194,7 +194,7 @@ export function deleteHardwareAsset(assetId: string) {
|
||||
*/
|
||||
export async function saveSoftwareAsset(asset: SoftwareAsset) {
|
||||
try {
|
||||
const response = await fetch('http://localhost:3000/api/software/save', {
|
||||
const response = await fetch('http://172.16.40.100:3000/api/software/save', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify(asset)
|
||||
@@ -223,7 +223,7 @@ export async function saveSoftwareAsset(asset: SoftwareAsset) {
|
||||
*/
|
||||
export async function deleteSoftwareAsset(type: string, id: string) {
|
||||
try {
|
||||
const response = await fetch(`http://localhost:3000/api/asset/${type}/${id}`, {
|
||||
const response = await fetch(`http://172.16.40.100:3000/api/asset/${type}/${id}`, {
|
||||
method: 'DELETE'
|
||||
});
|
||||
|
||||
|
||||
@@ -15,8 +15,8 @@ export function formatPrice(value: string | number): string {
|
||||
/**
|
||||
* HTML 배지 생성 (정/부 담당자, 원격도구 등)
|
||||
*/
|
||||
export function createBadge(text: string, bgColor: string): string {
|
||||
return `<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>`;
|
||||
export function createBadge(text: string, type: 'primary' | 'muted' | 'success' | 'danger' = 'primary'): string {
|
||||
return `<span class="badge badge-${type}">${text}</span>`;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user