4ee6de2548
- CpsActivityUpdate schema + repo update_activity(部分更新,非 None 覆盖) - router 按「合并后最终值」校验平台必填项(同新建口径),写审计 cps.activity.update - 可改名/平台/对应字段/落地页图/备注/状态 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1.2 KiB
1.2 KiB
signin_boost_record — 签到膨胀记录
App 用户当天签到后,看完激励视频可固定膨胀一次(默认 3000 金币,rewards.SIGNIN_BOOST_COIN,运营后台 app_config.signin_boost_coin 可改)。循环最后一天(cycle_day == SIGNIN_CYCLE_LEN,即 7 天循环的第 7 天)不展示也不允许膨胀。本表记录膨胀动作,并用唯一约束防重复补发。
字段
| 字段 | 类型 | 约束 | 说明 |
|---|---|---|---|
id |
Integer | PK | 自增主键 |
user_id |
Integer | FK → user.id, index, NOT NULL |
用户 |
signin_date |
Date | NOT NULL | 被膨胀的签到日期,北京时间 |
coin_awarded |
Integer | NOT NULL | 本次补发金币,默认固定 3000(rewards.get_signin_boost_coin) |
ad_ref_id |
String(64) | nullable | 穿山甲 S2S 回调 trans_id |
created_at |
DateTime(tz) | server_default now(), NOT NULL | 创建时间 |
约束
UNIQUE(user_id, signin_date)=uq_signin_boost_user_date:同一用户同一天只能膨胀一次。
关联
- 膨胀成功时写
coin_transaction.biz_type=signin_boost,ref_id = ad_ref_id(无 ad_ref_id 时回退当天日期 ISO 串)。