feat: redeem items support optional duration (permanent/timed)

- Add duration_minutes column to redeem_items (0 = permanent)
- Backend: update RedeemItem/RedeemItemWrite structs, all CRUD SQL
- Backend: EnsureColumn migration for existing databases
- Frontend: add duration selector dropdown (永久/15min/30min/1h/2h/3h/custom)
- Frontend: show ♾️ Permanent or ⏱️ duration in item list

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
这个提交包含在:
cryptocommuniums-afk
2026-02-16 18:38:56 +08:00
父节点 9772ea6764
当前提交 bd300ac597
修改 5 个文件,包含 68 行新增20 行删除

查看文件

@@ -16,6 +16,7 @@ struct RedeemItem {
std::string unit_label;
int holiday_cost = 0;
int studyday_cost = 0;
int duration_minutes = 0; // 0 = permanent
bool is_active = true;
bool is_global = true;
int64_t created_by = 0;
@@ -29,6 +30,7 @@ struct RedeemItemWrite {
std::string unit_label = "小时";
int holiday_cost = 5;
int studyday_cost = 25;
int duration_minutes = 0; // 0 = permanent
bool is_active = true;
bool is_global = true;
};