Commit 88f38faf by 胡悦

fix(studyDetail): Correct progress display logic in detail.vue and longCourse.vue

- Updated the progress display logic to ensure that a value of 0 is shown correctly when item.progress is 0, preventing potential display issues.
1 parent aaf3dd12
......@@ -22,7 +22,7 @@
<view class="item-info-label">当前状态</view>
<view :class="['item-info-value', item.status === 5 ? 'green' : 'orange']">
<view v-if="item.status !== 5" class="dot-value"></view>
{{ item.status !== 5 ? `${statusMap[item.status]}(${item.progress === 0 ? 0 : item.progress}%)` : '已完成' }}
{{ item.status !== 5 ? `${statusMap[item.status]}(${item.progress === 0 ? 0 : item.progress || 0}%)` : '已完成' }}
</view>
</view>
<view class="item-info">
......
......@@ -69,7 +69,7 @@
<view class="item-info-label">当前状态</view>
<view :class="['item-info-value', item.status === 5 ? 'green' : 'orange']">
<view class="dot-value" :class="item.status === 5 ? 'green' : 'orange'"></view>
{{ item.status !== 5 ? `${statusMap[item.status]}(${item.progress === 0 ? 0 : item.progress}%)` : '已完成' }}
{{ item.status !== 5 ? `${statusMap[item.status]}(${item.progress === 0 ? 0 : item.progress || 0}%)` : '已完成' }}
</view>
</view>
<view class="item-info">
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!