diff --git a/app/libs/util/redis.rb b/app/libs/util/redis.rb new file mode 100644 index 000000000..f240406f5 --- /dev/null +++ b/app/libs/util/redis.rb @@ -0,0 +1,9 @@ +module Util::Redis + class << self + def online_user_count + if Rails.cache.is_a?(ActiveSupport::Cache::RedisStore) + Rails.cache.data.scan(0, match: 'cache:_session_id:*', count: 100000).last.uniq.size + end + end + end +end \ No newline at end of file diff --git a/public/react/src/modules/courses/Index.js b/public/react/src/modules/courses/Index.js index 457723376..f21dc01ab 100644 --- a/public/react/src/modules/courses/Index.js +++ b/public/react/src/modules/courses/Index.js @@ -270,7 +270,6 @@ const Ordering=Loadable({ loader: () => import('../../modules/courses/ordering/Ordering'), loading: Loading, }); - class CoursesIndex extends Component{ constructor(props) { super(props) diff --git a/public/react/src/modules/courses/completetaskdetails/Completetaskdetails.js b/public/react/src/modules/courses/completetaskdetails/Completetaskdetails.js index 833c60e1f..0da4e4369 100644 --- a/public/react/src/modules/courses/completetaskdetails/Completetaskdetails.js +++ b/public/react/src/modules/courses/completetaskdetails/Completetaskdetails.js @@ -1,3 +1,4 @@ + import React, {Component} from "react"; import { WordsBtn,on, off, trigger,MarkdownToHtml,getImageUrl} from 'educoder'; import { @@ -78,7 +79,6 @@ class Groupjobbandetails extends Component { ) } {/*
*/} - {/*{datas.attachments === undefined ? "" : datas.attachments.map((item, key) => {*/} {/* return (*/} {/* */} diff --git a/public/react/src/modules/courses/completetaskdetails/Completetaskpage.js b/public/react/src/modules/courses/completetaskdetails/Completetaskpage.js index b74ad13e2..039dbda89 100644 --- a/public/react/src/modules/courses/completetaskdetails/Completetaskpage.js +++ b/public/react/src/modules/courses/completetaskdetails/Completetaskpage.js @@ -1,3 +1,4 @@ + import React, {Component} from "react"; import {Link, NavLink} from 'react-router-dom'; import {WordsBtn, ActionBtn,MarkdownToHtml} from 'educoder'; @@ -228,4 +229,3 @@ class Completetaskpage extends Component { } export default Completetaskpage; - diff --git a/public/react/src/modules/courses/completetaskdetails/completetaskdetails.css b/public/react/src/modules/courses/completetaskdetails/completetaskdetails.css index 0f3b143d6..809736d69 100644 --- a/public/react/src/modules/courses/completetaskdetails/completetaskdetails.css +++ b/public/react/src/modules/courses/completetaskdetails/completetaskdetails.css @@ -1,3 +1,4 @@ + .yslquestionbank1{ padding-top: 30px !important; padding-right: 30px !important; @@ -11,7 +12,6 @@ .yslquesmarkdowntext{ font-size: 16px; color: #707070; - } .yslquesmat26{ margin-top: 26px; diff --git a/public/react/src/modules/courses/groupjobbank/GroupPackage.js b/public/react/src/modules/courses/groupjobbank/GroupPackage.js index 73132b3fa..e0b220202 100644 --- a/public/react/src/modules/courses/groupjobbank/GroupPackage.js +++ b/public/react/src/modules/courses/groupjobbank/GroupPackage.js @@ -1,3 +1,4 @@ + import React, {Component} from "react"; import { WordsBtn,on, off, trigger,markdownToHTML,getImageUrl} from 'educoder'; import { @@ -36,7 +37,6 @@ class GroupPackage extends Component { - } // 获取数据地方 getTrainingjobsetting = () => { diff --git a/public/react/src/modules/courses/groupjobbank/GroupPackage2.js b/public/react/src/modules/courses/groupjobbank/GroupPackage2.js index 349c2b97e..888e6c012 100644 --- a/public/react/src/modules/courses/groupjobbank/GroupPackage2.js +++ b/public/react/src/modules/courses/groupjobbank/GroupPackage2.js @@ -59,28 +59,28 @@ class GroupPackage extends Component { return ( bool===true? -
- { - datas===undefined?"":datas.min_num===undefined||datas.max_num===undefined?"":datas.min_num===null||datas.max_num===null?"": -

- 分组要求: - {datas&&datas.min_num}~ {datas&&datas.max_num}(学生提交作品时需要关联同组成员,组内成员作品共享) -

- } -

- 基于项目实施 - (学生必须在本平台创建项目,项目管理员可以提交作品) -

-
- :
+
{ - datas===undefined?"":datas.group_info===undefined?"":datas.group_info.min_number===undefined||datas.group_info.max_number===undefined?"": - datas.group_info.min_number===null||datas.group_info.max_number===null?"": + datas===undefined?"":datas.min_num===undefined||datas.max_num===undefined?"":datas.min_num===null||datas.max_num===null?"":

分组要求: - {datas&&datas.group_info&&datas.group_info.min_number}~ {datas&&datas.group_info&&datas.group_info.max_number}(学生提交作品时需要关联同组成员,组内成员作品共享) + {datas&&datas.min_num}~ {datas&&datas.max_num}(学生提交作品时需要关联同组成员,组内成员作品共享)

} +

+ 基于项目实施 + (学生必须在本平台创建项目,项目管理员可以提交作品) +

+
+ :
+ { + datas===undefined?"":datas.group_info===undefined?"":datas.group_info.min_number===undefined||datas.group_info.max_number===undefined?"": + datas.group_info.min_number===null||datas.group_info.max_number===null?"": +

+ 分组要求: + {datas&&datas.group_info&&datas.group_info.min_number}~ {datas&&datas.group_info&&datas.group_info.max_number}(学生提交作品时需要关联同组成员,组内成员作品共享) +

+ } { datas&&datas.group_info&&datas.group_info.base_on_project?

diff --git a/public/react/src/modules/courses/groupjobbank/Groupjobbandetails.js b/public/react/src/modules/courses/groupjobbank/Groupjobbandetails.js index a0ba84549..fa3503b69 100644 --- a/public/react/src/modules/courses/groupjobbank/Groupjobbandetails.js +++ b/public/react/src/modules/courses/groupjobbank/Groupjobbandetails.js @@ -1,3 +1,4 @@ + import React, {Component} from "react"; import { WordsBtn,on, off, trigger,MarkdownToHtml,getImageUrl} from 'educoder'; import { @@ -79,7 +80,6 @@ class Groupjobbandetails extends Component { ) } {/*

*/} - {/*{datas.attachments === undefined ? "" : datas.attachments.map((item, key) => {*/} {/* return (*/} {/* */} diff --git a/public/react/src/modules/courses/groupjobbank/GroupjobbankPage.js b/public/react/src/modules/courses/groupjobbank/GroupjobbankPage.js index 25089079d..237aac3a3 100644 --- a/public/react/src/modules/courses/groupjobbank/GroupjobbankPage.js +++ b/public/react/src/modules/courses/groupjobbank/GroupjobbankPage.js @@ -1,3 +1,4 @@ + import React, {Component} from "react"; import {Link, NavLink} from 'react-router-dom'; import {WordsBtn, ActionBtn} from 'educoder'; @@ -264,4 +265,3 @@ class GroupjobbankPage extends Component { } export default GroupjobbankPage; - diff --git a/public/react/src/modules/courses/groupjobbank/Groupjobquesanswer.js b/public/react/src/modules/courses/groupjobbank/Groupjobquesanswer.js index b927f3177..8bc9c970d 100644 --- a/public/react/src/modules/courses/groupjobbank/Groupjobquesanswer.js +++ b/public/react/src/modules/courses/groupjobbank/Groupjobquesanswer.js @@ -1,3 +1,4 @@ + import React, {Component} from "react"; import { WordsBtn,on, off, trigger,MarkdownToHtml,getImageUrl} from 'educoder'; import { diff --git a/public/react/src/modules/courses/questionbank/Generaljobbankdetails.js b/public/react/src/modules/courses/questionbank/Generaljobbankdetails.js index c24c0569c..881f0f70d 100644 --- a/public/react/src/modules/courses/questionbank/Generaljobbankdetails.js +++ b/public/react/src/modules/courses/questionbank/Generaljobbankdetails.js @@ -1,3 +1,4 @@ + import React, {Component} from "react"; import {Link, NavLink} from 'react-router-dom'; import {WordsBtn, ActionBtn,getImageUrl} from 'educoder'; @@ -259,4 +260,3 @@ class Generaljobbankdetails extends Component { } export default Generaljobbankdetails; - diff --git a/public/react/src/modules/courses/questionbank/Generaljobdetails.js b/public/react/src/modules/courses/questionbank/Generaljobdetails.js index b52c9f027..65d597428 100644 --- a/public/react/src/modules/courses/questionbank/Generaljobdetails.js +++ b/public/react/src/modules/courses/questionbank/Generaljobdetails.js @@ -1,3 +1,4 @@ + import React, {Component} from "react"; import { WordsBtn,on, off, trigger,markdownToHTML, MarkdownToHtml ,getImageUrl} from 'educoder'; import {