新增商品类目(限量返场/精英专享)支持与版本号 0.2.1
10.15 抓包确认:积分中心商城 PlayMallUI.queryAllocation 的商品与 webActUI.getActPrizeList(sid=2277) pid 完全一致,属于同一批商品,因此列表无需接商城链路;真号实测 sid=2277 返回 30 项(限量返场 99 共 12 项 + 精英专享 101 共 18 项),sid=2203 已返回空。\n\n- huya:解析商品 tag23/25/26/27/28(发布时间、上架/下架时间、每日时段),新增 PrizeInfo.CategoryIDs/InCategory/StartsAt/NotYetOnSale 与响应级 CategoryStats/CategorySummary/FilterByCategory,列表日志带类目统计\n- sniper:Config.Category 限定自动选品范围,未命中提示带类目\n- CLI:新增 -category / -category-only\n- GUI:Config.Category、ListPrizes 回传类目字典与统计;界面商品列表按类目分页签、每行标注类目、未上架显示上架时间与倒计时,所选类目随配置提交给监控\n- 测试:新增 internal/huya/category_test.go 与 sniper 类目用例;README/WSS_NOTES 补记结论
This commit is contained in:
@@ -23,6 +23,7 @@ export namespace gui {
|
||||
wssHost: string;
|
||||
sid: number;
|
||||
pid: number;
|
||||
category: string;
|
||||
name: string;
|
||||
targetText: string;
|
||||
maxPrice: number;
|
||||
@@ -55,6 +56,7 @@ export namespace gui {
|
||||
this.wssHost = source["wssHost"];
|
||||
this.sid = source["sid"];
|
||||
this.pid = source["pid"];
|
||||
this.category = source["category"];
|
||||
this.name = source["name"];
|
||||
this.targetText = source["targetText"];
|
||||
this.maxPrice = source["maxPrice"];
|
||||
@@ -161,6 +163,8 @@ export namespace gui {
|
||||
status: number;
|
||||
msg: string;
|
||||
prizes: huya.PrizeInfo[];
|
||||
categories: huya.PrizeTag[];
|
||||
categoryStats: huya.CategoryStat[];
|
||||
raw?: huya.GetActPrizeListResp;
|
||||
|
||||
static createFrom(source: any = {}) {
|
||||
@@ -173,6 +177,8 @@ export namespace gui {
|
||||
this.status = source["status"];
|
||||
this.msg = source["msg"];
|
||||
this.prizes = this.convertValues(source["prizes"], huya.PrizeInfo);
|
||||
this.categories = this.convertValues(source["categories"], huya.PrizeTag);
|
||||
this.categoryStats = this.convertValues(source["categoryStats"], huya.CategoryStat);
|
||||
this.raw = this.convertValues(source["raw"], huya.GetActPrizeListResp);
|
||||
}
|
||||
|
||||
@@ -291,6 +297,26 @@ export namespace huya {
|
||||
this.button_desc = source["button_desc"];
|
||||
}
|
||||
}
|
||||
export class CategoryStat {
|
||||
id: number;
|
||||
name: string;
|
||||
count: number;
|
||||
left: number;
|
||||
total: number;
|
||||
|
||||
static createFrom(source: any = {}) {
|
||||
return new CategoryStat(source);
|
||||
}
|
||||
|
||||
constructor(source: any = {}) {
|
||||
if ('string' === typeof source) source = JSON.parse(source);
|
||||
this.id = source["id"];
|
||||
this.name = source["name"];
|
||||
this.count = source["count"];
|
||||
this.left = source["left"];
|
||||
this.total = source["total"];
|
||||
}
|
||||
}
|
||||
export class ExchangeInfo {
|
||||
pid: number;
|
||||
exchange_score: number;
|
||||
@@ -341,6 +367,11 @@ export namespace huya {
|
||||
tags?: string;
|
||||
left_num: number;
|
||||
is_show_num: number;
|
||||
publish_time?: number;
|
||||
start_time?: number;
|
||||
end_time?: number;
|
||||
daily_start?: string;
|
||||
daily_end?: string;
|
||||
|
||||
static createFrom(source: any = {}) {
|
||||
return new PrizeInfo(source);
|
||||
@@ -365,6 +396,11 @@ export namespace huya {
|
||||
this.tags = source["tags"];
|
||||
this.left_num = source["left_num"];
|
||||
this.is_show_num = source["is_show_num"];
|
||||
this.publish_time = source["publish_time"];
|
||||
this.start_time = source["start_time"];
|
||||
this.end_time = source["end_time"];
|
||||
this.daily_start = source["daily_start"];
|
||||
this.daily_end = source["daily_end"];
|
||||
}
|
||||
}
|
||||
export class GetActPrizeListResp {
|
||||
|
||||
Reference in New Issue
Block a user