样式修改完成,待测试

This commit is contained in:
rain
2026-07-07 17:07:34 +08:00
parent 0f6ed0cad3
commit 8a6a8acab7
32 changed files with 2097 additions and 505 deletions
+16 -2
View File
@@ -768,6 +768,19 @@ const ApiClient = {
const params = this.normalizePageParams(data || {});
const code = params.code || params.suoxie || params.lotteryCode || '';
const pageSize = params.pageSize || params.limit || params.count || 100;
const normalizeResponse = (res) => {
if (!this.isSuccess(res)) return res;
const payload = this.pickData(res, {});
const list = this.asArray(payload);
return Object.assign({}, res, {
code: 0,
success: true,
data: list,
rawData: payload,
rows: list,
records: list,
});
};
if (code && this.API.lotteryTrend) {
try {
const trendRes = await this.get(this.API.lotteryTrend, {
@@ -775,13 +788,14 @@ const ApiClient = {
pageSize,
});
if (this.isSuccess(trendRes) && this.asArray(this.pickData(trendRes, [])).length) {
return trendRes;
return normalizeResponse(trendRes);
}
} catch (e) {
// Fall back to the older result-list endpoint below.
}
}
return this.requestWithMenu('/api/web/lottery/result/list', data);
const listRes = await this.requestWithMenu('/api/web/lottery/result/list', data);
return normalizeResponse(listRes);
},
async loadLegacyExpertDetailCompat(data = {}) {