Files
hr-position-system/docs/更新欄位名稱.md
DonaldFang 方士碩 a6af297623 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>
2025-12-09 12:05:20 +08:00

9.9 KiB
Raw Permalink Blame History

系統表單欄位規範書 (Standardized Field Specifications)

1. 命名規範與前綴定義 (Naming Conventions)

為了確保系統一致性HTML 元素 ID 採用 [模組前綴]_[標準欄位名] 的命名方式。

模組名稱 模組前綴 (Prefix) 說明
崗位管理 (Position) pos_ 崗位基礎資料
招聘條件 (Recruit) rec_ 崗位內的招聘頁籤
職務管理 (Job) job_ 全公司通用的職務定義
部門職責 (DeptFunc) df_ 部門功能與職責定義
崗位描述 (JobDesc) jd_ 最終的 JD 產出表單

2. 崗位基礎資料模組 (Position Module)

表單代號: positionForm 資料表: Position

2.1 基礎資料頁籤 (tab-position-basic)

# 欄位顯示名稱 標準化 HTML ID 資料庫欄位名稱 類型 必填 預設 備註
1 事業體 pos_businessUnit businessUnit select - SBU, MBU... (聯動L1)
2 處級單位 pos_division division select - (聯動L2)
3 部級單位 pos_department department select - (聯動L3)
4 課級單位 pos_section section text - -
5 崗位編號 pos_code positionCode text - 唯一識別碼 (PK)
6 生效日期 pos_effectiveDate effectiveDate date Today -
7 崗位名稱 pos_name positionName text - -
8 崗位級別 pos_level positionLevel select - L1-L7
9 崗位類別 pos_category positionCategory select - onchange 觸發
10 崗位類別名稱 pos_categoryName positionCategoryName text - readonly
11 崗位性質 pos_type positionType select - FT, PT, CT, IN
12 崗位性質名稱 pos_typeName positionTypeName text - readonly
13 編制人數 pos_headcount headcount number 0 min=0
14 崗位描述 pos_desc description textarea - rows=6
15 崗位備注 pos_remark remark textarea - rows=6

2.2 招聘要求資料頁籤 (tab-position-recruit)

# 欄位顯示名稱 標準化 HTML ID 資料庫欄位名稱 類型 必填 預設 備註
1 最低學歷 rec_eduLevel educationLevel select - HS, BA, MA, PHD
2 要求性別 rec_gender requiredGender select Any M, F, Any
3 薪酬范圍 rec_salaryRange salaryRange select - A-E, Negotiable
4 工作經驗 rec_expYears experienceYears select - 0, 1, 3, 5, 10+
5 最小年齡 rec_minAge minAge number - min=18
6 最大年齡 rec_maxAge maxAge number - max=65
7 工作性質 rec_jobType jobType select - 招聘用性質分類
8 招聘職位 rec_position recruitPosition select - ENG, MGR...
9 職位名稱(對外) rec_jobTitle jobTitle text - 對外招聘用Title
10 上級崗位編號 rec_superiorCode superiorPositionCode text - -
11 職位描述(JD) rec_jobDesc recruitJobDesc textarea - 招聘廣告用
12 崗位要求(Req) rec_positionReq recruitRequirements textarea - 招聘廣告用
13 證照要求 rec_certReq certRequirements select - -
14 專業要求 rec_majorReq majorRequirements text - Modal選擇
15 技能要求 rec_skillReq skillRequirements text - Tags input
16 語言要求 rec_langReq langRequirements text - -
17 其他要求 rec_otherReq otherRequirements text - -
18 招聘備注 rec_remark recruitRemark textarea - -

3. 職務基礎資料模組 (Job Module)

表單代號: jobForm 資料表: Job

# 欄位顯示名稱 標準化 HTML ID 資料庫欄位名稱 類型 必填 預設 備註
1 職務類別編號 job_category jobCategoryCode select - onchange 觸發
2 職務類別名稱 job_categoryName jobCategoryName text - readonly
3 職務編號 job_code jobCode text - 唯一識別碼
4 職務名稱 job_name jobName text - -
5 職務英文 job_nameEn jobNameEn text - -
6 生效日期 job_effectiveDate effectiveDate date - -
7 職務層級 job_level jobLevel text 保密 敏感欄位
8 編制人數 job_headcount headcount number - -
9 排列順序 job_sortOrder sortOrder number - -
10 全勤獎金 job_hasAttBonus hasAttendanceBonus checkbox false Toggle Switch
11 住房補貼 job_hasHouseAllow hasHousingAllowance checkbox false Toggle Switch
12 職務備注 job_remark remark textarea - -

