diff --git a/public/react/src/modules/user/usersInfo/InfosTopics.js b/public/react/src/modules/user/usersInfo/InfosTopics.js index 13bd93ebd..3a5d0c080 100644 --- a/public/react/src/modules/user/usersInfo/InfosTopics.js +++ b/public/react/src/modules/user/usersInfo/InfosTopics.js @@ -1,7 +1,7 @@ import React, { Component } from 'react'; import { SnackbarHOC } from 'educoder'; import {BrowserRouter as Router,Route,Switch,Link} from 'react-router-dom'; -import {Tooltip,Menu,Pagination,Spin, Dropdown} from 'antd'; +import {Tooltip,Menu,Pagination,Spin, Dropdown,Checkbox} from 'antd'; import axios from 'axios'; import {getImageUrl,WordsBtn} from 'educoder'; import moment from 'moment'; @@ -21,7 +21,8 @@ class InfosTopics extends Component{ sort_by:"updated_at", sort_direction:"desc", page:1, - data:undefined + data:undefined, + checkBoxValues:[] } } @@ -112,13 +113,20 @@ class InfosTopics extends Component{ ) } + onCheckBoxChange=(checkedValues)=>{ + debugger + this.setState({ + checkBoxValues:checkedValues + }) + } render(){ let{ category, course_list_id, isSpin, data, - page + page, + sort_direction } = this.state; let categorylist=[ @@ -140,20 +148,14 @@ class InfosTopics extends Component{ const menu = ( - - 1st menu item - + 最近更新 - - 2nd menu item - - - - - 3rd menu item - + 题目更新 + {types==="publicly"? + 贡献者 + :""} ); return( @@ -206,8 +208,10 @@ class InfosTopics extends Component{
我的题库 - 公共题库 + href={`/users/innov/topics/personal`}>我的题库 + 公共题库
@@ -233,14 +237,22 @@ class InfosTopics extends Component{
-
+

{data&&data.count} - 已选择 {data&&data.count} + 已选择 {this.state.checkBoxValues.length}

- 最近更新 + + 最近更新 + + + + + 发送 {types==="personal"?删除:""} @@ -248,21 +260,21 @@ class InfosTopics extends Component{

- {data===undefined?:data.question_banks===undefined||data.question_banks.length===0?:data.question_banks.map((item,key)=>{ - return( + {data===undefined?:data.question_banks===undefined||data.question_banks.length===0?: + + {data.question_banks.map((item,key)=>{ + return(
- {/*id: 4269*/} -
- - + + {item.name} - {item.is_public===false?公开:""} + {item.is_public===false?公开:""} {types==="personal"&&item.is_public===false?设为公开:""} @@ -270,7 +282,7 @@ class InfosTopics extends Component{

- {types==="publicly"?{item.creator_name}:""} + {types==="publicly"?{item.creator_name}:""} {item.quotes_count} 次引用 {item.solve_count} 次答题 {moment(item.updated_at).fromNow()} @@ -287,6 +299,8 @@ class InfosTopics extends Component{

)})} + + } { data&&data.count >15 && diff --git a/public/react/src/modules/user/usersInfo/usersInfo.css b/public/react/src/modules/user/usersInfo/usersInfo.css index b97bc13a4..f57612f77 100644 --- a/public/react/src/modules/user/usersInfo/usersInfo.css +++ b/public/react/src/modules/user/usersInfo/usersInfo.css @@ -281,7 +281,7 @@ } .topcsactive{ - color: #4CACFF; + color: #4CACFF !important; } .topicsmidfont{ @@ -325,7 +325,7 @@ } .pd1323{ - padding: 10px 30px 25px 30px; + padding: 10px 6px 25px 40px; cursor: pointer; } .pd1323:hover { @@ -350,13 +350,13 @@ } .topscisright{ - right: -2px; + right: 0px; top: 50px; display: block; position: absolute; } -.topsics125{ - width: 125px; +.topsics100{ + width: 100px; display: inline-block; } \ No newline at end of file