dev_oauth
caicai8 6 years ago
parent 2adf55507e
commit a3ee98adbf

@ -1,5 +1,5 @@
import React,{ Component } from "react";
import { Input,Checkbox,Table, Pagination, Modal,Menu ,Spin, Tooltip} from "antd";
import { Input,Checkbox,Table, Pagination, Modal,Menu ,Spin, Tooltip , Divider } from "antd";
import ClipboardJS from 'clipboard'
import '../css/Courses.css'
import '../css/members.css'
@ -612,7 +612,12 @@ class studentsList extends Component{
padding-top: 10px;
padding-bottom: 8px;
}
.drop_down_menu .drop_down_btn{
border-top:none;
}
.dividerStyle.ant-divider-horizontal{
margin: 0px;
}
`}</style>
{ isAdmin &&
<li className="li_line drop_down fr color-blue font-16">
@ -656,8 +661,10 @@ class studentsList extends Component{
</p>):
''
}
{course_group_id != 0 && <li key={0} onClick={() => this.moveToGroup({id: 0})}>未分班</li>}
{
course_group_id != 0 && course_groups && course_groups.length > 0 &&
<li key={0} onClick={() => this.moveToGroup({id: 0})}>未分班</li>
}
{ course_groups.filter((item)=> {
return item.id != course_group_id && (!this.state.groupSearchValue || item.name.indexOf(this.state.groupSearchValue) != -1)
}).map( item => {
@ -665,6 +672,7 @@ class studentsList extends Component{
<li key={item.id} onClick={() => this.moveToGroup(item)} title={item.name}>{item.name}</li>
)
}) }
{ course_groups && course_groups.length > 0 && <Divider className="dividerStyle"></Divider> }
{ isAdmin &&
<p className="drop_down_btn">

@ -677,6 +677,12 @@ class studentsList extends Component{
float: none;
text-align: center;
}
.drop_down_menu .drop_down_btn{
border-top:none;
}
.dividerStyle.ant-divider-horizontal{
margin: 0px;
}
`}</style>
<div className="mt20 edu-back-white padding20 teacherList">
@ -705,12 +711,13 @@ class studentsList extends Component{
{
groupList && groupList.graduation_group_list && groupList.graduation_group_list.filter((item)=> {
return (!this.state.graduationGroupSearchValue || item.name.indexOf(this.state.graduationGroupSearchValue) != -1)
}).map((item,key)=>{
}).map((item,key)=>{
return(
<li key={key} value={item.id} onClick={() => this.joinGraduationGroup(item.id)}>{item.name}</li>
)
})
}
{ groupList && groupList.graduation_groups_count > 0 && <Divider className="dividerStyle"></Divider> }
<p className="drop_down_btn">
<a href="javascript:void(0)" className="color-grey-6"
onClick={() => this.refs['addGraduationGroupModal'].setVisible(true)}

@ -41,7 +41,7 @@ class Repository extends Component {
}
render() {
let { match, author, git_url, lastest_commit, trees, commits,repositoryLoading, pathArray } = this.props;
let { match, author, git_url, lastest_commit, trees, commits,repositoryLoading, pathArray , TPMRightSectionData } = this.props;
if (!author) {
author = {}
}
@ -49,7 +49,6 @@ class Repository extends Component {
if(this.props.author!=undefined){
userauthority=this.props.author.login===""||this.props.author.user_id===""||this.props.author.login===null||this.props.author.user_id===null;
}
return (
<React.Fragment>
{/* jfinalshop/WebRoot */}
@ -85,7 +84,7 @@ class Repository extends Component {
<a href="/forums/2784" target="_blank"
className=" guideBtn" >Git使用指南</a>
{
this.props.current_user && this.props.current_user.admin ==true ?
this.props.current_user && (this.props.current_user.admin ==true || (TPMRightSectionData&& TPMRightSectionData.creator && TPMRightSectionData.creator.login == this.props.current_user.login)) ?
<ActionBtn style="orangeLine" className="ml20" to={`/shixuns/${match.params.shixunId}/repository/add_file`}>+添加文件</ActionBtn>:""
}

Loading…
Cancel
Save