backup: 完成 HR_position_ 表格前綴重命名與欄位對照表整理

變更內容:
- 所有資料表加上 HR_position_ 前綴
- 整理完整欄位顯示名稱與 ID 對照表
- 模組化 JS 檔案 (admin.js, ai.js, csv.js 等)
- 專案結構優化 (docs/, scripts/, tests/ 等)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2025-12-09 12:05:20 +08:00
parent a068ef9704
commit a6af297623
82 changed files with 8685 additions and 4933 deletions

View File

@@ -132,39 +132,39 @@ export function showCopyableError(options) {
const modalHTML = `
<div id="errorModal" class="modal-overlay show">
<div class="modal" style="max-width: 600px;">
<div class="modal-header" style="background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%); color: white;">
<h3>🚨 ${sanitizeHTML(title)}</h3>
<div class="modal" style="max-width: min(90vw, 500px); max-height: 85vh; display: flex; flex-direction: column;">
<div class="modal-header" style="background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%); color: white; flex-shrink: 0;">
<h3 style="font-size: 1rem;">🚨 ${sanitizeHTML(title)}</h3>
<button class="modal-close" onclick="closeErrorModal(this)" style="color: white;">✕</button>
</div>
<div class="modal-body">
<div style="margin-bottom: 16px;">
<strong>錯誤訊息:</strong>
<p style="color: #e74c3c; font-weight: 500;">${sanitizeHTML(message)}</p>
<div class="modal-body" style="overflow-y: auto; flex: 1; padding: 16px;">
<div style="margin-bottom: 12px;">
<strong style="font-size: 0.9rem;">錯誤訊息:</strong>
<p style="color: #e74c3c; font-weight: 500; font-size: 0.85rem; word-break: break-word;">${sanitizeHTML(message)}</p>
</div>
${details ? `
<div style="margin-bottom: 16px;">
<strong>詳細資訊:</strong>
<pre style="background: #f8f9fa; padding: 12px; border-radius: 6px; overflow-x: auto; font-size: 0.85rem; max-height: 200px;">${sanitizeHTML(details)}</pre>
<div style="margin-bottom: 12px;">
<strong style="font-size: 0.9rem;">詳細資訊:</strong>
<pre style="background: #f8f9fa; padding: 10px; border-radius: 6px; overflow-x: auto; font-size: 0.75rem; max-height: 120px; white-space: pre-wrap; word-break: break-all;">${sanitizeHTML(details)}</pre>
</div>
` : ''}
${suggestions && suggestions.length > 0 ? `
<div>
<strong>請檢查以下項目:</strong>
<ul style="margin: 8px 0; padding-left: 20px;">
${suggestions.map(s => `<li style="margin: 4px 0;">${sanitizeHTML(s)}</li>`).join('')}
<strong style="font-size: 0.9rem;">請檢查以下項目:</strong>
<ul style="margin: 6px 0; padding-left: 18px; font-size: 0.85rem;">
${suggestions.map(s => `<li style="margin: 3px 0;">${sanitizeHTML(s)}</li>`).join('')}
</ul>
</div>
` : ''}
</div>
<div class="modal-footer">
<button class="btn btn-secondary" onclick="copyErrorDetails()">
<svg viewBox="0 0 24 24" style="width: 16px; height: 16px;">
<div class="modal-footer" style="flex-shrink: 0; padding: 12px 16px;">
<button class="btn btn-secondary" onclick="copyErrorDetails()" style="font-size: 0.85rem; padding: 8px 12px;">
<svg viewBox="0 0 24 24" style="width: 14px; height: 14px;">
<path fill="currentColor" d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/>
</svg>
複製錯誤詳情
複製
</button>
<button class="btn btn-primary" onclick="closeErrorModal(this)">關閉</button>
<button class="btn btn-primary" onclick="closeErrorModal(this)" style="font-size: 0.85rem; padding: 8px 16px;">關閉</button>
</div>
</div>
</div>