Merge branch 'dev_aliyun' of http://bdgit.educoder.net/Hjqreturn/educoder into dev_aliyun

courseware
anke1460 5 years ago
commit 4ab0d9d506

@ -106,7 +106,7 @@ class AttendancesController < ApplicationController
attrs = %i[course_attendance_id user_id course_member_id course_id course_group_id created_at updated_at]
same_attrs = {course_attendance_id: attendance.id, course_id: course.id}
same_attrs = {course_attendance_id: @attendance.id, course_id: @course.id}
CourseMemberAttendance.bulk_insert(*attrs) do |worker|

@ -19,6 +19,7 @@ json.data do
json.category_id attachment.course_second_category_id
if (@course_second_category_id.to_i == 0 && attachment.course_second_category.present?) || (@parent_category_id == 0 && attachment.course_second_category&.parent_id.to_i != 0)
json.category_name attachment.course_second_category&.name
json.parent_category_name attachment.course_second_category&.parent&.name
end
end
end

@ -1,7 +1,7 @@
import React, {Component} from "react";
import '../../signin/css/signincdi.css';
import {Progress, message} from 'antd';
import {getImageUrl} from 'educoder';
import {getImageUrl,formatSeconds} from 'educoder';
import axios from 'axios';
@ -88,7 +88,7 @@ class Studenticscom extends Component {
<div className="yslshipingshi" style={{width:260,height:100}}>
<div className="ws100s verticallayout tbrt">
<div className="ws100 ts">总观看时长</div>
<div className="ws100s tss">{this.props.watch_staticsdata&&this.props.watch_staticsdata.total_duration?this.props.watch_staticsdata.total_duration:0}</div>
<div className="ws100s tss">{this.props.watch_staticsdata&&this.props.watch_staticsdata.total_duration?formatSeconds(this.props.watch_staticsdata.total_duration):0}</div>
</div>
</div>

@ -155,7 +155,7 @@ class Studentstatistics extends Component {
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,
feq:response.data.data[i].feq,
feq:response.data.data[i].freq,
start_at:response.data.data[i].start_at,
end_at:response.data.data[i].end_at,
})
@ -205,7 +205,7 @@ class Studentstatistics extends Component {
let mysorder="";
if (sorter.order === "ascend") {
if(sorter.columnKey === "feq"){
mysorder="feq-asc";
mysorder="freq-asc";
}else{
mysorder="total_duration-asc";
@ -221,7 +221,7 @@ class Studentstatistics extends Component {
})
} else if (sorter.order === "descend") {
if(sorter.columnKey === "feq"){
mysorder="feq-desc";
mysorder="freq-desc";
}else{
mysorder="total_duration-desc";
@ -263,7 +263,7 @@ class Studentstatistics extends Component {
{
`
.ysltableo .ant-table-thead > tr > th, .ant-table-tbody > tr > td {
padding: 10px 10px;
padding: 10px 5px;
}
`
}

Loading…
Cancel
Save