webIDE 点击时判断是否登录

This commit is contained in:
caishi 2022-11-14 16:44:53 +08:00
parent eac7c739ae
commit 5347be0614
2 changed files with 2 additions and 2 deletions

View File

@ -476,7 +476,7 @@ function CoderDepot(props){
</Dropdown>
}
{
checkIfLogin?
checkIfLogin && checkIfLogin()?
<a className='newBtn' onClick={()=>eventTrack(`/${owner}/${projectsId}/webIDE/tree/${defaultBranch}`)}>Web IDE <div className='newBtnImg'></div></a>
:
<a className='newBtn' onClick={showLoginDialog}>Web IDE <div className='newBtnImg'></div></a>

View File

@ -303,7 +303,7 @@ class MessageCount extends Component {
codeReview=()=>{
const {history,match , checkIfLogin , showLoginDialog}=this.props;
if(checkIfLogin){
if(checkIfLogin && checkIfLogin()){
const { projectsId, mergeId , owner } =match.params;
const { repo_id } = this.props && this.props.projectDetail;
// 埋点