Update intranet tools and voucher comparison
This commit is contained in:
@@ -0,0 +1,54 @@
|
||||
const HMBIZ_LOCATION_HOST = String(window.location.hostname || '').trim();
|
||||
const HMBIZ_LOCATION_PORT = String(window.location.port || '').trim();
|
||||
const HMBIZ_LOCATION_PROTOCOL = String(window.location.protocol || 'http:');
|
||||
const HMBIZ_LOCATION_PATHNAME = String(window.location.pathname || '/');
|
||||
|
||||
const HMBIZ_IS_LOCAL_LIVE_SERVER = HMBIZ_LOCATION_PORT === '5500';
|
||||
const HMBIZ_IS_HMAC_HOST = /\.hmac\.kr$/i.test(HMBIZ_LOCATION_HOST) || HMBIZ_LOCATION_HOST === 'hmac.kr';
|
||||
const HMBIZ_IS_GITEA_HOST = /^gitea\.hmac\.kr$/i.test(HMBIZ_LOCATION_HOST);
|
||||
const HMBIZ_IS_STATIC_HTML_VIEW = /\.html?$/i.test(HMBIZ_LOCATION_PATHNAME);
|
||||
const HMBIZ_REMOTE_RAW_BASE = 'https://gitea.hmac.kr/tech-planning/hm-biz-process/raw/branch/feature/viewer-ui-cleanup';
|
||||
|
||||
function hmbizNormalizePath(path) {
|
||||
const raw = String(path || '').trim();
|
||||
if (!raw) return '/';
|
||||
return raw.startsWith('/') ? raw : `/${raw}`;
|
||||
}
|
||||
|
||||
function hmbizDirectoryPath(pathname) {
|
||||
const normalized = hmbizNormalizePath(pathname);
|
||||
const idx = normalized.lastIndexOf('/');
|
||||
if (idx <= 0) return '/';
|
||||
return normalized.slice(0, idx);
|
||||
}
|
||||
|
||||
function hmbizJoinPath(baseDir, fileName) {
|
||||
const dir = hmbizDirectoryPath(baseDir);
|
||||
return `${dir}/${String(fileName || '').replace(/^\/+/, '')}`;
|
||||
}
|
||||
|
||||
const HMBIZ_CURRENT_DIR = hmbizDirectoryPath(HMBIZ_LOCATION_PATHNAME);
|
||||
|
||||
const HMBIZ_API_BASE_URL = '/biz-process-viewer';
|
||||
const HMBIZ_PROCESS_MAP_ROUTE = '/biz-process-viewer/process-map';
|
||||
const HMBIZ_MAIN_APP_PATH = '/static/hm-biz-process/flow_260320.html';
|
||||
const HMBIZ_DEFAULT_JSON_CANDIDATES = [];
|
||||
|
||||
window.HMBIZ_CONFIG = Object.freeze({
|
||||
apiBaseUrl: HMBIZ_API_BASE_URL,
|
||||
forceRemoteSync: true,
|
||||
seedVersion: 'flow-data-2026-03-23',
|
||||
defaultJsonCandidates: HMBIZ_DEFAULT_JSON_CANDIDATES,
|
||||
processMapRoute: HMBIZ_PROCESS_MAP_ROUTE,
|
||||
processMapPopupName: 'hm-process-map',
|
||||
processMapBroadcastChannel: 'hm-biz-process-map',
|
||||
processMapStorageSignalKey: 'hm-biz-process-map:refresh',
|
||||
processMapNavigationStorageKey: 'hm-biz-process-map:navigate',
|
||||
processMapFocusStorageKey: 'hm-biz-process-map:focus',
|
||||
processMapPollIntervalMs: 60000,
|
||||
apiFetchTimeoutMs: 4500,
|
||||
mainAppPath: HMBIZ_MAIN_APP_PATH,
|
||||
sitemapAutoLinkWidth: 132,
|
||||
sitemapManualLinkWidth: 132,
|
||||
sharedSegment: ['전표작성', '검토', '출금']
|
||||
});
|
||||
Reference in New Issue
Block a user