diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js
index 0c064f3e3..6dbe44ae3 100644
--- a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js
+++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js
@@ -25,6 +25,7 @@ class Videostatisticscom extends Component {
}
+
render() {
return (
@@ -42,23 +43,49 @@ class Videostatisticscom extends Component {
`
.yslsprenshu{
background-image: url(${getImageUrl(`images/qiandao/sprenshu.png`)});
+ background-repeat:no-repeat;
+ -moz-background-size:100% 100%;
+ background-size:100% 100%;
}
.yslspcishu{
background-image: url(${getImageUrl(`images/qiandao/spcishu.png`)});
+ background-repeat:no-repeat;
+ -moz-background-size:100% 100%;
+ background-size:100% 100%;
}
.yslshipingshi{
background-image: url(${getImageUrl(`images/qiandao/shipingshi.png`)});
+ background-repeat:no-repeat;
+ -moz-background-size:100% 100%;
+ background-size:100% 100%;
}
`
}
-
-
-
-
-
-
+
+
+
+
观看总人数(人)
+
{this.props.watch_staticsdata&&this.props.watch_staticsdata.people_num?this.props.watch_staticsdata.people_num:0}
+
+
+
+
+
+
+
+
观看总人次(次)
+
{this.props.watch_staticsdata&&this.props.watch_staticsdata.freq?this.props.watch_staticsdata.freq:0}
+
+
+
+
+
+
总观看时长(时)
+
{this.props.watch_staticsdata&&this.props.watch_staticsdata.total_duration?this.props.watch_staticsdata.total_duration:0}
+
+
diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js
new file mode 100644
index 000000000..692958517
--- /dev/null
+++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticslist.js
@@ -0,0 +1,204 @@
+import React, {Component} from "react";
+import '../../signin/css/signincdi.css';
+import {Pagination,Table} from 'antd';
+import {getImageUrl} from 'educoder';
+import axios from 'axios';
+import LoadingSpin from "../../../../common/LoadingSpin";
+import NoneDatas from "../../signin/component/NoneDatas";
+
+
+//条目
+class Videostatisticslist extends Component {
+ //条目组件
+ constructor(props) {
+ super(props);
+
+ this.state = {
+ columnsstu: [
+ {
+ title: '序号',
+ dataIndex: 'number',
+ key: 'number',
+ align: "center",
+ className: 'font-14',
+ width: '90px',
+ render: (text, record) => (
+
{record.number}
+ ),
+ },
+ {
+ title: '视频名称',
+ dataIndex: 'title',
+ key: 'title',
+ align: "center",
+ className: 'font-14 maxnamewidth150s',
+ width: '150px',
+ render: (text, record) => (
+
{record.title}
+ ),
+ },
+ {
+ title: '观看人数(人)',
+ dataIndex: 'people_num',
+ key: 'people_num',
+ align: "center",
+ className: 'font-14',
+ width: '98px',
+ render: (text, record) => (
+
{record.people_num}
+ ),
+ },
+ {
+ title: '累计观看时长',
+ dataIndex: 'total_time',
+ key: 'total_time',
+ align: "center",
+ className: 'font-14 maxnamewidth150s',
+ width: '150px',
+ render: (text, record) => (
+
{record.total_time}
+ ),
+ },
+ {
+ title: '发布人',
+ dataIndex: 'user_name',
+ key: 'user_name',
+ align: "center",
+ className: 'font-14 maxnamewidth100s',
+ width: '100px',
+ render: (text, record) => (
+
{record.user_name}
+ ),
+ },
+ {
+ title: '详情',
+ dataIndex: 'id',
+ key: 'id',
+ align: "center",
+ className: 'font-14',
+ width: '90px',
+ render: (text, record) => (
+
this.props.details()}>详情
+ ),
+ }
+ ],
+ loading:false,
+ data:[],
+ page:1,
+ limit:10,
+ members_count:0,
+ }
+ }
+
+ componentDidMount() {
+ this.togetdatas(1);
+
+ }
+
+ componentDidUpdate = (prevProps) => {
+
+
+ }
+ paginationonChange = (pageNumber) => {
+ this.setState({
+ page: pageNumber,
+ })
+ this.togetdatas(pageNumber);
+ }
+
+
+ togetdatas(page){
+ this.setState({
+ loading:true
+ })
+ const CourseId=this.props.match.params.coursesId;
+ let url=`/courses/${CourseId}/watch_video_histories.json`;
+ axios.get(url,{params:{
+ page:page
+ }
+ }).then((response) => {
+ if(response){
+ this.setState({
+ data:response.data&&response.data.videos?response.data.videos:[],
+ members_count:count,
+ })
+
+ }
+ this.setState({
+ loading:false
+ })
+ }).catch((error) => {
+ this.setState({
+ loading:false
+ })
+ });
+ }
+
+
+
+
+ render() {
+ let {loading,data,columnsstu,page,members_count,limit}=this.state;
+ return (
+
+
+
+
+
+ {
+ loading===true?
+
+
+
+ :
+
+ {
+ data.length===0?
+
+
+
+ :
+
+ }
+
+
+
+ }
+
+
+
+
+ {
+ data&&data.length>0?
+
+ :""
+ }
+
+
+
+
+
+ )
+ }
+}
+
+export default Videostatisticslist;