4. 部門職責模組 (DeptFunction Module)

表單代號: deptFunctionForm 資料表: DeptFunction

# 欄位顯示名稱 標準化 HTML ID 資料庫欄位名稱 類型 必填 預設 備註
1 職責編號 df_code dfCode text - DF-001
2 職責名稱 df_name dfName text - -
3 事業體 df_businessUnit businessUnit select - (已合併重複欄位)
4 處級單位 df_division division select - -
5 部級單位 df_department department select - -
6 課級單位 df_section section text - -
7 對應崗位 df_posTitle positionTitle select - 關聯 Position
8 崗位級別 df_posLevel positionLevel select - 自動帶出或指定
9 部門主管職稱 df_managerTitle managerTitle text - -
10 生效日期 df_effectiveDate effectiveDate date - -
11 人數上限 df_headcountLimit headcountLimit number - -
12 狀態 df_status status select active -
13 部門使命 df_mission mission textarea - -
14 部門願景 df_vision vision textarea - -
15 核心職責 df_coreFunc coreFunctions textarea - -
16 KPIs df_kpis kpis textarea - -
17 協作部門 df_collab collaboration textarea - -
18 備注 df_remark remark textarea - -

5. 崗位描述模組 (JobDescription Module)

表單代號: jobDescForm 資料表: JobDescription (部分欄位為 View)

5.1 基本信息 (Header)

# 欄位顯示名稱 標準化 HTML ID 資料庫欄位名稱 類型 必填 備註
1 工號 jd_empNo empNo text Search Modal
2 姓名 jd_empName empName text Readonly
3 崗位代碼 jd_posCode positionCode text 關聯鍵
4 版本日期 jd_versionDate versionDate date -

5.2 崗位資訊 (Position Info - Readonly/Derived)

# 欄位顯示名稱 標準化 HTML ID 資料庫欄位名稱 類型 必填 備註
1 崗位名稱 jd_posName positionName text -
2 事業體 jd_businessUnit businessUnit select -
3 處級單位 jd_division division select -
4 部級單位 jd_department department select -
5 課級單位 jd_section section text -
6 崗位級別 jd_posLevel positionLevel select -
7 生效日期 jd_posEffDate positionEffectiveDate date -
8 直接主管 jd_supervisor directSupervisor text -
9 職等&職務 jd_gradeJob positionGradeJob text Modal
10 匯報對象 jd_reportTo reportTo text Modal
11 直接下屬 jd_directReports directReports text -
12 任職地點 jd_location workLocation select -
13 員工屬性 jd_empAttr empAttribute select -

5.3 職責與要求 (Details)

# 欄位顯示名稱 標準化 HTML ID 資料庫欄位名稱 類型 必填 備註
1 部門職責代碼 jd_dfCode dfCode text 關聯 DeptFunction
2 崗位設置目的 jd_purpose positionPurpose text -
3 主要職責 jd_mainResp mainResponsibilities textarea 編號清單
4 教育程度 jd_eduLevel educationLevel text -
5 基本技能 jd_basicSkills basicSkills textarea -
6 專業知識 jd_proKnowledge professionalKnowledge textarea -
7 工作經驗 jd_expReq experienceRequirements textarea -
8 其他要求 jd_otherReq otherRequirements textarea -

6. 共用設定與資料字典

6.1 模態框 (Modals)

  • MajorModal (專業要求)
  • EmpSearchModal (員工搜索)
  • OrgSearchModal (組織搜索)
  • GradeJobModal (職等職務)
  • ReportToModal (匯報對象)

6.2 特殊控件

  • Toggle Switch: 用於所有布林值 (Boolean) 欄位。
  • Numbered Textarea: 用於 mainResponsibilities,自動產生序號。
  • Cascading Selects: 組織層級 (BU -> Div -> Dept -> Section) 統一使用標準聯動邏輯。