实名认证

issues25489
caishi 5 years ago
parent fa6dae580f
commit 29a533da0a

@ -4,7 +4,7 @@ import { SnackbarHOC, getImageUrl, City, ConditionToolTip } from 'educoder';
import { Form, Button, Input, Radio, Select, Tooltip, Icon, AutoComplete } from 'antd' import { Form, Button, Input, Radio, Select, Tooltip, Icon, AutoComplete } from 'antd'
const RadioGroup = Radio.Group; const RadioGroup = Radio.Group;
const Option = Select.Option; const Option = Select.Option;
class AccpimtBasicEditItem extends Component { class AccountBasicEditItem extends Component {
constructor(props){ constructor(props){
super(props); super(props);
} }
@ -196,4 +196,4 @@ class AccpimtBasicEditItem extends Component {
) )
} }
} }
export default AccpimtBasicEditItem; export default AccountBasicEditItem;

@ -257,10 +257,10 @@ class RealNameCertificationModal extends Component{
onSendOk = () => { onSendOk = () => {
this.props.form.validateFieldsAndScroll((err, values) => { this.props.form.validateFieldsAndScroll((err, values) => {
console.log(values); // console.log(values);
console.log(this.state.department_id); // console.log(this.state.realName);
if(!err){ if(!err){
let{imageUrl2}=this.state; let{imageUrl2,showRealName}=this.state;
let{current_user,basicInfo}=this.props; let{current_user,basicInfo}=this.props;
if(imageUrl2){ if(imageUrl2){
let { certification } = this.props; let { certification } = this.props;
@ -268,9 +268,10 @@ class RealNameCertificationModal extends Component{
// 实名认证 // 实名认证
let url = `/users/accounts/${current_user && current_user.login}/authentication_apply.json` let url = `/users/accounts/${current_user && current_user.login}/authentication_apply.json`
axios.post((url),{ axios.post((url),{
name:values.name || basicInfo.name, name:this.state.realName || basicInfo.name,
gender:parseInt(values.sex), gender:parseInt(values.sex),
id_number:values.credentials, id_number:values.credentials,
show_realname:showRealName,
attachment_ids:[this.state.fileID] attachment_ids:[this.state.fileID]
}).then((result)=>{ }).then((result)=>{
if(result){ if(result){

Loading…
Cancel
Save