学习记录

main
king 1 year ago
parent b12641e1a7
commit ec5d995611
  1. 1
      src/components/video/video.tsx
  2. 1
      src/pages/business/videoInfo/components/course.tsx

@ -98,7 +98,6 @@ const HVideo: FC<HVideoOptions> = (opt: HVideoOptions) => {
Taro.useUnload(() => { Taro.useUnload(() => {
unique_ident.put(undefined, currentTime) unique_ident.put(undefined, currentTime)
unique_ident.remove()
unique_ident.upload().then() unique_ident.upload().then()
}) })

@ -33,6 +33,7 @@ const Course: FC<Props> = ({id, courseId, preview, curEnd}) => {
async function onEnded() { async function onEnded() {
const startRecording = unique_ident.get() const startRecording = unique_ident.get()
startRecording && await curriculum.curEnd(courseId, id, {...startRecording, duration: data?.duration!}) // 结束 startRecording && await curriculum.curEnd(courseId, id, {...startRecording, duration: data?.duration!}) // 结束
unique_ident.remove()
if (testId) { if (testId) {
if (preview) { // 预览 if (preview) { // 预览

Loading…
Cancel
Save