feat(admin): 对齐旧站后台布局与导航
This commit is contained in:
@@ -61,7 +61,7 @@ export function AdminBackupsPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 系统" title="备份管理" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 系统" title="数据备份" />
|
||||
<Alert type="warning" showIcon message="当前账号没有备份查看权限(backup:view)" />
|
||||
</div>
|
||||
)
|
||||
@@ -78,7 +78,7 @@ export function AdminBackupsPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 系统"
|
||||
title="备份管理"
|
||||
title="数据备份"
|
||||
description="查看数据库全量/增量备份状态,并维护定时备份计划。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -215,7 +215,7 @@ export function AdminChatsPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 客服" title="客服会话" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 客服" title="客服群聊" />
|
||||
<Alert type="warning" showIcon message="当前账号没有聊天查看权限(chat:view)" />
|
||||
</div>
|
||||
)
|
||||
@@ -225,7 +225,7 @@ export function AdminChatsPage() {
|
||||
<div className="admin-page admin-chat-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 客服"
|
||||
title="客服会话"
|
||||
title="客服群聊"
|
||||
description="按阶段筛选会话、查看用户消息并直接回复,支持转接与备注。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -172,7 +172,7 @@ export function AdminCrashCategoriesPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 摸红" title="摸红分类" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 摸红" title="撞车分类" />
|
||||
<Alert type="warning" showIcon message="当前账号没有摸红商品权限" />
|
||||
</div>
|
||||
)
|
||||
@@ -182,7 +182,7 @@ export function AdminCrashCategoriesPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 摸红"
|
||||
title="摸红分类"
|
||||
title="撞车分类"
|
||||
description="维护撞车商城的商品分类与排序。"
|
||||
meta={<Tag color="geekblue">共 {categoriesQuery.data?.length ?? 0} 个分类</Tag>}
|
||||
extra={
|
||||
|
||||
@@ -35,8 +35,8 @@ export function AdminCrashConfigPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 摸红" title="摸红配置" />
|
||||
<Alert type="warning" showIcon message="当前账号没有摸红配置权限" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 摸红" title="撞车配置" />
|
||||
<Alert type="warning" showIcon message="当前账号没有撞车配置权限" />
|
||||
</div>
|
||||
)
|
||||
}
|
||||
@@ -45,7 +45,7 @@ export function AdminCrashConfigPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 摸红"
|
||||
title="摸红配置"
|
||||
title="撞车配置"
|
||||
description="维护撞车订单默认固定二维码与订单一键复制模板。"
|
||||
extra={
|
||||
<Button
|
||||
|
||||
@@ -210,8 +210,8 @@ export function AdminCrashOrdersPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 摸红" title="摸红订单" />
|
||||
<Alert type="warning" showIcon message="当前账号没有摸红订单权限" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 摸红" title="撞车订单" />
|
||||
<Alert type="warning" showIcon message="当前账号没有撞车订单权限" />
|
||||
</div>
|
||||
)
|
||||
}
|
||||
@@ -220,7 +220,7 @@ export function AdminCrashOrdersPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 摸红"
|
||||
title="摸红订单"
|
||||
title="撞车订单"
|
||||
description="处理撞车商城订单:接单、完成、取消与退款。"
|
||||
meta={<Tag color="geekblue">共 {ordersQuery.data?.total ?? 0} 单</Tag>}
|
||||
extra={
|
||||
|
||||
@@ -245,8 +245,8 @@ export function AdminCrashProductsPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 摸红" title="摸红商品" />
|
||||
<Alert type="warning" showIcon message="当前账号没有摸红商品权限" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 摸红" title="撞车商品" />
|
||||
<Alert type="warning" showIcon message="当前账号没有撞车商品权限" />
|
||||
</div>
|
||||
)
|
||||
}
|
||||
@@ -255,7 +255,7 @@ export function AdminCrashProductsPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 摸红"
|
||||
title="摸红商品"
|
||||
title="撞车商品"
|
||||
description="维护撞车商城商品、价格、库存与固定二维码。"
|
||||
meta={<Tag color="geekblue">共 {productsQuery.data?.total ?? 0} 个商品</Tag>}
|
||||
extra={
|
||||
|
||||
@@ -173,7 +173,7 @@ export function AdminDisputesPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 交易"
|
||||
title="申诉仲裁"
|
||||
title="仲裁中心"
|
||||
description="核对申诉描述、证据与结账快照,给出可追溯的仲裁结果。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -504,7 +504,7 @@ export function AdminDistributionQrCodesPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 分销"
|
||||
title="二维码池"
|
||||
title="分站二维码池"
|
||||
description="每个分站只从自己的码池发码;池空等待补码,不会混发主站或其他分站二维码。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -165,7 +165,7 @@ export function AdminFinanceDetailsPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader title="资金明细" eyebrow="JIEYOU OPS · 财务" />
|
||||
<AdminPageHeader title="财务明细" eyebrow="JIEYOU OPS · 财务" />
|
||||
<Alert type="warning" showIcon message="当前账号没有资金查看权限" />
|
||||
</div>
|
||||
)
|
||||
@@ -175,7 +175,7 @@ export function AdminFinanceDetailsPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 财务"
|
||||
title="资金明细"
|
||||
title="财务明细"
|
||||
description="按订单维度核对实付、退款、号主结算与平台净额。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
@@ -256,7 +256,7 @@ export function AdminFinanceDetailsPage() {
|
||||
type="error"
|
||||
showIcon
|
||||
className="admin-table-alert"
|
||||
message="资金明细加载失败"
|
||||
message="财务明细加载失败"
|
||||
description={errorText(detailsQuery.error)}
|
||||
/>
|
||||
) : null}
|
||||
@@ -273,7 +273,7 @@ export function AdminFinanceDetailsPage() {
|
||||
setPage(nextPage)
|
||||
setPageSize(nextSize)
|
||||
}}
|
||||
emptyDescription="所选区间还没有资金明细"
|
||||
emptyDescription="所选区间还没有财务明细"
|
||||
/>
|
||||
</div>
|
||||
)
|
||||
|
||||
@@ -265,7 +265,7 @@ export function AdminFinancePage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 财务"
|
||||
title="财务看板"
|
||||
title="财务仪表盘"
|
||||
description="按时间区间核对流水、退款、平台收入、号主结算与出款压力。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -240,7 +240,7 @@ export function AdminInvitationsPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 运营" title="邀请管理" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 运营" title="邀请返利管理" />
|
||||
<Alert type="warning" showIcon message="当前账号没有邀请数据查看权限" />
|
||||
</div>
|
||||
)
|
||||
@@ -252,7 +252,7 @@ export function AdminInvitationsPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 运营"
|
||||
title="邀请管理"
|
||||
title="邀请返利管理"
|
||||
description="维护邀请返利比例,查看邀请关系与返利流水;比例按百分比录入,提交时转 0–1 小数。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -366,8 +366,8 @@ export function AdminManualEntriesPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 客服" title="手工录单" />
|
||||
<Alert type="warning" showIcon message="当前账号没有手工录单查看权限" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 客服" title="手动录单" />
|
||||
<Alert type="warning" showIcon message="当前账号没有手动录单查看权限" />
|
||||
</div>
|
||||
)
|
||||
}
|
||||
@@ -376,7 +376,7 @@ export function AdminManualEntriesPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 客服"
|
||||
title="手工录单"
|
||||
title="手动录单"
|
||||
description="客服在系统外成单后录入编号,用于对账与客服绩效统计。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -270,7 +270,7 @@ export function AdminRolesPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 权限"
|
||||
title="角色权限"
|
||||
title="角色管理"
|
||||
description="维护后台角色与权限矩阵;系统内置角色不可删除。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -328,7 +328,7 @@ export function AdminStaffAccountsPage() {
|
||||
if (!canManage) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 系统" title="管理员账号" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 系统" title="管理员管理" />
|
||||
<Alert type="warning" showIcon message="当前账号没有管理员账号管理权限" />
|
||||
</div>
|
||||
)
|
||||
@@ -338,7 +338,7 @@ export function AdminStaffAccountsPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 系统"
|
||||
title="管理员账号"
|
||||
title="管理员管理"
|
||||
description="维护后台账号、启用状态、角色绑定与密码重置。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -238,7 +238,7 @@ export function AdminSupportGroupsPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 客服"
|
||||
title="客服群组"
|
||||
title="客服分组"
|
||||
description="维护客服分组、在线成员与排序,用于会话分配与订单客服群。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -322,8 +322,8 @@ export function AdminTrackingLinksPage() {
|
||||
if (!canManage) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 运营" title="推广追踪" />
|
||||
<Alert type="warning" showIcon message="当前账号没有推广追踪管理权限" />
|
||||
<AdminPageHeader eyebrow="JIEYOU OPS · 运营" title="推广链接管理" />
|
||||
<Alert type="warning" showIcon message="当前账号没有推广链接管理管理权限" />
|
||||
</div>
|
||||
)
|
||||
}
|
||||
@@ -332,7 +332,7 @@ export function AdminTrackingLinksPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 运营"
|
||||
title="推广追踪"
|
||||
title="推广链接管理"
|
||||
description="管理推广短链、渠道成本与注册下单转化数据。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
|
||||
@@ -125,7 +125,7 @@ export function AdminWalletLedgerPage() {
|
||||
if (!canView) {
|
||||
return (
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader title="钱包流水" eyebrow="JIEYOU OPS · 财务" />
|
||||
<AdminPageHeader title="资金流水" eyebrow="JIEYOU OPS · 财务" />
|
||||
<Alert type="warning" showIcon message="当前账号没有资金查看权限" />
|
||||
</div>
|
||||
)
|
||||
@@ -135,7 +135,7 @@ export function AdminWalletLedgerPage() {
|
||||
<div className="admin-page">
|
||||
<AdminPageHeader
|
||||
eyebrow="JIEYOU OPS · 财务"
|
||||
title="钱包流水"
|
||||
title="资金流水"
|
||||
description="按用户、订单与业务类型核对每一笔余额变动。"
|
||||
meta={
|
||||
<Space size={8} wrap>
|
||||
@@ -197,7 +197,7 @@ export function AdminWalletLedgerPage() {
|
||||
type="error"
|
||||
showIcon
|
||||
className="admin-table-alert"
|
||||
message="钱包流水加载失败"
|
||||
message="资金流水加载失败"
|
||||
description={errorText(ledgerQuery.error)}
|
||||
/>
|
||||
) : null}
|
||||
@@ -214,7 +214,7 @@ export function AdminWalletLedgerPage() {
|
||||
setPage(nextPage)
|
||||
setPageSize(nextSize)
|
||||
}}
|
||||
emptyDescription="还没有钱包流水"
|
||||
emptyDescription="还没有资金流水"
|
||||
/>
|
||||
</div>
|
||||
)
|
||||
|
||||
@@ -169,6 +169,13 @@ export async function fetchAdminMe() {
|
||||
return data.data
|
||||
}
|
||||
|
||||
export async function updateAdminSupportStatus(status: 'online' | 'offline' | 'busy') {
|
||||
const { data } = await adminClient.put<
|
||||
ApiResponse<{ updated: boolean; support_status: string }>
|
||||
>('/admin/me/support-status', { status })
|
||||
return data.data
|
||||
}
|
||||
|
||||
export async function logoutAdmin() {
|
||||
await adminClient.post('/admin/auth/logout')
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user