feat: 场地无项目时显示提示并隐藏选手列表

- 添加"当前场地暂无比赛项目"提示
- 当没有项目时隐藏选手列表
- 添加no-project-tip样式

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
This commit is contained in:
DevOps
2026-01-07 11:31:40 +08:00
parent 1b305fc2bd
commit 56a33707d5
2 changed files with 20 additions and 2 deletions

View File

@@ -39,6 +39,7 @@
> >
{{ project.projectName }} {{ project.projectName }}
</view> </view>
<view class="no-project-tip" v-if="projects.length === 0">当前场地暂无比赛项目</view>
</view> </view>
</view> </view>
@@ -49,7 +50,7 @@
</view> </view>
<!-- 选手列表 --> <!-- 选手列表 -->
<view class="player-list"> <view class="player-list" v-if="projects.length > 0">
<!-- 遍历选手列表 --> <!-- 遍历选手列表 -->
<view <view
class="player-card" class="player-card"
@@ -685,4 +686,12 @@ export default {
color: #666666; color: #666666;
line-height: 1.5; line-height: 1.5;
} }
.no-project-tip {
padding: 30rpx;
text-align: center;
color: #999;
font-size: 28rpx;
width: 100%;
}
</style> </style>

View File

@@ -37,6 +37,7 @@
</view> </view>
</view> </view>
</scroll-view> </scroll-view>
<view class="no-project-tip" v-if="projects.length === 0">当前场地暂无比赛项目</view>
</view> </view>
<!-- 评分统计 --> <!-- 评分统计 -->
@@ -46,7 +47,7 @@
</view> </view>
<!-- 选手列表 --> <!-- 选手列表 -->
<view class="player-list"> <view class="player-list" v-if="projects.length > 0">
<!-- 选手卡片 --> <!-- 选手卡片 -->
<view <view
class="player-card" class="player-card"
@@ -662,4 +663,12 @@ export default {
font-size: 28rpx; font-size: 28rpx;
color: #999999; color: #999999;
} }
.no-project-tip {
padding: 30rpx;
text-align: center;
color: #999;
font-size: 28rpx;
width: 100%;
}
</style> </style>