courseDetail.wxml 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. <wxs src='../../../utils/formatFuc.wxs' module="format"></wxs>
  2. <wxs src='../../../utils/format.wxs' module="utils"></wxs>
  3. <view class="container">
  4. <view class="course-title">
  5. 课程名称:{{courseInfo.course.courseName}}
  6. </view>
  7. <view class="course-type">课程形式:
  8. <text wx:if="{{courseInfo.course.form=='1'}}">线上</text>
  9. <text wx:if="{{courseInfo.course.form=='2'}}">线下</text>
  10. <text wx:if="{{courseInfo.course.form=='3'}}">线上+线下</text>
  11. </view>
  12. <view class="course-content" style="margin-bottom:14rpx;">
  13. 课程内容:{{courseInfo.course.courseSketch}}</view>
  14. <view class="skill-line">
  15. 课程完成获取技能:{{courseInfo.courseSkill}}
  16. </view>
  17. <view class="common-line">
  18. 需完成时间: {{format.formatDate(courseInfo.arrangement.endTime)}}
  19. </view>
  20. <view class="common-line">
  21. 线下培训时间:{{format.formatDate(courseInfo.arrangement.startTime)}}
  22. </view>
  23. <!-- 2视频 1图文 -->
  24. <view wx:if="{{courseInfo.course.contentType==1}}">
  25. <view class="detail">
  26. <import src="/lib/wxParse/wxParse.wxml" />
  27. <template is="wxParse" data="{{wxParseData:courseHtml.nodes}}" />
  28. </view>
  29. </view>
  30. <view wx:if="{{courseInfo.course.contentType==2}}">
  31. <!-- <view class="video-wrapper">
  32. <view class="video-info">
  33. <view class="title-left">
  34. 第二节:2023新人训 视频2
  35. </view>
  36. <view class="title-right"
  37. >
  38. <van-icon name="clock-o" size="20px" color="#666666"/>
  39. <view class="hour">5小时</view>
  40. </view>
  41. </view>
  42. <view class="video-status">未完成</view>
  43. </view> -->
  44. <view class="video-wrapper" wx:for="{{courseInfo.courseVideoList}}" wx:key="index" bindtap="toggleVideo" data-index="{{index}}" data-istiled="{{item.isTiled}}">
  45. <view class="video-info" >
  46. <view class="title-left">
  47. {{item.videoName}}
  48. </view>
  49. <view class="title-right"
  50. >
  51. <!-- <van-icon name="clock-o" size="20px" color="#666666"/>
  52. <view class="hour">{{utils.learnTime(item.duration)}}</view> -->
  53. </view>
  54. </view>
  55. <view class="duration-wrapper"
  56. >
  57. <van-icon name="clock-o" size="20px" color="#666666"/>
  58. <view class="hour">{{utils.learnTime(item.duration)}}</view>
  59. </view>
  60. <view class="video-status" wx:if="{{item.isComplate==1}}">已完成</view>
  61. <view class="video-status" wx:if="{{item.isComplate==0}}">未完成</view>
  62. <video hidden="{{!item.isTiled}}"
  63. class="video-block"
  64. src="{{item.videoUrl}}"
  65. object-fit="contain"
  66. enable-danmu
  67. danmu-btn
  68. bindtimeupdate="videoPlay"
  69. bindplay="videoBegin"
  70. bindended="videoEnd"
  71. show-center-play-btn='{{true}}'
  72. show-play-btn="{{true}}"
  73. show-progress="{{true}}"
  74. show-bottom-progress="{{true}}"
  75. enable-progress-gesture="{{false}}"
  76. controls
  77. data-videoid="{{item.videoOssId}}"
  78. ></video>
  79. </view>
  80. </view>
  81. <view class="operate-record">
  82. <view class="common-line title">
  83. <text class="left">实操记录</text>
  84. <text>{{courseInfo.enrolment.raterTime}}</text>
  85. </view>
  86. <view class="common-line">
  87. 培训老师: {{courseInfo.arrangement.lectureUserName}}
  88. </view>
  89. <view class="common-line">
  90. 培训内容: {{courseInfo.arrangement.trainingContent}}
  91. </view>
  92. <view class="common-line">
  93. 实操打分:{{courseInfo.enrolment.score}}
  94. </view>
  95. </view>
  96. <view class="relate-course">
  97. <view class="head common-line">
  98. 课程相关知识
  99. </view>
  100. <scroll-view class="scroll-view" scroll-x="true" bindscroll="scroll" >
  101. <view class="relate-item" wx:for="{{courseInfo.relationCourse}}" wx:key="index" bindtap="goCourseDetail" data-id="{{item.id}}">
  102. <image src="{{item.courseBackimgSamll}}" class="relate-img" mode="aspectFill"></image>
  103. <view class="relate-title">
  104. {{item.courseName}}
  105. </view>
  106. </view>
  107. </scroll-view>
  108. </view>
  109. <view class="submit-btn" bindtap="submit" wx:if="{{!isFinished}}">完成课程</view>
  110. </view>