From 1a13d511bd2470eeb38162af2849e7c1c3d38087 Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Tue, 17 Mar 2020 09:47:26 +0800 Subject: [PATCH 01/21] =?UTF-8?q?=E7=9F=AD=E4=BF=A1=E9=80=9A=E7=9F=A5?= =?UTF-8?q?=E7=9A=84=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/subjects_controller.rb | 2 +- lib/educoder/sms.rb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/controllers/subjects_controller.rb b/app/controllers/subjects_controller.rb index c78eff35a..c5cae99c4 100644 --- a/app/controllers/subjects_controller.rb +++ b/app/controllers/subjects_controller.rb @@ -244,7 +244,7 @@ class SubjectsController < ApplicationController @subject.update_attributes(public: 1) ApplyAction.create(container_type: "ApplySubject", container_id: @subject.id, user_id: current_user.id, status: 0) begin - Educoder::Sms.send(mobile: '18711011226', send_type:'publish_subject' , name: '管理员') + Educoder::Sms.send(mobile: '17347001317', send_type:'publish_subject' , name: '管理员') rescue => e uid_logger_error("发送验证码出错: #{e}") end diff --git a/lib/educoder/sms.rb b/lib/educoder/sms.rb index a98ebf493..39c48c1f0 100644 --- a/lib/educoder/sms.rb +++ b/lib/educoder/sms.rb @@ -21,7 +21,7 @@ module Educoder def self.notify_admin(opt) opt[:name] = '管理员' - opt[:mobile] = ENV['NOTIFY_ADMIN_PHONE'] || EduSetting.get('notify_admin_phone') || '18711085785' + opt[:mobile] = ENV['NOTIFY_ADMIN_PHONE'] || EduSetting.get('notify_admin_phone') || '18670760309' send(opt) end @@ -49,7 +49,7 @@ module Educoder elsif send_type == "apply_pro_certification" || send_type == "apply_auth" params['text'] = "【Edu实训】亲爱的#{name},有新的#{send_type == 'apply_pro_certification'?'职业':'实名'}认证申请,请尽快处理" elsif send_type == "publish_subject" ||send_type == "publish_shixun"|| send_type == "user_apply_auth" || send_type == "discuss" - params['mobile'] = EduSetting.get('subject_shixun_notify_phone') || '18711011226' if send_type == "publish_subject" || send_type == "publish_shixun" + params['mobile'] = EduSetting.get('subject_shixun_notify_phone') || '17347001317' if send_type == "publish_subject" || send_type == "publish_shixun" params['text'] = "【Edu实训】亲爱的#{name},有新的#{send_type == 'publish_subject'?'实训路径':(send_type == 'publish_shixun' ? '实训' : (send_type == 'discuss' ? '实训评论':'试用'))}申请发布,请尽快处理" elsif send_type == 'join_course_multi_role' params['text'] = "【Edu实训】亲爱的#{user_name},您的课堂#{name}有助教或者教师申请加入,请尽快审核" From 5107b474bd01f00b804cc94dfff78fa0307c8ea4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Tue, 17 Mar 2020 10:05:59 +0800 Subject: [PATCH 02/21] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/react/src/AppConfig.js | 4 +-- .../src/modules/courses/Video/VideoIndex.js | 9 ++++-- .../component/Videostatisticscomtwo.js | 32 ++++++++++++++----- .../component/Videostatisticslist.js | 2 +- 4 files changed, 34 insertions(+), 13 deletions(-) diff --git a/public/react/src/AppConfig.js b/public/react/src/AppConfig.js index fee6eb724..332e8ea73 100644 --- a/public/react/src/AppConfig.js +++ b/public/react/src/AppConfig.js @@ -42,11 +42,11 @@ if (isDev) { window.location.search.indexOf('debug=a') != -1 ? 'admin' : parsed.debug || 'admin' } // 超管 -debugType="admin"; +// debugType="admin"; // 老师 // debugType="teacher"; // 学生 -// debugType="student"; +debugType="student"; diff --git a/public/react/src/modules/courses/Video/VideoIndex.js b/public/react/src/modules/courses/Video/VideoIndex.js index e2b3a0841..d808ee787 100644 --- a/public/react/src/modules/courses/Video/VideoIndex.js +++ b/public/react/src/modules/courses/Video/VideoIndex.js @@ -12,7 +12,7 @@ import Videostatistics from '../videostatistics/Videostatistics'; import './video.css'; import '../css/Courses.css'; import '../publicNav/nav.css'; - +import Videostatisticscomtwo from '../videostatistics/component/Videostatisticscomtwo'; const PAGE_SIZE = 15; const LIVE_PAGE_SIZE = 10; const $ = window.$; @@ -378,7 +378,12 @@ class VideoIndex extends Component { : - this.statisticsy(b)}> + ( + isAdmin? + this.statisticsy(b)}> + : + + ) } { statistics === false ? diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js index 637a2a0fd..51673aa38 100644 --- a/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js +++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js @@ -126,6 +126,7 @@ class Videostatisticscomtwo extends Component { course_groups: [], fbbool: false, groupsid: null, + none_group_member_count:0, } } @@ -164,9 +165,9 @@ class Videostatisticscomtwo extends Component { let url = `/courses/${CourseId}/course_groups.json`; axios.get(url).then((response) => { if (response) { - console.log("分班"); - console.log("response"); - console.log(response); + // console.log("分班"); + // console.log("response"); + // console.log(response); this.setState({ course_groups: response.data.course_groups, current_group_id: response.data.current_group_id, @@ -202,7 +203,7 @@ class Videostatisticscomtwo extends Component { number: (parseInt(this.state.page) - 1) * parseInt(this.state.limit) + (i + 1), user_name: response.data.data[i].user_name, is_finished: response.data.data[i].is_finished, - total_duration: response.data.data[i].total_duration?formatSeconds(response.data.data[i].total_duration):0, + total_duration: response.data.data[i].total_duration, feq: response.data.data[i].feq, start_at: response.data.data[i].start_at, end_at: response.data.data[i].end_at, @@ -398,7 +399,7 @@ class Videostatisticscomtwo extends Component { render() { let {loading, data, page, limit, members_count, columnsstu, fbbool, course_groups} = this.state; - const isAdmin = this.props.isAdmin(); + const isAdmin = this.props&& this.props.isAdmin(); const menu = ( @@ -423,6 +424,16 @@ class Videostatisticscomtwo extends Component { : "" } + { + this.state.none_group_member_count&&this.state.none_group_member_count>0? + + this.setcourse_groups(0)}> +

未分班

+
+
+ : + "" + }
); return ( @@ -435,9 +446,14 @@ class Videostatisticscomtwo extends Component { color: "#5091FF", lineHeight: "42px", }}> -
this.props.tisticsbools(false, null)}> - 视频统计总览 -
+ { + isAdmin === true ? +
this.props.tisticsbools(false, null)}> + 视频统计总览 +
+ :"" + } + { isAdmin === true ?
this.fenbanone()}> diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js index 4a0667e5b..7fe655aeb 100644 --- a/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js +++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js @@ -152,7 +152,7 @@ class Videostatisticslist extends Component { number: (parseInt(this.state.page) - 1) * parseInt(this.state.limit) + (i + 1), title: response.data.videos[i].title, people_num: response.data.videos[i].people_num, - total_time: response.data.videos[i].total_time?formatSeconds(response.data.videos[i].total_time):0, + total_time: response.data.videos[i].total_time, user_name: response.data.videos[i].user_name, id: response.data.videos[i].id, }) From 5a50cfb92aa988b4dfde777c16b8633f6273c213 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Tue, 17 Mar 2020 10:12:43 +0800 Subject: [PATCH 03/21] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/react/src/AppConfig.js | 4 ++-- .../modules/courses/videostatistics/Videostatistics.js | 10 ++++++---- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/public/react/src/AppConfig.js b/public/react/src/AppConfig.js index 332e8ea73..fee6eb724 100644 --- a/public/react/src/AppConfig.js +++ b/public/react/src/AppConfig.js @@ -42,11 +42,11 @@ if (isDev) { window.location.search.indexOf('debug=a') != -1 ? 'admin' : parsed.debug || 'admin' } // 超管 -// debugType="admin"; +debugType="admin"; // 老师 // debugType="teacher"; // 学生 -debugType="student"; +// debugType="student"; diff --git a/public/react/src/modules/courses/videostatistics/Videostatistics.js b/public/react/src/modules/courses/videostatistics/Videostatistics.js index 52d69b0fb..ddd8c8deb 100644 --- a/public/react/src/modules/courses/videostatistics/Videostatistics.js +++ b/public/react/src/modules/courses/videostatistics/Videostatistics.js @@ -62,15 +62,17 @@ class Videostatistics extends Component{
-
-

this.props.statisticsy(false)}> - -

返回

+ +

+ this.props.statisticsy(false)}> +

this.props.statisticsy(false)}>返回

+
From 5bcc9fbb41bca7b2d3b0d246b9c1f4a67ea7476e Mon Sep 17 00:00:00 2001 From: anke1460 Date: Tue, 17 Mar 2020 10:13:46 +0800 Subject: [PATCH 04/21] =?UTF-8?q?=E8=AF=BE=E5=A0=82=E8=A7=86=E9=A2=91?= =?UTF-8?q?=E9=99=90=E5=AE=9A=E7=BB=9F=E8=AE=A1=E5=AD=A6=E7=94=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/course_videos_controller.rb | 5 ++--- app/controllers/courses_controller.rb | 11 ++++++++--- app/views/course_videos/watch_histories.json.jbuilder | 2 +- app/views/courses/own_watch_histories.json.jbuilder | 2 +- app/views/courses/watch_video_histories.json.jbuilder | 2 +- 5 files changed, 13 insertions(+), 9 deletions(-) diff --git a/app/controllers/course_videos_controller.rb b/app/controllers/course_videos_controller.rb index c5e0358cd..fe01c6226 100644 --- a/app/controllers/course_videos_controller.rb +++ b/app/controllers/course_videos_controller.rb @@ -26,14 +26,13 @@ class CourseVideosController < ApplicationController @watch_course_videos = course_video.watch_course_videos.joins(" JOIN watch_video_histories ON watch_video_histories.watch_course_video_id = watch_course_videos.id + JOIN course_members ON course_members.user_id = watch_course_videos.user_id AND course_members.course_id = #{@course.id} AND role = 4 ").group("watch_video_histories.watch_course_video_id").where("watch_course_videos.end_at IS NOT NULL").select("watch_course_videos.id") @count = @watch_course_videos.count.count if params[:group_id].present? - @watch_course_videos = @watch_course_videos.joins(" - JOIN course_members ON course_members.user_id = watch_course_videos.user_id AND course_members.course_id = #{@course.id} - ").where("course_members.course_group_id = ?", params[:group_id]) + @watch_course_videos = @watch_course_videos.where("course_members.course_group_id = ?", params[:group_id]) end @watch_course_videos = @watch_course_videos.select("count(watch_video_histories.id) AS freq, watch_course_videos.*") diff --git a/app/controllers/courses_controller.rb b/app/controllers/courses_controller.rb index bdb5daae1..909f1c11d 100644 --- a/app/controllers/courses_controller.rb +++ b/app/controllers/courses_controller.rb @@ -1494,6 +1494,7 @@ class CoursesController < ApplicationController SELECT watch_course_videos.course_video_id, SUM(watch_course_videos.total_duration) AS time, COUNT(watch_course_videos.course_video_id) AS num FROM watch_course_videos JOIN course_videos ON course_videos.id = watch_course_videos.course_video_id AND watch_course_videos.end_at IS NOT NULL + JOIN course_members ON course_members.user_id = watch_course_videos.user_id AND course_members.course_id = #{@course.id} AND role = 4 WHERE course_videos.course_id = #{@course.id} GROUP BY watch_course_videos.course_video_id ) AS hisotries ON hisotries.course_video_id = course_videos.id").select("course_videos.id") @@ -1523,6 +1524,7 @@ class CoursesController < ApplicationController SELECT watch_course_videos.course_video_id, COUNT(watch_course_videos.course_video_id) AS num FROM watch_course_videos JOIN course_videos ON course_videos.id = watch_course_videos.course_video_id + JOIN course_members ON course_members.user_id = watch_course_videos.user_id AND course_members.course_id = #{@course.id} AND role = 4 WHERE course_videos.course_id = #{@course.id} AND watch_course_videos.user_id = #{current_user.id} AND watch_course_videos.end_at IS NOT NULL GROUP BY watch_course_videos.course_video_id ) AS hisotries ON hisotries.course_video_id = course_videos.id").select("course_videos.id") @@ -1543,9 +1545,12 @@ class CoursesController < ApplicationController # 课堂视频的统计总览 def watch_statics - @total_duration = @course.course_videos.joins(:watch_course_videos).sum(:total_duration).round(2) - @frequencies = @course.course_videos.joins([watch_course_videos: :watch_video_histories]).count(:id) - @people_num = @course.course_videos.joins(:watch_course_videos).count(:id) + course_videos = @course.course_videos.joins(:watch_course_videos).joins(" + JOIN course_members ON course_members.user_id = watch_course_videos.user_id AND course_members.course_id = #{@course.id} AND role = 4 + ") + @total_duration = course_videos.sum(:total_duration).round(0) + @frequencies = course_videos.joins("JOIN watch_video_histories ON watch_course_videos.id = watch_video_histories.watch_course_video_id").count(:id) + @people_num = course_videos.count(:id) render json: { total_duration: @total_duration, freq: @frequencies, diff --git a/app/views/course_videos/watch_histories.json.jbuilder b/app/views/course_videos/watch_histories.json.jbuilder index 705e2d6b7..2babab5d0 100644 --- a/app/views/course_videos/watch_histories.json.jbuilder +++ b/app/views/course_videos/watch_histories.json.jbuilder @@ -2,7 +2,7 @@ json.data do json.array! @watch_course_videos do |d| json.user_name d.user&.real_name json.is_finished d.is_finished ? true : false - json.total_duration d.total_duration.round(2) + json.total_duration d.total_duration.round(0) json.feq d['freq'] json.start_at d.start_at.to_s json.end_at d.end_at.to_s diff --git a/app/views/courses/own_watch_histories.json.jbuilder b/app/views/courses/own_watch_histories.json.jbuilder index 982939d9c..cc3b31eae 100644 --- a/app/views/courses/own_watch_histories.json.jbuilder +++ b/app/views/courses/own_watch_histories.json.jbuilder @@ -3,7 +3,7 @@ json.data do json.title d.title json.user_name @current_user&.real_name json.is_finished d.is_finished ? true : false - json.total_duration d.total_duration.round(2) + json.total_duration d.total_duration.round(0) json.freq d['freq'] json.start_at d.start_at.to_s json.end_at d.end_at.to_s diff --git a/app/views/courses/watch_video_histories.json.jbuilder b/app/views/courses/watch_video_histories.json.jbuilder index 207b9029b..8efab4a20 100644 --- a/app/views/courses/watch_video_histories.json.jbuilder +++ b/app/views/courses/watch_video_histories.json.jbuilder @@ -4,7 +4,7 @@ json.videos do json.title v.title json.user_name v.user&.real_name json.people_num v['people_num'] - json.total_time v['total_time'] + json.total_time v['total_time'].round(0) end end json.count @count \ No newline at end of file From 6e7bce87f4f408dfa302b849d75bc07b9f753fe3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Tue, 17 Mar 2020 10:45:24 +0800 Subject: [PATCH 05/21] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/modules/courses/Video/VideoIndex.js | 2 +- .../courses/videostatistics/Videostatistics.js | 10 ++++++---- .../component/Videostatisticscomtwo.js | 18 ++++++++++++++---- .../component/Videostatisticslist.js | 4 ++-- 4 files changed, 23 insertions(+), 11 deletions(-) diff --git a/public/react/src/modules/courses/Video/VideoIndex.js b/public/react/src/modules/courses/Video/VideoIndex.js index d808ee787..787263cb0 100644 --- a/public/react/src/modules/courses/Video/VideoIndex.js +++ b/public/react/src/modules/courses/Video/VideoIndex.js @@ -382,7 +382,7 @@ class VideoIndex extends Component { isAdmin? this.statisticsy(b)}> : - + ) } { diff --git a/public/react/src/modules/courses/videostatistics/Videostatistics.js b/public/react/src/modules/courses/videostatistics/Videostatistics.js index ddd8c8deb..f497b3ca6 100644 --- a/public/react/src/modules/courses/videostatistics/Videostatistics.js +++ b/public/react/src/modules/courses/videostatistics/Videostatistics.js @@ -14,6 +14,7 @@ class Videostatistics extends Component{ watch_staticsdata:[], tisticsbool:false, tisid:null, + mytitle:"" } @@ -43,16 +44,17 @@ class Videostatistics extends Component{ }); } - tisticsbools=(bool,id)=>{ + tisticsbools=(bool,id,mytitle)=>{ this.setState({ tisticsbool:bool, tisid:id, + mytitle:mytitle }) } render(){ - let {watch_staticsdata,tisticsbool,tisid}= this.state; + let {watch_staticsdata,tisticsbool,tisid,mytitle}= this.state; return( @@ -79,13 +81,13 @@ class Videostatistics extends Component{
- this.tisticsbools(b,id)}> + this.tisticsbools(b,id,t)}>
: - this.tisticsbools(b,id)}> + this.tisticsbools(b,id,t)}> }
diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js index 51673aa38..b64cd06ac 100644 --- a/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js +++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js @@ -207,6 +207,7 @@ class Videostatisticscomtwo extends Component { feq: response.data.data[i].feq, start_at: response.data.data[i].start_at, end_at: response.data.data[i].end_at, + title: response.data.data[i].title, }) } @@ -436,12 +437,21 @@ class Videostatisticscomtwo extends Component { } ); + + let mytitle=""; + if(isAdmin){ + mytitle=this.props&&this.props.mytitle; + + }else{ + mytitle=this.state.data[0].title; + } + return (
-
视频名称视频名称…
+
{mytitle}
分班 { fbbool === true ? - + : - + } @@ -488,7 +498,7 @@ class Videostatisticscomtwo extends Component { } -
+
{ data.length === 0 ?
( - this.props.tisticsbools(true,record.id)}>详情 + this.props.tisticsbools(true,record.id,record.title)}>详情 ), } ], @@ -266,7 +266,7 @@ class Videostatisticslist extends Component { } -
+
{ data.length===0?
Date: Tue, 17 Mar 2020 10:46:09 +0800 Subject: [PATCH 06/21] =?UTF-8?q?=E8=AF=BE=E5=A0=82=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=BB=9F=E8=AE=A1=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/admins/courses_controller.rb | 4 ++-- app/models/course.rb | 4 ++++ app/views/admins/courses/index.xlsx.axlsx | 8 ++++++-- app/views/admins/courses/shared/_list.html.erb | 14 +++++++++----- app/views/admins/courses/shared/_td.html.erb | 6 +++++- 5 files changed, 26 insertions(+), 10 deletions(-) diff --git a/app/controllers/admins/courses_controller.rb b/app/controllers/admins/courses_controller.rb index 518054e12..c1093d9e7 100644 --- a/app/controllers/admins/courses_controller.rb +++ b/app/controllers/admins/courses_controller.rb @@ -7,13 +7,13 @@ class Admins::CoursesController < Admins::BaseController courses = Admins::CourseQuery.call(params) @ended_courses = courses.where(is_end: 1).size @processed_courses = courses.where(is_end: 0).size - @courses = paginate courses.includes(:school, :students, :attachments, :homework_commons, teacher: :user_extension) + @courses = paginate courses.includes(:school, :students, :teacher_course_members, :informs, :course_videos, :attachments, :homework_commons, teacher: :user_extension) respond_to do |format| format.js format.html format.xlsx do - @courses = courses.includes(:school, :students, :attachments, :homework_commons, :course_acts, teacher: :user_extension) + @courses = courses.includes(:school, :students, :teacher_course_members, :informs, :course_videos, :attachments, :homework_commons, :course_activities, teacher: :user_extension) filename = "课堂列表_#{Time.current.strftime('%Y%m%d%H%M%S')}.xlsx" render xlsx: 'index', filename: filename end diff --git a/app/models/course.rb b/app/models/course.rb index a0daaea22..cb8e3560d 100644 --- a/app/models/course.rb +++ b/app/models/course.rb @@ -406,6 +406,10 @@ class Course < ApplicationRecord homework_commons.select{|homework| homework.homework_type == type}.size end + def student_works_count + StudentWork.joins(:homework_common).where(homework_commons: {course_id: id}).where("work_status > 0").size + end + private #创建课程后,给该用户发送消息 diff --git a/app/views/admins/courses/index.xlsx.axlsx b/app/views/admins/courses/index.xlsx.axlsx index 7cab54482..cb8ab0610 100644 --- a/app/views/admins/courses/index.xlsx.axlsx +++ b/app/views/admins/courses/index.xlsx.axlsx @@ -3,17 +3,21 @@ wb = xlsx_package.workbook wb.styles do |s| blue_cell = s.add_style :bg_color => "FAEBDC", :sz => 10,:height => 25,:b => true, :border => { :style => :thin, :color =>"000000" },:alignment => {wrap_text: true,:horizontal => :center,:vertical => :center} wb.add_worksheet(name: "课堂列表") do |sheet| - sheet.add_row %w(ID 课堂名称 成员 资源 普通作业 分组作业 实训作业 试卷 评测次数 私有 状态 单位 创建者 创建时间 动态时间), :height => 25,:style => blue_cell + sheet.add_row %w(ID 课堂名称 老师 学生 资源 公告 视频 普通作业 分组作业 实训作业 作品数 试卷 评测次数 私有 状态 单位 创建者 创建时间 动态时间), :height => 25,:style => blue_cell @courses.each do |course| data = [ course.id, course.name, - course.course_members_count, + course.teacher_course_members.size, + course.students.size, get_attachment_count(course, 0), + course.informs.size, + course.course_videos.size, course.course_homework_count(1), course.course_homework_count(3), course.course_homework_count(4), + course.student_works_count, course.exercises_count, course.evaluate_count, course.is_public == 1 ? "--" : "√", diff --git a/app/views/admins/courses/shared/_list.html.erb b/app/views/admins/courses/shared/_list.html.erb index 4105c8153..47839c549 100644 --- a/app/views/admins/courses/shared/_list.html.erb +++ b/app/views/admins/courses/shared/_list.html.erb @@ -3,18 +3,22 @@ 序号 ID - 课堂名称 - 成员 + 课堂名称 + 老师 + 学生 资源 + 公告 + 视频 普通作业 分组作业 实训作业 + 作品数 试卷 评测次数 私有 - 状态 - 单位 - 创建者 + 状态 + 单位 + 创建者 <%= sort_tag('创建时间', name: 'created_at', path: admins_courses_path) %> 首页 邮件通知 diff --git a/app/views/admins/courses/shared/_td.html.erb b/app/views/admins/courses/shared/_td.html.erb index 7b72179da..397a69aae 100644 --- a/app/views/admins/courses/shared/_td.html.erb +++ b/app/views/admins/courses/shared/_td.html.erb @@ -3,11 +3,15 @@ <%= link_to(course.name, "/classrooms/#{course.id}", target: '_blank') %> -<%= course.course_members_count %> +<%= course.teacher_course_members.size %> +<%= course.students.size %> <%= get_attachment_count(course, 0) %> +<%= course.informs.size %> +<%= course.course_videos.size %> <%= course.course_homework_count("normal") %> <%= course.course_homework_count("group") %> <%= course.course_homework_count("practice") %> +<%= course.student_works_count %> <%= course.exercises_count %> <%= course.evaluate_count %> <%= course.is_public == 1 ? "--" : "√" %> From 6a748ce7b19b684b782d86f8cb6cdf53128199ad Mon Sep 17 00:00:00 2001 From: anke1460 Date: Tue, 17 Mar 2020 10:51:33 +0800 Subject: [PATCH 07/21] =?UTF-8?q?=E8=AF=BE=E5=A0=82=E8=A7=86=E9=A2=91?= =?UTF-8?q?=E7=BB=9F=E8=AE=A1=E5=8E=BB=E6=8E=89=E6=9C=AA=E5=BC=80=E5=A7=8B?= =?UTF-8?q?=E8=AE=B0=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/courses_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/courses_controller.rb b/app/controllers/courses_controller.rb index 909f1c11d..f6868cfa2 100644 --- a/app/controllers/courses_controller.rb +++ b/app/controllers/courses_controller.rb @@ -1547,7 +1547,7 @@ class CoursesController < ApplicationController def watch_statics course_videos = @course.course_videos.joins(:watch_course_videos).joins(" JOIN course_members ON course_members.user_id = watch_course_videos.user_id AND course_members.course_id = #{@course.id} AND role = 4 - ") + ").where("watch_course_videos.end_at IS NOT NULL") @total_duration = course_videos.sum(:total_duration).round(0) @frequencies = course_videos.joins("JOIN watch_video_histories ON watch_course_videos.id = watch_video_histories.watch_course_video_id").count(:id) @people_num = course_videos.count(:id) From fdef75d144baa4593fb8794b6aefc87ea5305e22 Mon Sep 17 00:00:00 2001 From: daiao <358551898@qq.com> Date: Tue, 17 Mar 2020 11:03:28 +0800 Subject: [PATCH 08/21] =?UTF-8?q?=E9=83=A8=E9=97=A8=E5=90=8D=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/admins/courses_controller.rb | 2 +- app/views/admins/courses/index.xlsx.axlsx | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/controllers/admins/courses_controller.rb b/app/controllers/admins/courses_controller.rb index c1093d9e7..4f82d5d58 100644 --- a/app/controllers/admins/courses_controller.rb +++ b/app/controllers/admins/courses_controller.rb @@ -13,7 +13,7 @@ class Admins::CoursesController < Admins::BaseController format.js format.html format.xlsx do - @courses = courses.includes(:school, :students, :teacher_course_members, :informs, :course_videos, :attachments, :homework_commons, :course_activities, teacher: :user_extension) + @courses = courses.includes(:school, :students, :teacher_course_members, :informs, :course_videos, :attachments, :homework_commons, :course_activities, teacher: [user_extension: :department]) filename = "课堂列表_#{Time.current.strftime('%Y%m%d%H%M%S')}.xlsx" render xlsx: 'index', filename: filename end diff --git a/app/views/admins/courses/index.xlsx.axlsx b/app/views/admins/courses/index.xlsx.axlsx index cb8ab0610..3185f21be 100644 --- a/app/views/admins/courses/index.xlsx.axlsx +++ b/app/views/admins/courses/index.xlsx.axlsx @@ -3,7 +3,7 @@ wb = xlsx_package.workbook wb.styles do |s| blue_cell = s.add_style :bg_color => "FAEBDC", :sz => 10,:height => 25,:b => true, :border => { :style => :thin, :color =>"000000" },:alignment => {wrap_text: true,:horizontal => :center,:vertical => :center} wb.add_worksheet(name: "课堂列表") do |sheet| - sheet.add_row %w(ID 课堂名称 老师 学生 资源 公告 视频 普通作业 分组作业 实训作业 作品数 试卷 评测次数 私有 状态 单位 创建者 创建时间 动态时间), :height => 25,:style => blue_cell + sheet.add_row %w(ID 课堂名称 老师 学生 资源 公告 视频 普通作业 分组作业 实训作业 作品数 试卷 评测次数 私有 状态 单位 部门 创建者 创建时间 动态时间), :height => 25,:style => blue_cell @courses.each do |course| data = [ @@ -23,6 +23,7 @@ wb.styles do |s| course.is_public == 1 ? "--" : "√", course.is_end ? "已结束" : "正在进行", course.school&.name, + course.teacher&.department_name course.teacher&.real_name, course.created_at&.strftime('%Y-%m-%d %H:%M'), course.max_activity_time ? course.max_activity_time&.strftime('%Y-%m-%d %H:%M') : "--" From 3fca3d83244b97142b38978497663c6c33312978 Mon Sep 17 00:00:00 2001 From: daiao <358551898@qq.com> Date: Tue, 17 Mar 2020 11:13:11 +0800 Subject: [PATCH 09/21] =?UTF-8?q?=E5=AF=BC=E5=87=BA=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/admins/courses/index.xlsx.axlsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/admins/courses/index.xlsx.axlsx b/app/views/admins/courses/index.xlsx.axlsx index 3185f21be..22cf58e4d 100644 --- a/app/views/admins/courses/index.xlsx.axlsx +++ b/app/views/admins/courses/index.xlsx.axlsx @@ -23,7 +23,7 @@ wb.styles do |s| course.is_public == 1 ? "--" : "√", course.is_end ? "已结束" : "正在进行", course.school&.name, - course.teacher&.department_name + course.teacher&.department_name, course.teacher&.real_name, course.created_at&.strftime('%Y-%m-%d %H:%M'), course.max_activity_time ? course.max_activity_time&.strftime('%Y-%m-%d %H:%M') : "--" From 34df3fd1c06e8a1302df83715ed08ce1071f06fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Tue, 17 Mar 2020 11:21:29 +0800 Subject: [PATCH 10/21] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/courses/signin/css/signincdi.css | 1 + .../videostatistics/Videostatistics.js | 13 +---------- .../component/Videostatisticscom.js | 4 ++++ .../component/Videostatisticscomtwo.js | 22 +++++++++++++++---- .../component/Videostatisticslist.js | 2 +- 5 files changed, 25 insertions(+), 17 deletions(-) diff --git a/public/react/src/modules/courses/signin/css/signincdi.css b/public/react/src/modules/courses/signin/css/signincdi.css index a7fbbb20a..9416de345 100644 --- a/public/react/src/modules/courses/signin/css/signincdi.css +++ b/public/react/src/modules/courses/signin/css/signincdi.css @@ -440,3 +440,4 @@ .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 f497b3ca6..ba4891b2c 100644 --- a/public/react/src/modules/courses/videostatistics/Videostatistics.js +++ b/public/react/src/modules/courses/videostatistics/Videostatistics.js @@ -64,19 +64,8 @@ class Videostatistics extends Component{
-
-

- this.props.statisticsy(false)}> -

this.props.statisticsy(false)}>返回

-

- - -
- + this.props.statisticsy(b)}> diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js index 1111b6509..3c12ff424 100644 --- a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js +++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js @@ -35,6 +35,10 @@ class Videostatisticscom extends Component { }}>
+

this.props.statisticsy(false)} > + this.props.statisticsy(false)}> +

this.props.statisticsy(false)}>返回

+

视频统计总览
播放数据从{this.props.watch_staticsdata&&this.props.watch_staticsdata.begin_at?this.props.watch_staticsdata.begin_at:0}开始统计
diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js index b64cd06ac..8c4025143 100644 --- a/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js +++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticscomtwo.js @@ -203,7 +203,7 @@ class Videostatisticscomtwo extends Component { number: (parseInt(this.state.page) - 1) * parseInt(this.state.limit) + (i + 1), user_name: response.data.data[i].user_name, is_finished: response.data.data[i].is_finished, - total_duration: response.data.data[i].total_duration, + total_duration: response.data.data[i].total_duration?formatSeconds(response.data.data[i].total_duration):0, feq: response.data.data[i].feq, start_at: response.data.data[i].start_at, end_at: response.data.data[i].end_at, @@ -291,10 +291,24 @@ class Videostatisticscomtwo extends Component { } } else { - data = { - id: CourseId, - page: this.state.page + try { + if(id!==null&&id===0){ + data = { + id: CourseId, + page: this.state.page, + group_id: id + } + }else{ + data = { + id: CourseId, + page: this.state.page + } + } + + }catch (e) { + } + } this.getdatas(data); } diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js index fa24c9c32..a30d872de 100644 --- a/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js +++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js @@ -152,7 +152,7 @@ class Videostatisticslist extends Component { number: (parseInt(this.state.page) - 1) * parseInt(this.state.limit) + (i + 1), title: response.data.videos[i].title, people_num: response.data.videos[i].people_num, - total_time: response.data.videos[i].total_time, + total_time: response.data.videos[i].total_time?formatSeconds(response.data.videos[i].total_time):0, user_name: response.data.videos[i].user_name, id: response.data.videos[i].id, }) From fcdd2da413c95169994f53e30a21e66adee702e7 Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Tue, 17 Mar 2020 11:36:07 +0800 Subject: [PATCH 11/21] =?UTF-8?q?=E5=AF=BC=E5=87=BA=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/admins/courses/index.xlsx.axlsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/views/admins/courses/index.xlsx.axlsx b/app/views/admins/courses/index.xlsx.axlsx index cb8ab0610..f21141de0 100644 --- a/app/views/admins/courses/index.xlsx.axlsx +++ b/app/views/admins/courses/index.xlsx.axlsx @@ -14,9 +14,9 @@ wb.styles do |s| get_attachment_count(course, 0), course.informs.size, course.course_videos.size, - course.course_homework_count(1), - course.course_homework_count(3), - course.course_homework_count(4), + course.course_homework_count("normal"), + course.course_homework_count("group"), + course.course_homework_count("practice"), course.student_works_count, course.exercises_count, course.evaluate_count, From f987bcd5e2e882ac186bd501b6c8d354b0250721 Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Tue, 17 Mar 2020 11:41:30 +0800 Subject: [PATCH 12/21] =?UTF-8?q?=E8=AF=BE=E5=A0=82=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E5=AF=BC=E5=87=BA=E5=A2=9E=E5=8A=A0=E7=BB=9F=E8=AE=A1=E6=95=B0?= =?UTF-8?q?=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/models/course.rb | 5 +++++ app/views/admins/courses/index.xlsx.axlsx | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/app/models/course.rb b/app/models/course.rb index cb8e3560d..d4d5387d5 100644 --- a/app/models/course.rb +++ b/app/models/course.rb @@ -406,6 +406,11 @@ class Course < ApplicationRecord homework_commons.select{|homework| homework.homework_type == type}.size end + # 课堂作业数 + def published_course_homework_count type + homework_commons.select{|homework| homework.homework_type == type && homework.publish_time.present? && homework.publish_time <= Time.now}.size + end + def student_works_count StudentWork.joins(:homework_common).where(homework_commons: {course_id: id}).where("work_status > 0").size end diff --git a/app/views/admins/courses/index.xlsx.axlsx b/app/views/admins/courses/index.xlsx.axlsx index 9690eaa05..bc6581972 100644 --- a/app/views/admins/courses/index.xlsx.axlsx +++ b/app/views/admins/courses/index.xlsx.axlsx @@ -3,7 +3,7 @@ wb = xlsx_package.workbook wb.styles do |s| blue_cell = s.add_style :bg_color => "FAEBDC", :sz => 10,:height => 25,:b => true, :border => { :style => :thin, :color =>"000000" },:alignment => {wrap_text: true,:horizontal => :center,:vertical => :center} wb.add_worksheet(name: "课堂列表") do |sheet| - sheet.add_row %w(ID 课堂名称 老师 学生 资源 公告 视频 普通作业 分组作业 实训作业 作品数 试卷 评测次数 私有 状态 单位 部门 创建者 创建时间 动态时间), :height => 25,:style => blue_cell + sheet.add_row %w(ID 课堂名称 老师 学生 资源 公告 视频 普通作业 分组作业 实训作业 实训作业已发布数 作品数 试卷 评测次数 私有 状态 单位 部门 创建者 创建时间 动态时间), :height => 25,:style => blue_cell @courses.each do |course| data = [ @@ -17,6 +17,7 @@ wb.styles do |s| course.course_homework_count("normal"), course.course_homework_count("group"), course.course_homework_count("practice"), + course.published_course_homework_count("practice"), course.student_works_count, course.exercises_count, course.evaluate_count, From 25e6feccec7855f60ee17d6bf44b9b753a144056 Mon Sep 17 00:00:00 2001 From: anke1460 Date: Tue, 17 Mar 2020 11:43:14 +0800 Subject: [PATCH 13/21] =?UTF-8?q?fix=20=E8=A7=86=E9=A2=91=E7=9C=8B?= =?UTF-8?q?=E5=AE=8C=E6=B2=A1=E6=A0=87=E8=AE=B0=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/services/create_watch_video_service.rb | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/app/services/create_watch_video_service.rb b/app/services/create_watch_video_service.rb index 0f1b32814..5a3813571 100644 --- a/app/services/create_watch_video_service.rb +++ b/app/services/create_watch_video_service.rb @@ -33,12 +33,10 @@ class CreateWatchVideoService < ApplicationService if watch_course_video.present? watch_course_video.total_duration = watch_course_video.watch_video_histories.sum(:total_duration) watch_course_video.end_at = current_time - if !watch_course_video.is_finished && watch_course_video.watch_duration < params[:watch_duration] + if !watch_course_video.is_finished # 更新课程视频的时长及是否看完状态 - watch_course_video.watch_duration = params[:watch_duration] - if params[:ed].present? - watch_course_video.is_finished = watch_course_video.total_duration >= watch_course_video.duration - end + watch_course_video.watch_duration = params[:watch_duration] if watch_course_video.watch_duration < params[:watch_duration] + watch_course_video.is_finished = watch_course_video.total_duration >= watch_course_video.duration if params[:ed].present? end watch_course_video.save! end From b4703c01eb7b3efa33365834c8dccce33be9f57c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Tue, 17 Mar 2020 11:46:09 +0800 Subject: [PATCH 14/21] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/modules/courses/signin/css/signincdi.css | 13 ++++++++++++- .../component/Videostatisticscom.js | 2 +- .../component/Videostatisticscomtwo.js | 16 ++++++++-------- 3 files changed, 21 insertions(+), 10 deletions(-) diff --git a/public/react/src/modules/courses/signin/css/signincdi.css b/public/react/src/modules/courses/signin/css/signincdi.css index 9416de345..cdd41eede 100644 --- a/public/react/src/modules/courses/signin/css/signincdi.css +++ b/public/react/src/modules/courses/signin/css/signincdi.css @@ -100,7 +100,10 @@ width: 80%; } .ws50s{ - width: 50%; + width: 50%; + } +.ws40s{ + width: 40%; } .hs30s{ height: 30%; @@ -425,6 +428,14 @@ white-space:nowrap; cursor: default; } +.maxnamewidth90s{ + width: 90px; + max-width: 90px; + overflow:hidden; + text-overflow:ellipsis; + white-space:nowrap; + cursor: default; +} .maxnamewidth100s{ width: 100px; max-width: 100px; diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js index 3c12ff424..dff57d642 100644 --- a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js +++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js @@ -39,7 +39,7 @@ class Videostatisticscom extends Component { this.props.statisticsy(false)}>

this.props.statisticsy(false)}>返回

-
视频统计总览
+
视频统计总览
播放数据从{this.props.watch_staticsdata&&this.props.watch_staticsdata.begin_at?this.props.watch_staticsdata.begin_at:0}开始统计
- {/*计算成绩时间:{teacherdata&&teacherdata.calculation_time==null?"--": moment(teacherdata&&teacherdata.calculation_time).format('YYYY-MM-DD HH:mm')}*/} - {/* { course_is_end===true?"":teacherdata&&teacherdata.task_operation&&teacherdata.task_operation[0]==="开启挑战"?"":*/} - {/* {computeTimetype===true?*/} - - {/* (this.props.isNotMember()===false?*/} - {/* (*/} - {/* teacherdata&&teacherdata.update_score===true?*/} - {/*
*/} - {/* 查看最新成绩*/} - {/*
:""*/} - {/* )*/} - {/* :""):*/} - {/* teacherdata&&teacherdata.homework_status!==undefined&&teacherdata.homework_status[0]=== "未发布"? "":*/} - {/* (this.props.isNotMember()===false?
*/} - {/* 查看最新成绩*/} - {/*
:"")*/} - {/* }*/} - {/*
}*/} +
From be50b57aae5a7cc8578596d49e5deb8559f2abfd Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Tue, 17 Mar 2020 14:12:27 +0800 Subject: [PATCH 19/21] =?UTF-8?q?=E8=B5=84=E6=BA=90=E6=8E=A5=E5=8F=A3?= =?UTF-8?q?=E8=BF=9E=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/courses/left_banner.json.jbuilder | 1 + 1 file changed, 1 insertion(+) diff --git a/app/views/courses/left_banner.json.jbuilder b/app/views/courses/left_banner.json.jbuilder index b53dbbb79..efc40f5ef 100644 --- a/app/views/courses/left_banner.json.jbuilder +++ b/app/views/courses/left_banner.json.jbuilder @@ -30,6 +30,7 @@ json.course_modules @course_modules.each do |mod| json.third_category category.children do |child| json.partial! "category_info", category: child + json.parent_id child.parent_id end end end From 7b32ae5c30be796a6c326f4842d6c8746d37a462 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Tue, 17 Mar 2020 14:15:45 +0800 Subject: [PATCH 20/21] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E8=AE=A1=E7=AE=97?= =?UTF-8?q?=E6=97=B6=E9=97=B4=20=E6=97=B6=E9=97=B4=E9=95=BF=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../courses/shixunHomework/Listofworksstudentone.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js index f6e82d396..fb9c244cd 100644 --- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js +++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js @@ -2519,7 +2519,6 @@ class Listofworksstudentone extends Component { axios.get(url).then((response) => { if (response) { if (response.data.status === 0) { - setTimeout(() => { this.props.showNotification(`${response.data.message}`); // var homeworkid = this.props.match.params.homeworkid; this.Getalistofworks(homeworkid, false); @@ -2529,12 +2528,14 @@ class Listofworksstudentone extends Component { } catch (e) { } - }, 2500); } } // this.Getalistofworkstwo("", "", "", "", 1, 20); }).catch((error) => { console.log(error) + this.setState({ + computeTimetype:true + }) }); } @@ -3364,7 +3365,6 @@ class Listofworksstudentone extends Component { axios.get(url).then((response) => { if (response) { if (response.data.status === 0) { - setTimeout(() => { this.setState({ loadingstate: true }) @@ -3379,11 +3379,13 @@ class Listofworksstudentone extends Component { } catch (e) { } - }, 500); } } }).catch((error) => { console.log(error) + this.setState({ + computeTimetype:true + }) }); }; From b84f1a435eafb59b90e814f38d0717233bb67145 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Tue, 17 Mar 2020 14:37:06 +0800 Subject: [PATCH 21/21] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../courses/videostatistics/component/Videostatisticscom.js | 2 +- .../courses/videostatistics/component/Videostatisticscomtwo.js | 2 +- .../courses/videostatistics/component/Videostatisticslist.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js index 220a59b46..c819e76c9 100644 --- a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js +++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js @@ -39,7 +39,7 @@ class Videostatisticscom extends Component { this.props.statisticsy(false)} style={{color:'#5091FF'}}>

this.props.statisticsy(false)}>返回

-
视频统计总览
+
视频统计总览
播放数据从{this.props.watch_staticsdata&&this.props.watch_staticsdata.begin_at?this.props.watch_staticsdata.begin_at:0}开始统计