forked from Gitlink/forgeplus-react
commit隐藏编辑文件按钮
This commit is contained in:
commit
eafd40a6ff
|
@ -54,6 +54,11 @@ class CoderRootFileDetail extends Component {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
isCommit = () => {
|
||||||
|
const {detail, branch} = this.props;
|
||||||
|
return detail && detail.commit && detail.commit.sha.includes(branch)
|
||||||
|
}
|
||||||
|
|
||||||
// 更新网页标题
|
// 更新网页标题
|
||||||
updateDocumentTitle(){
|
updateDocumentTitle(){
|
||||||
const {projectDetail, treeValuePath, location} = this.props;
|
const {projectDetail, treeValuePath, location} = this.props;
|
||||||
|
@ -300,7 +305,7 @@ class CoderRootFileDetail extends Component {
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<p className="text-right">
|
<p className="text-right">
|
||||||
{flag && platform && (
|
{flag && platform && !this.isCommit() && (
|
||||||
<div>
|
<div>
|
||||||
{readOnly ? (
|
{readOnly ? (
|
||||||
<span>
|
<span>
|
||||||
|
|
Loading…
Reference in New Issue