forked from tongChong/forgeplus-react
17 lines
370 B
JavaScript
17 lines
370 B
JavaScript
import React from 'react';
|
|
|
|
function Profile({children,sureFunc,showCompeleteDialog , completeProfile, className}) {
|
|
|
|
function checkProfile() {
|
|
if(!completeProfile){
|
|
showCompeleteDialog && showCompeleteDialog();
|
|
}else{
|
|
sureFunc();
|
|
}
|
|
}
|
|
|
|
return(
|
|
<a className={className} onClick={checkProfile}>{children}</a>
|
|
)
|
|
}
|
|
export default Profile; |