Commit 2241c1a1 authored by wildfirecode13's avatar wildfirecode13

1

parent 72f96a98
......@@ -13,9 +13,9 @@ export const homeInfo = {
export const updateUinfo = {
"code": null,
"data": true,
"message": null,
"success": true
"data": 1,
"message": 'dfs',
"success": false
}
export const doshare = {
"code": null,
......
......@@ -23,11 +23,16 @@ class Userinfo extends Component {
return Toast("名字不能为空");
}
API.updateUinfo({type: 2, nickName: planame}).then(res=>{
this.props.ctx.freshHomeInfo();
// console.log('res',res);
}).catch(e=>{
console.log('err',e);
API.updateUinfo({ type: 2, nickName: planame }).then(res => {
console.log('res', res);
if (res && res.success) {
this.props.ctx.freshHomeInfo();
this.props.onClose();
} else {
Toast(res.message || '网络异常,请稍后重试~')
}
}).catch(e => {
console.log('err', e);
});
// let updateuinfo = await getAPIdata(Store.updateUinfo, {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment