forked from Gitlink/forgeplus-react
fix issue
This commit is contained in:
parent
1a5f81887a
commit
5b2198ce4c
|
@ -128,6 +128,7 @@ class CoderRootCommit extends Component{
|
||||||
const { commitDatas , dataCount , limit , page , isSpining , branchList } = this.state;
|
const { commitDatas , dataCount , limit , page , isSpining , branchList } = this.state;
|
||||||
const { projectDetail, commit_class , defaultBranch } = this.props;
|
const { projectDetail, commit_class , defaultBranch } = this.props;
|
||||||
const { projectsId , owner , branchName } = this.props.match.params;
|
const { projectsId , owner , branchName } = this.props.match.params;
|
||||||
|
console.log(branchName);
|
||||||
let branch = returnbar(branchName || defaultBranch);
|
let branch = returnbar(branchName || defaultBranch);
|
||||||
return(
|
return(
|
||||||
<React.Fragment>
|
<React.Fragment>
|
||||||
|
|
|
@ -38,14 +38,14 @@ function Tags(props) {
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title:"创建时间",
|
title:"创建时间",
|
||||||
dataIndex:"time",
|
dataIndex:"time_ago",
|
||||||
key:2,
|
key:2,
|
||||||
ellipsis:true,
|
ellipsis:true,
|
||||||
render:(txt,item)=>{
|
render:(txt,item)=>{
|
||||||
return (
|
return (
|
||||||
<span className="color-grey-3">
|
<span className="color-grey-3">
|
||||||
<Link className="mr3" style={{fontWeight:"500"}} to={`/${item.commit && item.commit.login}`} >{item.commit && item.commit.name}</Link>
|
<Link className="mr3" style={{fontWeight:"500"}} to={`/${item.commit && item.commit.login}`} >{item.commit && item.commit.name}</Link>
|
||||||
<span>创建于{item.commit && item.commit.time_ago}</span>
|
<span>创建于{txt}</span>
|
||||||
</span>
|
</span>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
@ -63,7 +63,11 @@ function Index(props) {
|
||||||
<div className="treeinfo">
|
<div className="treeinfo">
|
||||||
<Link to={`/${owner}/${projectsId}/tree/${turnbar(i.name)}`} className="task-hide">{i.name}</Link>
|
<Link to={`/${owner}/${projectsId}/tree/${turnbar(i.name)}`} className="task-hide">{i.name}</Link>
|
||||||
<div>
|
<div>
|
||||||
<img style={{borderRadius:"50%"}} src={getImageUrl(`${last_commit && last_commit.committer && last_commit.committer.image_url}`)} alt=""/>
|
{
|
||||||
|
<Link to={`/${last_commit && last_commit.committer && last_commit.committer.login}`}>
|
||||||
|
<img style={{borderRadius:"50%"}} src={getImageUrl(`/${last_commit && last_commit.committer && last_commit.committer.image_url}`)} alt=""/>
|
||||||
|
</Link>
|
||||||
|
}
|
||||||
<span className="mr3 color-grey-3" style={{fontWeight:"500"}}>{last_commit && last_commit.committer && last_commit.committer.name}</span>
|
<span className="mr3 color-grey-3" style={{fontWeight:"500"}}>{last_commit && last_commit.committer && last_commit.committer.name}</span>
|
||||||
<span className="color-grey-3">更新于{last_commit && last_commit.time_from_now}</span>
|
<span className="color-grey-3">更新于{last_commit && last_commit.time_from_now}</span>
|
||||||
</div>
|
</div>
|
||||||
|
@ -72,7 +76,7 @@ function Index(props) {
|
||||||
<div>
|
<div>
|
||||||
<span>
|
<span>
|
||||||
<img src={Tree} alt="sha" width={"16px"}/>
|
<img src={Tree} alt="sha" width={"16px"}/>
|
||||||
<Link to={`/${owner}/${projectsId}/commits/${truncateCommitId(last_commit && last_commit.sha)}`}>{truncateCommitId(last_commit && last_commit.sha)}</Link>
|
<Link to={`/${owner}/${projectsId}/commits/branch/${truncateCommitId(last_commit && last_commit.sha)}`}>{truncateCommitId(last_commit && last_commit.sha)}</Link>
|
||||||
<input type="text" id={`value${key}${k}`} value={`${truncateCommitId(last_commit && last_commit.sha)}`}/>
|
<input type="text" id={`value${key}${k}`} value={`${truncateCommitId(last_commit && last_commit.sha)}`}/>
|
||||||
</span>
|
</span>
|
||||||
<CopyTool beforeText="复制commit id" afterText="复制成功" inputId={`value${key}${k}`}/>
|
<CopyTool beforeText="复制commit id" afterText="复制成功" inputId={`value${key}${k}`}/>
|
||||||
|
@ -81,7 +85,7 @@ function Index(props) {
|
||||||
<div className="treeabout">
|
<div className="treeabout">
|
||||||
{
|
{
|
||||||
(isManager || isDeveloper) && (projectDetail && projectDetail.type!==2) &&
|
(isManager || isDeveloper) && (projectDetail && projectDetail.type!==2) &&
|
||||||
<Link to={`/${owner}/${projectsId}/pulls/new/${item.name}`} className="btn-83">+ 合并请求</Link>
|
<Link to={`/${owner}/${projectsId}/pulls/new/${i.name}`} className="btn-83">+ 合并请求</Link>
|
||||||
}
|
}
|
||||||
<Dropdown overlay={menu(i.zip_url,i.tar_url)} trigger={['click']} placement="bottomRight">
|
<Dropdown overlay={menu(i.zip_url,i.tar_url)} trigger={['click']} placement="bottomRight">
|
||||||
<a className="btn-83 ml15">下载<i className="iconfont icon-sanjiaoxing-down font-14"></i></a>
|
<a className="btn-83 ml15">下载<i className="iconfont icon-sanjiaoxing-down font-14"></i></a>
|
||||||
|
|
Loading…
Reference in New Issue