gamer147
a5999a3e9c
feat(leader-skin): shop catalog + 5 endpoints (/products, /buy, /buy_set, /buy_set_item, /ids)
Schema: LeaderSkinShopSeries -> Products (owned rewards) + owned
SetCompletionRewards on the series; ViewerLeaderSkinSetClaim composite
PK (ViewerId, SeriesId) backs the /buy_set_item idempotent-claim check.
Importer mirrors SleeveShopImporter: idempotent find-or-create, owned
collections rewritten wholesale on rerun. 16 series, 104 products.
Controller (extends existing /set with 5 new endpoints):
- /products: dict-keyed-by-series_id-string wire shape. is_completed
per-viewer, rewards.status from ViewerLeaderSkinSetClaim (0=no set
sale, 1=available, 2=claimed) matching client RewardStatus enum.
- /buy: single skin, sales_type 1/2 dispatch, 3=>501.
- /buy_set: whole series at SetPrice; requires set_sales_status != 0;
grants every product's rewards (RewardGrantService idempotent on
already-owned cosmetics, so partial-set buys don't double-add).
- /buy_set_item: requires viewer owns every skin in series; idempotent
on re-claim (returns 200 + empty reward_list, not 400) so client
retries don't error.
- /ids: flat owned-skin-id list for badge refresh.
496 tests pass (was 486; +10 leader-skin-shop tests).
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-27 22:55:09 -04:00
..
2026-05-27 10:41:49 -04:00
2026-05-27 00:00:24 -04:00
2026-05-27 10:30:29 -04:00
2026-05-27 14:11:47 -04:00
2026-05-27 10:35:40 -04:00
2026-05-27 22:55:09 -04:00
2026-05-27 22:55:09 -04:00
2026-05-25 19:07:49 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 18:14:42 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 18:14:42 -04:00
2026-05-23 18:14:42 -04:00
2026-05-23 19:57:34 -04:00
2026-05-26 22:49:30 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 19:57:34 -04:00
2026-05-24 21:13:15 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 18:14:42 -04:00
2026-05-24 02:03:13 -04:00
2026-05-24 02:03:13 -04:00
2026-05-24 02:03:13 -04:00
2026-05-24 02:03:13 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 18:14:42 -04:00
2026-05-23 18:14:42 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-24 02:03:13 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 18:14:42 -04:00
2026-05-23 15:47:23 -04:00
2024-09-12 00:35:31 -04:00
2026-05-23 19:57:34 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 18:14:42 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-25 12:03:47 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-24 21:13:15 -04:00
2026-05-26 10:01:37 -04:00
2026-05-23 18:14:42 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 15:47:23 -04:00
2026-05-23 18:14:42 -04:00
2026-05-23 15:47:23 -04:00