From 2948799447992e79e2ab8c1877d756de75889807 Mon Sep 17 00:00:00 2001 From: YuanHuakk <1751826683@qq.com> Date: Wed, 18 Oct 2023 16:04:41 +0800 Subject: [PATCH] feat(custom): i --- .env.development | 2 +- src/main.js | 2 +- src/views/game/statistics/index.vue | 5 +++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.env.development b/.env.development index b3fe94f..84d18c9 100644 --- a/.env.development +++ b/.env.development @@ -8,7 +8,7 @@ VITE_USE_MOCK = false VITE_USE_PROXY = true # base api -VITE_BASE_API = '/admin' +VITE_BASE_API = 'https://www.wanzhuanyongcheng.cn/admin' VITE_WS1_URL = 'game.wanzhuanyongcheng.cn/dice/home' diff --git a/src/main.js b/src/main.js index 2304706..44310ae 100644 --- a/src/main.js +++ b/src/main.js @@ -26,7 +26,7 @@ async function setupApp() { if (Array.isArray(value)) { if (value.length > 0) { const hasPermission = permissions.some((key) => { - return all_permission == key || value.includes(key) + return all_permission === key || value.includes(key) }) if (!hasPermission) { diff --git a/src/views/game/statistics/index.vue b/src/views/game/statistics/index.vue index c346273..fe1ee43 100644 --- a/src/views/game/statistics/index.vue +++ b/src/views/game/statistics/index.vue @@ -217,12 +217,13 @@ const getList = async () => { ((res.data.total * 10) / (res.data.total * 10 + res.data.totalDices)) * 100 ).toFixed(2) + const b = ((res.data.totalDices / (res.data.total * 10 + res.data.totalDices)) * 100).toFixed( 2 ) option.value.xAxis.data.push(`第${item.Periods}期-${item.Name}`) option.value.series[0].name = `下注(豆子): ${a}%` - option.value.series[0].data.push(item.NumberSum) + option.value.series[0].data.push(item.NumberSum * 10) option.value.series[1].name = `赔付(积分): ${b}%` option.value.series[1].data.push(item.TotalCount) }) @@ -232,7 +233,7 @@ const getList = async () => { ) const b = ((res.data.totalDices / (res.data.total * 10 + res.data.totalDices)) * 100).toFixed(2) - option1.value.series[0].data.push({ value: res.data.total, name: `总下注: ${a}%` }) + option1.value.series[0].data.push({ value: res.data.total * 10, name: `总下注: ${a}%` }) option1.value.series[0].data.push({ value: res.data.totalDices, name: `总赔付: ${b}%`,