功能:婚姻系统第9步(后台管理页面)

Admin/MarriageManagerController:
- index() 总览统计卡片
- list() 婚姻列表(筛选/强制离婚/取消求婚)
- proposals() 求婚记录
- ceremonies() 婚礼红包记录
- claimDetail() 红包领取明细
- intimacyLogs() 亲密度日志(来源筛选)
- configs/updateConfigs 参数配置(批量保存)
- tiers/updateTier 婚礼档位管理

Views(7个页面):admin/marriages/{index|list|configs|tiers|ceremonies|claim-detail|proposals|intimacy-logs}
侧边栏:superlevel 区块新增「💒 婚姻管理」入口
This commit is contained in:
2026-03-01 15:15:03 +08:00
parent 4f49fb7ce8
commit d2797d5b59
10 changed files with 1108 additions and 1 deletions
@@ -0,0 +1,85 @@
{{--
文件功能:婚礼红包领取明细页
@author ChatRoom Laravel
@version 1.0.0
--}}
@extends('admin.layouts.app')
@section('title', '婚礼红包明细')
@section('content')
<div class="flex items-center justify-between mb-5">
<div>
<h2 class="text-xl font-bold text-gray-800">🎁 红包领取明细</h2>
<p class="text-sm text-gray-500 mt-1">
{{ $ceremony->marriage?->user?->username }} × {{ $ceremony->marriage?->partner?->username }}
{{ $ceremony->tier?->icon }} {{ $ceremony->tier?->name ?? '婚礼' }}
· 总额 <strong class="text-amber-600">{{ number_format($ceremony->total_amount) }} </strong>
</p>
</div>
<a href="{{ route('admin.marriages.ceremonies') }}" class="text-sm text-indigo-600 hover:underline"> 返回婚礼列表</a>
</div>
{{-- 汇总 --}}
<div class="grid grid-cols-3 gap-4 mb-5">
<div class="bg-white rounded-xl border shadow-sm p-4 text-center">
<div class="text-2xl font-bold text-indigo-600">{{ $ceremony->online_count ?? 0 }}</div>
<div class="text-xs text-gray-500 mt-1">在线人数</div>
</div>
<div class="bg-white rounded-xl border shadow-sm p-4 text-center">
<div class="text-2xl font-bold text-green-600">{{ $ceremony->claimed_count }}</div>
<div class="text-xs text-gray-500 mt-1">已领取人数</div>
</div>
<div class="bg-white rounded-xl border shadow-sm p-4 text-center">
<div class="text-2xl font-bold text-amber-600">{{ number_format($ceremony->claimed_amount) }}</div>
<div class="text-xs text-gray-500 mt-1">已领取金额</div>
</div>
</div>
<div class="bg-white rounded-xl shadow-sm border overflow-hidden">
<div class="overflow-x-auto">
<table class="w-full text-sm">
<thead class="bg-gray-50 text-xs uppercase text-gray-600">
<tr>
<th class="px-4 py-3 text-left">用户</th>
<th class="px-4 py-3 text-center">分配金额</th>
<th class="px-4 py-3 text-center">状态</th>
<th class="px-4 py-3 text-left">领取时间</th>
</tr>
</thead>
<tbody class="divide-y">
@forelse ($claims as $claim)
<tr class="hover:bg-gray-50">
<td class="px-4 py-3 font-bold">{{ $claim->user?->username }}</td>
<td class="px-4 py-3 text-center font-bold text-amber-600">
{{ number_format($claim->amount) }}
</td>
<td class="px-4 py-3 text-center">
@if ($claim->claimed)
<span class="px-2 py-0.5 rounded-full text-xs bg-green-100 text-green-700 font-bold">
已领取</span>
@else
<span class="px-2 py-0.5 rounded-full text-xs bg-gray-100 text-gray-500">未领取</span>
@endif
</td>
<td class="px-4 py-3 text-xs text-gray-500">
{{ $claim->claimed_at?->format('H:i:s') ?? '—' }}
</td>
</tr>
@empty
<tr>
<td colspan="4" class="px-4 py-12 text-center text-gray-400">暂无领取记录</td>
</tr>
@endforelse
</tbody>
</table>
</div>
@if ($claims->hasPages())
<div class="px-4 py-4 border-t">{{ $claims->links() }}</div>
@endif
</div>
@endsection