fix: 订场页时间标签显示修复 + 约课页列表刷新修复

- private/index.vue: 时间标签改为单时间+竖线样式,第一行加 margin-top 防止被表头遮挡
- courses/index.vue: 修复切换Tab/日期列表不刷新问题(竞态条件+不清空旧数据+无错误处理)
- .env: 冰场馆URL修正
This commit is contained in:
gqt
2026-07-15 13:57:57 +08:00
parent 4b886840c0
commit d00304ec9c
3 changed files with 46 additions and 11 deletions
@@ -50,8 +50,11 @@
v-for="(slot, si) in grid.time_slots"
:key="si"
class="grid-row"
:class="{ 'grid-row-first': si === 0 }"
>
<view class="time-label-cell">{{ slot.start }}</view>
<view class="time-label-cell">
<text class="time-text">{{ slot.start }}</text>
</view>
<view
v-for="court in grid.courts"
:key="court.id"
@@ -489,24 +492,38 @@ defineExpose({
display: flex;
}
.grid-row-first {
margin-top: 20rpx;
}
.time-label-cell {
width: 128rpx;
flex-shrink: 0;
height: 107rpx;
display: flex;
align-items: center;
justify-content: center;
background: $bg-color-main;
border-right: 1rpx solid $border-color;
border-bottom: 1rpx solid $bg-color-hover;
color: $text-color-muted;
font-size: 20rpx;
font-weight: 700;
position: sticky;
left: 0;
z-index: 5;
}
.time-text {
position: absolute;
top: 0;
left: 0;
right: 0;
text-align: center;
transform: translateY(-50%);
background: $bg-color-main;
padding: 0 6rpx;
font-size: 20rpx;
font-weight: 700;
color: $text-color-muted;
line-height: 1;
z-index: 6;
}
.grid-cell {
width: 149rpx;
flex-shrink: 0;