fix: 修改热门赛事列表

This commit is contained in:
lz-ui 2025-10-24 17:43:32 +08:00
parent d932dcdf2b
commit ff4dd7734b

View File

@ -103,7 +103,7 @@ function getDetail() {
try {
if(isCustom.value) {
//
const matchDateTime = timerToStr(res.data.matchInfo.matchDateTime, 'YYYY-MM-DD HH:mm')
const matchDateTime = res.data.matchInfo && res.data.matchInfo.matchDateTime ? timerToStr(res.data.matchInfo.matchDateTime, 'YYYY-MM-DD HH:mm') : '-'
const matchCode = res.data.matchCode
const report = JSON.parse(res.data.report)
const { keyFactors, matchInfo, predictions } = report
@ -129,6 +129,24 @@ function getDetail() {
// 2.
influencingList.value = keyFactors
// 3.
if (modelType.value === 'HOT_F') {
//
coreList.value = [
{
"name": "总进球数",
"key": "total_goals",
"prediction": predictions.total_goals.prediction,
"analysis": predictions.total_goals.analysis
},
{
"name": "亚洲盘口",
"key": "asian_handicap",
"prediction": predictions.asian_handicap.prediction,
"analysis": predictions.asian_handicap.analysis
},
]
} else {
coreList.value = [
{
"name": "最终赛果",
@ -168,6 +186,7 @@ function getDetail() {
},
]
}
}
} catch (error) {
console.log(error)
}