eff4332aae
fix: 保存配方后0元bug + 标签字母排序
...
PR Preview / teardown-preview (pull_request) Has been skipped
PR Preview / test (pull_request) Successful in 5s
Test / unit-test (push) Successful in 4s
Test / build-check (push) Successful in 4s
PR Preview / deploy-preview (pull_request) Successful in 14s
Test / e2e-test (push) Successful in 50s
- 保存公共配方后reload从服务器重新获取(修复oil_name覆盖oil导致显示0元)
- 配方卡片标签按字母排序
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-10 21:34:16 +00:00
0dfef3ab16
fix: 已审核标签对viewer完全不可见
...
PR Preview / teardown-preview (pull_request) Has been skipped
Test / unit-test (push) Successful in 4s
Test / build-check (push) Successful in 3s
PR Preview / test (pull_request) Successful in 4s
PR Preview / deploy-preview (pull_request) Successful in 16s
Test / e2e-test (push) Has been cancelled
- EDITOR_ONLY_TAGS常量从recipes store导出,统一引用
- RecipeCard: viewer不显示已审核标签
- RecipeSearch: viewer搜索不匹配已审核标签
- RecipeManager: 标签筛选栏、配方行标签对viewer隐藏
- 所有标签按字母排序(已有)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-10 21:13:20 +00:00
6d2620eb6a
fix: 新增配方去重+编辑者权限+共享去重统一
...
PR Preview / teardown-preview (pull_request) Has been skipped
Test / unit-test (push) Successful in 5s
Test / build-check (push) Successful in 4s
PR Preview / test (pull_request) Successful in 4s
PR Preview / deploy-preview (pull_request) Successful in 15s
Test / e2e-test (push) Failing after 52s
新增去重:
- 新增配方保存前检查公共库和个人配方同名
- 完全相同提示已有,内容不同显示差异可改名
编辑者权限:
- editor可编辑所有公共配方(前端+后端)
- editor不能编辑精油价目(已有)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-10 20:12:10 +00:00
a8e91dc384
feat: 权限修复、搜索改进、滑动切换、通知badge
...
Deploy Production / test (push) Successful in 4s
Test / unit-test (push) Successful in 4s
Test / build-check (push) Successful in 4s
PR Preview / deploy-preview (pull_request) Has been skipped
PR Preview / test (pull_request) Has been skipped
PR Preview / teardown-preview (pull_request) Successful in 13s
Deploy Production / deploy (push) Successful in 7s
Test / e2e-test (push) Successful in 52s
权限:
- viewer 不能编辑公共配方(前端+后端双重限制)
- viewer 管理配方页只显示"我的配方"
- 取消 token 链接登录,改为自注册+管理员分配角色
- 用户管理页去掉创建用户和复制链接,禁止设管理员
- 修复改权限 API 路径错误
搜索:
- 模糊匹配+同义词扩展(37组),精确/相似分层
- 精确匹配不搜精油成分(避免"西班牙牛至"污染)
- 所有搜索结果底部加"通知编辑添加"按钮
UI:
- 顶部 tab 栏按用户角色显示,切换时居中滚动
- 左右滑动按 visibleTabs 顺序切换 tab
- 用户名旁红色通知数 badge
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-09 21:31:17 +00:00
e04d572f27
fix: 下架后卡片变灰+按钮变灰,isActive存为boolean
...
PR Preview / teardown-preview (pull_request) Has been skipped
Test / unit-test (push) Successful in 5s
Test / build-check (push) Successful in 4s
PR Preview / test (pull_request) Successful in 4s
PR Preview / deploy-preview (pull_request) Successful in 12s
Test / e2e-test (push) Failing after 1m42s
根因: oils store 存 isActive = oil.is_active ?? true
oil.is_active=0 时 0??true=0,但检查用 ===false,0!==false
修复: isActive = oil.is_active !== 0 (true/false boolean)
UI:
- 下架后弹窗不关闭,按钮变灰显示"✓ 已下架 · 点击重新上架"
- 卡片立即变灰(oil-chip--inactive class生效)
- 重新上架后恢复正常
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-09 16:50:26 +00:00
0c19153156
fix: 增强存为我的调试日志和错误提示,修复空名称静默失败问题
...
PR Preview / teardown-preview (pull_request) Has been skipped
Test / unit-test (push) Successful in 5s
Test / build-check (push) Successful in 4s
PR Preview / test (pull_request) Successful in 5s
PR Preview / deploy-preview (pull_request) Successful in 13s
Test / e2e-test (push) Failing after 1m23s
- 区分「取消」(null) 和「清空名称后确认」(空字符串) 两种情况
前者静默返回,后者提示「请输入配方名称」
- 添加 console.log/error 方便在浏览器控制台定位问题
- 成功 toast 改为「已保存!可在「配方查询 → 我的配方」查看」提示去向
- 错误 toast 延长至 3s,并显示 status code
- saveRecipe:loadRecipes 失败不再抛出,保证保存成功后不误报失败
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com >
2026-04-08 20:27:03 +00:00
31b46d59b6
feat: 配方卡片容量切换、预览/保存流程优化、精油搜索自动补全、精油英文名编辑
...
PR Preview / teardown-preview (pull_request) Has been skipped
Test / unit-test (push) Successful in 4s
Test / build-check (push) Successful in 4s
PR Preview / test (pull_request) Successful in 5s
PR Preview / deploy-preview (pull_request) Successful in 13s
Test / e2e-test (push) Failing after 1m20s
1. 配方卡片视图加回容量切换按钮(单次/2.5ml/5ml…),
非单次容量的滴数通过 Math.round 取整显示
2. 编辑器「预览」按钮改为展示当前未保存数据;
预览后点关闭询问是否保存;
直接点「保存」后留在配方卡片视图(不再关闭弹层)
3. 添加精油改为搜索输入框 + 下拉自动补全,
支持中文名和英文名筛选
4. 精油价目:添加/编辑表单加入英文名字段;
编辑/删除按钮改为悬停(桌面)或点击(移动端)才显示;
后端及数据库同步支持 oils.en_name
2026-04-08 20:03:14 +00:00
96504ed1d7
Resume pending action after login (favorite, diary, QR upload)
...
PR Preview / teardown-preview (pull_request) Has been skipped
Test / unit-test (push) Successful in 5s
Test / build-check (push) Successful in 4s
PR Preview / test (pull_request) Successful in 4s
PR Preview / deploy-preview (pull_request) Successful in 13s
Test / e2e-test (push) Failing after 1m4s
Add pendingAction callback to UI store. When user clicks favorite,
save-to-diary, or upload QR while not logged in, the action is stored
and automatically executed after successful login/register instead of
reloading the page.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-07 22:39:59 +00:00
dee4b1649a
fix: 卡片预览加入容量切换,非单次滴数四舍五入
...
PR Preview / teardown-preview (pull_request) Has been skipped
Test / unit-test (push) Successful in 5s
Test / build-check (push) Successful in 3s
PR Preview / test (pull_request) Successful in 4s
PR Preview / deploy-preview (pull_request) Successful in 12s
Test / e2e-test (push) Has been cancelled
- VOLUME_DROPS 新增「单次」(null,不缩放)
- 新增 scaleIngredients() 按比例缩放成分
- 卡片预览区加入容量切换按钮,切换后实时更新滴数与成本
- priceInfo 与 coconutDrops 均基于缩放后数据
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com >
2026-04-07 22:27:21 +00:00
6804835e85
Persist recipe English name translation to database
...
Test / unit-test (push) Successful in 5s
Test / build-check (push) Successful in 4s
Test / e2e-test (push) Failing after 1m7s
PR Preview / test (pull_request) Has been skipped
PR Preview / teardown-preview (pull_request) Successful in 14s
PR Preview / deploy-preview (pull_request) Has been skipped
- Add en_name column to recipes table (migration in database.py)
- Include en_name in recipe API responses and RecipeUpdate model
- Save en_name when admin/senior_editor applies translation
- Load en_name on overlay open, so translation persists across sessions
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-07 22:08:05 +00:00
6563a6f7d2
Grant senior_editor oil editing, PDF export, and public recipe management
...
PR Preview / teardown-preview (pull_request) Has been skipped
Test / unit-test (push) Successful in 4s
Test / build-check (push) Successful in 3s
PR Preview / test (pull_request) Successful in 4s
PR Preview / deploy-preview (pull_request) Successful in 20s
Test / e2e-test (push) Failing after 1m2s
Add canManage computed (senior_editor + admin) to auth store and use it
for oil edit/delete buttons, PDF export, and public recipe section
visibility. Backend already allowed these operations for senior_editor.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-07 11:59:49 +00:00
9c85ed21b3
Allow all logged-in users to create/edit/delete their own recipes
...
PR Preview / teardown-preview (pull_request) Has been skipped
Test / unit-test (push) Successful in 5s
Test / build-check (push) Successful in 4s
PR Preview / test (pull_request) Successful in 5s
PR Preview / deploy-preview (pull_request) Successful in 13s
Test / e2e-test (push) Failing after 6m48s
Previously only editor+ roles could manage recipes, so viewer users
saw an empty "我的配方" section. Now any authenticated user can CRUD
their own recipes while admin/senior_editor retain full access.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-06 22:30:24 +00:00
d88e202bb3
Fix critical bugs: oil prices ¥0.00, ingredient field mapping
...
- oils store: change Map to plain object for Vue reactivity
- recipes store: map `oil_name` from API (was only mapping `oil`/`name`)
- OilReference: fix .get() calls to bracket access
- Add price-display.cy.js regression test (3 tests)
- Add visual-check.cy.js for screenshot verification
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-06 20:35:01 +00:00
ee8ec23dc7
Refactor frontend to Vue 3 + Vite + Pinia + Cypress E2E
...
- Replace single-file 8441-line HTML with Vue 3 SPA
- Pinia stores: auth, oils, recipes, diary, ui
- Composables: useApi, useDialog, useSmartPaste, useOilTranslation
- 6 shared components: RecipeCard, RecipeDetailOverlay, TagPicker, etc.
- 9 page views: RecipeSearch, RecipeManager, Inventory, OilReference, etc.
- 14 Cypress E2E test specs (113 tests), all passing
- Multi-stage Dockerfile (Node build + Python runtime)
- Demo video generation scripts (TTS + subtitles + screen recording)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-06 18:35:00 +00:00