diff --git a/public/react/src/modules/courses/Video/Video.js b/public/react/src/modules/courses/Video/Video.js index 181c082ae..56ad1a60c 100644 --- a/public/react/src/modules/courses/Video/Video.js +++ b/public/react/src/modules/courses/Video/Video.js @@ -191,15 +191,21 @@ class Video extends Component { const CourseId = this.props.match.params.coursesId; const VID = this.props.match.params.videoId; - const login = this.props.user && this.props.user.login; + let login = this.props && this.props.user&&this.props.user.login;; + const _inputValue = videoId && this.getCopyText(videoId.file_url, videoId.cover_url); - const { admin, is_teacher, business, user_id } = this.props.user; + // const { admin, is_teacher, business, user_id } = this.props && this.props.user; + let admin = this.props && this.props.user&&this.props.user.admin;; + let business = this.props && this.props.user&&this.props.user.business;; + let user_id = this.props && this.props.user&&this.props.user.user_id;; + + const { videos, upload, uploadVideo, videoData, changePage, pageSize, page } = this.props; const operation = admin || business; - const { course_identity } = this.props.coursedata; + const { course_identity } = this.props && this.props.coursedata; const flagMove = parseInt(course_identity) < 5; return ( @@ -245,7 +251,7 @@ class Video extends Component {

播放数据从2020-03-13 24:00开始统计

- +
{ videos.map((item, key) => { diff --git a/public/react/src/modules/courses/Video/VideoIndex.js b/public/react/src/modules/courses/Video/VideoIndex.js index f52f54859..7a974c582 100644 --- a/public/react/src/modules/courses/Video/VideoIndex.js +++ b/public/react/src/modules/courses/Video/VideoIndex.js @@ -245,7 +245,7 @@ class VideoIndex extends Component{ const { videos , upload , videoData , type , liveData , lives , page , liveVisible , isSpining , liveId , otherLinkVisible,statistics } = this.state; const { coursesId , videoId }=this.props.match.params; let course_identity = this.props&&this.props.coursedata; - let is_teacher = this.props&&this.props.user; + let is_teacher=this.props&&this.props.user&&this.props.user.is_teacher; const flag = parseInt(course_identity) < 5; const newOperation = flag; const new_upload = flag && (is_teacher && this.props.checkIfProfessionalCertification());