From c3037eab854cdf8cd44ce6dbec1b56528f9b9845 Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Tue, 17 Mar 2020 22:33:38 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E7=89=88=E6=9C=AC?= =?UTF-8?q?=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/models/attachment.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/attachment.rb b/app/models/attachment.rb index dc8b44d1e..e91c4bc40 100644 --- a/app/models/attachment.rb +++ b/app/models/attachment.rb @@ -123,7 +123,7 @@ class Attachment < ApplicationRecord end def copy_attributes_from_new_attachment(new_attachment) - self.attributes = new_attachment.attributes.dup.except("id","container_id","container_type","is_public","downloads", "quotes",'is_publish','publish_time', "delay_publish") + self.attributes = new_attachment.attributes.dup.except("id","container_id","container_type","is_public","downloads", "quotes",'is_publish','publish_time', "delay_publish", "link") end def set_public(is_public) From be78b03ca69f3b09190762f4a5e4a4b6dbda0102 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 22:35:17 +0800 Subject: [PATCH 2/3] =?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 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js index 9b859cede..a16e0ed39 100644 --- a/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js +++ b/public/react/src/modules/courses/videostatistics/component/Videostatisticscom.js @@ -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 Videostatisticscom extends Component {
总观看时长(时)
-
{this.props.watch_staticsdata&&this.props.watch_staticsdata.total_duration?this.props.watch_staticsdata.total_duration:0}
+
{this.props.watch_staticsdata&&this.props.watch_staticsdata.total_duration?formatSeconds(this.props.watch_staticsdata.total_duration):0}
From 6ba830e7748020bf6b37df99cd74156a9f7b327e Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Tue, 17 Mar 2020 22:43:39 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E7=89=88=E6=9C=AC?= =?UTF-8?q?=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/models/attachment.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/attachment.rb b/app/models/attachment.rb index e91c4bc40..5e409decd 100644 --- a/app/models/attachment.rb +++ b/app/models/attachment.rb @@ -115,7 +115,7 @@ class Attachment < ApplicationRecord def become_history history = self.attachment_histories.first - new_attachment_history = AttachmentHistory.new(self.attributes.except("id", "resource_bank_id", "unified_setting", "course_second_category_id", "delay_publish").merge( + new_attachment_history = AttachmentHistory.new(self.attributes.except("id", "resource_bank_id", "unified_setting", "course_second_category_id", "delay_publish", "link").merge( attachment_id: self.id, version: history.nil? ? 1 : history.version + 1, ))