this.props.qiandaoxiangq(true,item.id):""}> +
{ item.name } @@ -95,18 +95,18 @@ class Teacherentry extends Component { isAdmin === true ? this.props.defaultActiveKey === "1" ?
{
From 97af74222e42d310a8030a61939990ad0eae436d Mon Sep 17 00:00:00 2001
From: cxt <853663049@qq.com>
Date: Mon, 16 Mar 2020 17:50:54 +0800
Subject: [PATCH 04/15] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app/jobs/student_join_attendance_record_job.rb | 2 +-
app/models/course_member.rb | 4 +++-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/app/jobs/student_join_attendance_record_job.rb b/app/jobs/student_join_attendance_record_job.rb
index ecc0b46a9..8840ae142 100644
--- a/app/jobs/student_join_attendance_record_job.rb
+++ b/app/jobs/student_join_attendance_record_job.rb
@@ -4,7 +4,7 @@ class StudentJoinAttendanceRecordJob < ApplicationJob
def perform(member_id)
member = CourseMember.find_by(id: member_id)
course = member&.course
- return if member.blank? || course.blank?
+ return if member.blank? || member.role != "STUDENT" || course.blank?
current_date = Date.current
current_end_time = Time.current.strftime("%H:%M:%S")
diff --git a/app/models/course_member.rb b/app/models/course_member.rb
index 21221e7e9..0a0433f6f 100644
--- a/app/models/course_member.rb
+++ b/app/models/course_member.rb
@@ -165,7 +165,9 @@ class CourseMember < ApplicationRecord
private
def create_attendance_record
- StudentJoinAttendanceRecordJob.perform_later(id)
+ if role == "STUDENT"
+ StudentJoinAttendanceRecordJob.perform_later(id)
+ end
end
end
From 7c357ff22041681cde5f138cf60197cf1cdc47c8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com>
Date: Mon, 16 Mar 2020 18:12:07 +0800
Subject: [PATCH 05/15] =?UTF-8?q?=E8=A7=86=E9=A2=91=E7=BB=9F=E8=AE=A1?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../modules/courses/signin/css/signincdi.css | 6 +
.../videostatistics/Videostatistics.js | 54 ++++----
.../component/Videostatisticscomtwo.js | 118 ++++++++++++++++++
.../component/Videostatisticslist.js | 2 +-
4 files changed, 157 insertions(+), 23 deletions(-)
create mode 100644 public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js
diff --git a/public/react/src/modules/courses/signin/css/signincdi.css b/public/react/src/modules/courses/signin/css/signincdi.css
index 5fe6a87cb..867dff40d 100644
--- a/public/react/src/modules/courses/signin/css/signincdi.css
+++ b/public/react/src/modules/courses/signin/css/signincdi.css
@@ -403,3 +403,9 @@
cursor: default;
}
+.font-14{
+ font-size: 14px !important;
+}
+.mr32{
+ margin-right: 32px;
+}
diff --git a/public/react/src/modules/courses/videostatistics/Videostatistics.js b/public/react/src/modules/courses/videostatistics/Videostatistics.js
index 93c9f57e6..0ea61c528 100644
--- a/public/react/src/modules/courses/videostatistics/Videostatistics.js
+++ b/public/react/src/modules/courses/videostatistics/Videostatistics.js
@@ -3,6 +3,7 @@ import axios from 'axios';
import '../signin/css/signincdi.css';
import Videostatisticscom from './component/Videostatisticscom';
import Videostatisticslist from './component/Videostatisticslist';
+import Videostatisticscomtwo from './component/Videostatisticscomtwo';
//在线学习
@@ -11,6 +12,8 @@ class Videostatistics extends Component{
super(props);
this.state={
watch_staticsdata:[],
+ tisticsbool:true,
+ tisid:0,
}
@@ -40,41 +43,48 @@ class Videostatistics extends Component{
});
}
-
+ tisticsbools=(bool,id)=>{
+ this.setState({
+ tisticsbool:bool,
+ tisid:id,
+ })
+ }
render(){
- let {watch_staticsdata}= this.state;
+ let {watch_staticsdata,tisticsbool}= this.state;
return(
this.props.statisticsy(false)}>
-
- 返回 this.props.statisticsy(false)}>
+
+ 返回
+ }
+
+
+
+ }
+
+
+
+
+