- typeList 从 5 项简化到 4 项:生日 / 结婚纪念日 / 订婚纪念日 / 其他纪念日 - TYPE_NAMES / TYPE_ICONS 中 lunar_birthday 保留兼容映射(也映射到「生日」+ 🎂), 让线上历史数据自然回显,无需数据库迁移(方案 A) - getTypeIndex('lunar_birthday') = 0,老数据编辑时正确回显「生日」 - index.js 列表筛选和 wxml 图标判断本来已含 lunar_birthday 兼容,无需改 老数据自然淘汰:用户重新保存时新数据写 type='birthday',老数据 type 保留 直到下次编辑保存才升级。 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
+4
-3
@@ -11,8 +11,9 @@ const ANNIVERSARY_TYPES = {
|
||||
}
|
||||
|
||||
const TYPE_NAMES = {
|
||||
birthday: '公历生日',
|
||||
lunar_birthday: '农历生日',
|
||||
birthday: '生日',
|
||||
// lunar_birthday 已合并到 birthday(公历/农历由 isLunar 决定),保留映射用于兼容老数据回显
|
||||
lunar_birthday: '生日',
|
||||
wedding: '结婚纪念日',
|
||||
engagement: '订婚纪念日',
|
||||
other: '其他纪念日'
|
||||
@@ -20,7 +21,7 @@ const TYPE_NAMES = {
|
||||
|
||||
const TYPE_ICONS = {
|
||||
birthday: '🎂',
|
||||
lunar_birthday: '🌙',
|
||||
lunar_birthday: '🎂',
|
||||
wedding: '💍',
|
||||
engagement: '💕',
|
||||
other: '📅'
|
||||
|
||||
Reference in New Issue
Block a user