diff --git a/generateCourseLiveList.js b/generateCourseLiveList.js index 2963ea3..707e340 100644 --- a/generateCourseLiveList.js +++ b/generateCourseLiveList.js @@ -74,11 +74,11 @@ for (let i = 1; i < lines.length; i++) { // 判断课程状态: // - 已完成:状态为"已结束"或日期在今天之前 - // - 直播中(current):今天的课程 - // - 即将开始(upcoming):未来7天内的课程(在组件中会显示为"即将开始") + // - 直播中(current):暂时没有课程处于直播中状态 + // - 即将开始(upcoming):今天及未来7天内的课程(在组件中会显示为"即将开始") const isCompleted = status === '已结束' || daysDiff < 0; - const isCurrent = daysDiff === 0; // 今天的课程设为直播中 - const isUpcoming = !isCompleted && !isCurrent && daysDiff > 0 && daysDiff <= 7; // 未来7天内 + const isCurrent = false; // 不设置任何课程为直播中 + const isUpcoming = !isCompleted && daysDiff >= 0 && daysDiff <= 7; // 今天及未来7天内 unitData.courses.push({ courseId: `c${unitData.unitId.replace('unit', '')}-${unitData.courses.length + 1}`, diff --git a/src/components/CoursesVideoPlayer/index.jsx b/src/components/CoursesVideoPlayer/index.jsx index 099319a..5942b99 100644 --- a/src/components/CoursesVideoPlayer/index.jsx +++ b/src/components/CoursesVideoPlayer/index.jsx @@ -81,15 +81,7 @@ export default ({ className = "", isLock = false, selectedCourse, teacherData, u handleClickBtn(2)}>下一集 >
- {selectedCourse?.current ? ( - - ) : ( - {unitName} - )} +
)}