# amlhc — 澳门六合彩后台遗漏号码分析 ## What This Is 基于 FastAdmin 1.6 + ThinkPHP 5.x 的澳门六合彩数据管理后台。已有功能包括:开奖历史查看、号码波色映射(fa_num 表)、数据抓取。本次新增**遗漏号码分析**功能——在后台 history 页面添加按钮,弹窗展示最近 X 期未出现的冷门号码。 ## Core Value 快速识别冷门号码,辅助投注决策——遗漏期数越长的号码,出现概率的感知越强。 ## Requirements ### Validated - ✓ 开奖历史列表展示(含波色球渲染) — 已有 - ✓ 号码波色映射(fa_num 表,从数据库读取) — 已有 - ✓ 历史数据录入(admin 添加) — 已有 ### Active - [ ] **OMIT-01**: history 页面新增"遗漏号码"按钮,点击弹窗展示 - [ ] **OMIT-02**: 弹窗内可输入期数 X(默认 10),点击查询后展示最近 X 期未出现的号码 - [ ] **OMIT-03**: 展示内容为:遗漏号码 + 遗漏期数(多少期没出现)+ 波色球 - [ ] **OMIT-04**: 遗漏号码按遗漏期数从大到小排序 - [ ] **OMIT-05**: 后端接口支持查询最近 X 期开奖数据并计算遗漏号码(1-49 范围) ### Out of Scope - 遗漏统计历史趋势图 — 首期不涉及,后续可扩展 - 遗漏号码的预测推荐 — 仅做数据展示,不做分析推荐 - 前台用户可见 — 仅后台 admin 功能 ## Context - 数据库:MySQL,表前缀 `fa_`,主要表 `fa_history`(开奖历史)、`fa_num`(号码波色) - 前端:RequireJS + Bootstrap Table + Layer 弹窗 - 后端:FastAdmin Backend 基类,ThinkPHP 5.x - 号码范围:1-49(标准六合彩) - 波色球颜色已在 `fa_num` 表中定义(红/蓝/绿) - history.js 已有 `getColorByNum()` 方法从后端加载颜色映射 ## Constraints - **[Tech stack]**: 必须沿用 FastAdmin + ThinkPHP 5.x 架构,不引入新框架 - **[UI style]**: 使用 FastAdmin 现有的 Layer 弹窗和 Bootstrap 组件风格 - **[Code convention]**: 保持与原代码风格统一,函数级中文注释 ## Key Decisions | Decision | Rationale | Outcome | |----------|-----------|---------| | 遗漏号码在 history 页面以按钮+弹窗形式展示 | 不新增独立页面/菜单,最小化改动 | ✓ Good | | 遗漏计算在后端完成,前端只负责展示 | 避免前端大量计算,后端可复用模型 | ✓ Good | | 使用 `$.ajax` 请求遗漏接口,Layer 弹窗展示 | FastAdmin 标准交互模式 | ✓ Good | --- *Last updated: 2026-04-21 after initialization* ## Evolution This document evolves at phase transitions and milestone boundaries. **After each phase transition** (via `/gsd-transition`): 1. Requirements invalidated? → Move to Out of Scope with reason 2. Requirements validated? → Move to Validated with phase reference 3. New requirements emerged? → Add to Active 4. Decisions to log? → Add to Key Decisions 5. "What This Is" still accurate? → Update if drifted **After each milestone** (via `/gsd-complete-milestone`): 1. Full review of all sections 2. Core Value check — still the right priority? 3. Audit Out of Scope — reasons still valid? 4. Update Context with current state