feat(admin,player,api): 公共管理与优胜冠军国旗、玩家端内容对接

新增公共内容 CRUD 与批量操作;公告滚动合并管理;优胜冠军内置国家选择与单行保存;玩家端统一 usePlayerHome 对接轮播与跑马灯。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-06-04 10:25:42 +08:00
parent 27580b2479
commit f76728dc3e
21 changed files with 1966 additions and 136 deletions

View File

@@ -36,6 +36,7 @@ const zh: Record<string, string> = {
'nav.outrights': '优胜冠军',
'nav.bets': '注单管理',
'nav.cashback': '返水管理',
'nav.contents': '公共管理',
'nav.audit': '操作日志',
'nav.players': '直属玩家',
'nav.subAgents': '下级代理',
@@ -187,6 +188,7 @@ const en: Record<string, string> = {
'nav.outrights': 'Outrights',
'nav.bets': 'Bets',
'nav.cashback': 'Cashback',
'nav.contents': 'Public Content',
'nav.audit': 'Audit Log',
'nav.players': 'My Players',
'nav.subAgents': 'Sub-Agents',
@@ -338,6 +340,7 @@ const ms: Record<string, string> = {
'nav.outrights': 'Juara',
'nav.bets': 'Pertaruhan',
'nav.cashback': 'Rebat',
'nav.contents': 'Kandungan awam',
'nav.audit': 'Log audit',
'nav.players': 'Pemain saya',
'nav.subAgents': 'Sub-ejen',

View File

@@ -249,13 +249,61 @@ export const adminPagesMs: Record<string, string> = {
'msg.outright_odds_saved': 'Odds juara disimpan',
'msg.load_failed': 'Gagal memuatkan',
'content.btn.create': 'Kandungan baharu',
'content.btn.enable': 'Aktifkan',
'content.btn.disable': 'Nyahaktif',
'content.dialog.create': 'Kandungan awam baharu',
'content.dialog.edit': 'Edit kandungan awam',
'content.confirm_delete': 'Padam "{title}"?',
'content.type.BANNER': 'Banner laman utama',
'content.type.ANNOUNCEMENT': 'Pengumuman',
'content.hint.announcement': 'Dipaparkan di ticker atas pemain; isi tajuk atau kandungan',
'content.status.DRAFT': 'Draf',
'content.status.ACTIVE': 'Aktif',
'content.status.INACTIVE': 'Tidak aktif',
'content.col.sort': 'Susunan',
'content.col.preview': 'Pratonton',
'content.col.title': 'Tajuk / ringkasan',
'content.col.player_visible': 'Pemain nampak',
'content.col.schedule': 'Jadual',
'content.col.link': 'Pautan',
'content.field.link_type': 'Jenis pautan',
'content.field.link_target': 'Sasaran pautan',
'content.field.start_time': 'Masa mula',
'content.field.end_time': 'Masa tamat',
'content.field.title': 'Tajuk',
'content.field.title_ph': 'Pilihan',
'content.field.body': 'Kandungan',
'content.field.announce_text': 'Teks ticker',
'content.field.image_url': 'URL imej',
'content.link.none': 'Tiada pautan',
'content.locale.zh-CN': 'Cina Ringkas',
'content.locale.en-US': 'English',
'content.locale.ms-MY': 'Bahasa Melayu',
'content.hidden_reason.NOT_ACTIVE': 'Tidak aktif atau draf',
'content.hidden_reason.NOT_STARTED': 'Belum bermula',
'content.hidden_reason.EXPIRED': 'Tamat tempoh',
'content.hidden_reason.INCOMPLETE': 'Terjemahan tidak lengkap',
'content.batch.selected': '{n} dipilih',
'content.batch.enable': 'Aktifkan dipilih',
'content.batch.disable': 'Nyahaktif dipilih',
'content.batch.delete': 'Padam dipilih',
'content.confirm_batch_enable': 'Aktifkan {n} item dipilih?',
'content.confirm_batch_disable': 'Nyahaktif {n} item dipilih?',
'content.confirm_batch_delete': 'Padam {n} item dipilih?',
'content.batch.all_ok': '{n} item berjaya',
'content.batch.partial': '{ok} berjaya, {fail} gagal',
'page.outrights.title': 'Juara',
'page.outrights.desc': 'Cipta dan edit pasaran juara; Piala Dunia 2026 boleh import asas',
'outright.col.rank': 'Kedudukan',
'outright.col.team_zh': 'Pasukan (ZH)',
'outright.col.team_en': 'Pasukan (EN)',
'outright.col.code': 'Kod',
'outright.col.country': 'Negara',
'outright.col.odds': 'Odds juara',
'outright.country_ph': 'Cari atau pilih negara',
'outright.err_country': 'Sila pilih negara',
'outright.btn.save_odds': 'Simpan semua odds',
'outright.btn.apply_canonical': 'Guna data jadual asas',
'msg.outright_canonical_applied': 'Odds 48 pasukan telah dikemas kini',

View File

@@ -249,13 +249,61 @@ export const adminPagesZh: Record<string, string> = {
'msg.outright_odds_saved': '夺冠赔率已保存',
'msg.load_failed': '加载失败',
'content.btn.create': '新建内容',
'content.btn.enable': '启用',
'content.btn.disable': '停用',
'content.dialog.create': '新建公共内容',
'content.dialog.edit': '编辑公共内容',
'content.confirm_delete': '确定删除「{title}」?',
'content.type.BANNER': '首页轮播',
'content.type.ANNOUNCEMENT': '公告滚动',
'content.hint.announcement': '显示在玩家端顶部跑马灯;标题与正文填一项即可,建议正文为主',
'content.status.DRAFT': '草稿',
'content.status.ACTIVE': '已启用',
'content.status.INACTIVE': '已停用',
'content.col.sort': '排序',
'content.col.preview': '预览',
'content.col.title': '标题/摘要',
'content.col.player_visible': '玩家可见',
'content.col.schedule': '展示时段',
'content.col.link': '跳转',
'content.field.link_type': '链接类型',
'content.field.link_target': '链接目标',
'content.field.start_time': '开始时间',
'content.field.end_time': '结束时间',
'content.field.title': '标题',
'content.field.title_ph': '选填,可与正文相同',
'content.field.body': '正文',
'content.field.announce_text': '滚动文案',
'content.field.image_url': '图片地址',
'content.link.none': '无跳转',
'content.locale.zh-CN': '简体中文',
'content.locale.en-US': 'English',
'content.locale.ms-MY': 'Bahasa Melayu',
'content.hidden_reason.NOT_ACTIVE': '未启用或草稿',
'content.hidden_reason.NOT_STARTED': '未到开始时间',
'content.hidden_reason.EXPIRED': '已过结束时间',
'content.hidden_reason.INCOMPLETE': '多语言内容不完整',
'content.batch.selected': '已选 {n} 项',
'content.batch.enable': '批量启用',
'content.batch.disable': '批量停用',
'content.batch.delete': '批量删除',
'content.confirm_batch_enable': '确定启用选中的 {n} 项?',
'content.confirm_batch_disable': '确定停用选中的 {n} 项?',
'content.confirm_batch_delete': '确定删除选中的 {n} 项?',
'content.batch.all_ok': '已成功处理 {n} 项',
'content.batch.partial': '成功 {ok} 项,失败 {fail} 项',
'page.outrights.title': '优胜冠军',
'page.outrights.desc': '可新建任意联赛冠军盘、编辑队伍与赔率;世界杯 48 强提供一键导入基准数据',
'outright.col.rank': '排名',
'outright.col.team_zh': '队伍(中文)',
'outright.col.team_en': '队伍(英文)',
'outright.col.code': '代码',
'outright.col.country': '国家/地区',
'outright.col.odds': '夺冠赔率',
'outright.country_ph': '搜索或选择国家',
'outright.err_country': '请选择国家',
'outright.btn.save_odds': '保存全部赔率',
'outright.btn.save_meta': '保存赛事信息',
'outright.btn.publish': '发布',
@@ -553,13 +601,61 @@ export const adminPagesEn: Record<string, string> = {
'msg.outright_odds_saved': 'Outright odds saved',
'msg.load_failed': 'Load failed',
'content.btn.create': 'New content',
'content.btn.enable': 'Enable',
'content.btn.disable': 'Disable',
'content.dialog.create': 'New public content',
'content.dialog.edit': 'Edit public content',
'content.confirm_delete': 'Delete "{title}"?',
'content.type.BANNER': 'Home banners',
'content.type.ANNOUNCEMENT': 'Announcements',
'content.hint.announcement': 'Shown in the player top marquee; fill title or body (body recommended)',
'content.status.DRAFT': 'Draft',
'content.status.ACTIVE': 'Active',
'content.status.INACTIVE': 'Inactive',
'content.col.sort': 'Sort',
'content.col.preview': 'Preview',
'content.col.title': 'Title / summary',
'content.col.player_visible': 'Player visible',
'content.col.schedule': 'Schedule',
'content.col.link': 'Link',
'content.field.link_type': 'Link type',
'content.field.link_target': 'Link target',
'content.field.start_time': 'Start time',
'content.field.end_time': 'End time',
'content.field.title': 'Title',
'content.field.title_ph': 'Optional; can match body',
'content.field.body': 'Body',
'content.field.announce_text': 'Marquee text',
'content.field.image_url': 'Image URL',
'content.link.none': 'No link',
'content.locale.zh-CN': 'Chinese (Simplified)',
'content.locale.en-US': 'English',
'content.locale.ms-MY': 'Malay',
'content.hidden_reason.NOT_ACTIVE': 'Not active or draft',
'content.hidden_reason.NOT_STARTED': 'Not started yet',
'content.hidden_reason.EXPIRED': 'Expired',
'content.hidden_reason.INCOMPLETE': 'Incomplete translations',
'content.batch.selected': '{n} selected',
'content.batch.enable': 'Enable selected',
'content.batch.disable': 'Disable selected',
'content.batch.delete': 'Delete selected',
'content.confirm_batch_enable': 'Enable {n} selected item(s)?',
'content.confirm_batch_disable': 'Disable {n} selected item(s)?',
'content.confirm_batch_delete': 'Delete {n} selected item(s)?',
'content.batch.all_ok': '{n} item(s) processed',
'content.batch.partial': '{ok} succeeded, {fail} failed',
'page.outrights.title': 'Outrights',
'page.outrights.desc': 'Create and edit any winner market; WC 2026 has one-click baseline import',
'outright.col.rank': 'Rank',
'outright.col.team_zh': 'Team (ZH)',
'outright.col.team_en': 'Team (EN)',
'outright.col.code': 'Code',
'outright.col.country': 'Country',
'outright.col.odds': 'Winner odds',
'outright.country_ph': 'Search or select country',
'outright.err_country': 'Please select a country',
'outright.btn.save_odds': 'Save all odds',
'outright.btn.save_meta': 'Save event info',
'outright.btn.publish': 'Publish',