dev_auth
杨树林 6 years ago
parent 37f3fae030
commit df6f4aeb09

@ -53,6 +53,9 @@ class CompetitionContentspdfpeopledata extends Component {
getdata = () => { getdata = () => {
this.setState({
certification: 3
})
let url = `/users/accounts/${this.props.current_user.login}.json`; let url = `/users/accounts/${this.props.current_user.login}.json`;
axios.get(url).then((result) => { axios.get(url).then((result) => {
if (result.data) { if (result.data) {
@ -64,7 +67,8 @@ class CompetitionContentspdfpeopledata extends Component {
basicInfo: Object.assign({}, {...result.data}, { basicInfo: Object.assign({}, {...result.data}, {
avatar_url: `${result.data.avatar_url}`, avatar_url: `${result.data.avatar_url}`,
gender: result.data.gender == null || result.data.gender == undefined ? 0 : result.data.gender gender: result.data.gender == null || result.data.gender == undefined ? 0 : result.data.gender
}) }),
certification: 3
}) })
} }
}).catch((error) => { }).catch((error) => {
@ -277,6 +281,14 @@ class CompetitionContentspdfpeopledata extends Component {
}) })
} }
//取消认证弹框
onCancel = () => {
this.getdata();
}
//撤销认证 //撤销认证
Cancellationofapplication = (index) => { Cancellationofapplication = (index) => {
let url = "" let url = ""
@ -294,7 +306,7 @@ class CompetitionContentspdfpeopledata extends Component {
} else if (index === 2) { } else if (index === 2) {
this.props.showNotification('撤销职业认证成功') this.props.showNotification('撤销职业认证成功')
} }
this.getdata();
} }
} catch (e) { } catch (e) {
@ -315,16 +327,21 @@ class CompetitionContentspdfpeopledata extends Component {
console.log(emailbool); console.log(emailbool);
return ( return (
<div className="flexdidirectionss mt17"> <div className="flexdidirectionss mt17">
{this.state.certification === 1 ? <RealNameCertificationModal {...this.props} {...this.state} {this.state.certification === 1 ?
wrappedComponentRef={(form) => this.realNameCertificationModal1 = form} <RealNameCertificationModal {...this.props} {...this.state} basicInfo={this.state.basicInfo}
certification={certification} wrappedComponentRef={(form) => this.realNameCertificationModal1 = form}
Getdata={() => this.getdata()} certification={certification}
Getdata={() => this.getdata()}
onCancel={() => this.onCancel()}
></RealNameCertificationModal> : ""} ></RealNameCertificationModal> : ""}
{this.state.certification === 2 ? <RealNameCertificationModal {...this.props} {...this.state} {this.state.certification === 2 ?
wrappedComponentRef={(form) => this.realNameCertificationModal2 = form} <RealNameCertificationModal {...this.props} {...this.state} basicInfo={this.state.basicInfo}
certification={certification} wrappedComponentRef={(form) => this.realNameCertificationModal2 = form}
Getdata={() => this.getdata()} certification={certification}
Getdata={() => this.getdata()}
onCancel={() => this.onCancel()}
></RealNameCertificationModal> : ""} ></RealNameCertificationModal> : ""}
<div className="flexdirections "> <div className="flexdirections ">
<p className="fontcolorsyslhei font-16 w98"><span className="fontcolorsysl font-16">*</span><span></span> <p className="fontcolorsyslhei font-16 w98"><span className="fontcolorsysl font-16">*</span><span></span>

@ -56,6 +56,8 @@ class RealNameCertificationModal extends Component{
} }
componentDidMount() { componentDidMount() {
console.log("RealNameCertificationModal");
console.log(this.props.basicInfo);
if(this.props.basicInfo){ if(this.props.basicInfo){
this.setValue(this.props.basicInfo); this.setValue(this.props.basicInfo);
this.getSchoolList(this.props.basicInfo); this.getSchoolList(this.props.basicInfo);
@ -484,6 +486,7 @@ class RealNameCertificationModal extends Component{
<span><i className="iconfont icon-zhiyerenzheng font-18 color-blue mr5" style={{fontWeight:"normal"}}></i></span> <span><i className="iconfont icon-zhiyerenzheng font-18 color-blue mr5" style={{fontWeight:"normal"}}></i></span>
} }
{...this.props } {...this.props }
{...this.state}
onOk={this.onOk} onOk={this.onOk}
okText="保存" okText="保存"
className="applyForModal certificationModal courseNormalForm" className="applyForModal certificationModal courseNormalForm"

Loading…
Cancel
Save