feat(admin,api,player): 优胜赛配置、赛事管理重构与玩家端投注体验优化
管理端拆分赛事/优胜赛 Tab,新增联赛优胜赔率面板(批量、排序、外侧删除);统一 list-chrome 工具栏对齐与列表页布局;Dashboard 失败重试、Users 操作下拉、小屏侧栏等体验修复。 API 扩展优胜赛与赛事目录接口,完善投注与钱包查询;玩家端重构赛事卡片、串关面板、注单/钱包页,新增注单详情、下注成功动画与下拉刷新。 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
30
apps/admin/src/views/outrights/OutrightEditRedirect.vue
Normal file
30
apps/admin/src/views/outrights/OutrightEditRedirect.vue
Normal file
@@ -0,0 +1,30 @@
|
||||
<script setup lang="ts">
|
||||
import { onMounted } from 'vue';
|
||||
import { useRoute, useRouter } from 'vue-router';
|
||||
import api from '../../api';
|
||||
|
||||
const route = useRoute();
|
||||
const router = useRouter();
|
||||
|
||||
onMounted(async () => {
|
||||
const matchId = String(route.params.matchId ?? '').trim();
|
||||
if (!matchId) {
|
||||
await router.replace('/matches/outrights');
|
||||
return;
|
||||
}
|
||||
try {
|
||||
const { data } = await api.get(`/admin/outrights/${matchId}`);
|
||||
const leagueId = data.data?.leagueId as string | undefined;
|
||||
await router.replace({
|
||||
path: '/matches/outrights',
|
||||
query: leagueId ? { leagueId } : { matchId },
|
||||
});
|
||||
} catch {
|
||||
await router.replace('/matches/outrights');
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div />
|
||||
</template>
|
||||
@@ -1,10 +1,11 @@
|
||||
<script setup lang="ts">
|
||||
import { ref, computed, watch } from 'vue';
|
||||
import { useRoute, useRouter } from 'vue-router';
|
||||
import { useRoute } from 'vue-router';
|
||||
import { ElMessage, ElMessageBox } from 'element-plus';
|
||||
import { useAdminLocale } from '../../composables/useAdminLocale';
|
||||
import api from '../../api';
|
||||
import LogoUrlField from '../../components/LogoUrlField.vue';
|
||||
import AdminSubNav from '../../components/AdminSubNav.vue';
|
||||
import {
|
||||
getBuiltinCountry,
|
||||
resolveCountryCode,
|
||||
@@ -12,7 +13,6 @@ import {
|
||||
} from '../../data/builtinCountries';
|
||||
|
||||
const route = useRoute();
|
||||
const router = useRouter();
|
||||
const { t } = useAdminLocale();
|
||||
|
||||
const matchId = computed(() => String(route.params.matchId ?? ''));
|
||||
@@ -336,11 +336,10 @@ async function saveRow(row: SelectionRow) {
|
||||
|
||||
<template>
|
||||
<div class="event-editor" v-loading="loading">
|
||||
<div class="editor-topbar">
|
||||
<el-button size="small" text @click="router.push({ name: 'admin-outrights' })">
|
||||
← {{ t('outright.back_list') }}
|
||||
</el-button>
|
||||
</div>
|
||||
<AdminSubNav
|
||||
:title="t('outright.section.edit')"
|
||||
:subtitle="`#${matchId}`"
|
||||
/>
|
||||
|
||||
<el-alert
|
||||
v-if="!meta.playerVisible"
|
||||
@@ -513,14 +512,6 @@ async function saveRow(row: SelectionRow) {
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.editor-topbar {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
flex-shrink: 0;
|
||||
margin-bottom: 2px;
|
||||
}
|
||||
|
||||
.player-alert {
|
||||
flex-shrink: 0;
|
||||
margin-bottom: 0;
|
||||
|
||||
Reference in New Issue
Block a user