Skip to content

Commit

Permalink
improve ux
Browse files Browse the repository at this point in the history
  • Loading branch information
vapao committed Sep 28, 2021
1 parent 405f477 commit 9998ae4
Showing 1 changed file with 1 addition and 14 deletions.
15 changes: 1 addition & 14 deletions spug_web/src/pages/host/Form.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,9 @@ export default observer(function () {
})
}
} else {
message.success('操作成功');
message.success('验证成功');
store.formVisible = false;
store.fetchRecords();
if (!store.record.id) handleNext(res)
}
}, () => setLoading(false))
}
Expand All @@ -59,23 +58,11 @@ export default observer(function () {
message.success('验证成功');
store.formVisible = false;
store.fetchRecords();
if (!store.record.id) handleNext(res)
})
}
message.error('请输入授权密码')
}

function handleNext(res) {
Modal.confirm({
title: '提示信息',
content: '是否继续完善主机的扩展信息?',
onOk: () => {
store.record = res;
store.detailVisible = true
}
})
}

const ConfirmForm = (props) => (
<Form layout="vertical" style={{marginTop: 24}}>
<Form.Item required label="授权密码" help={`用户 ${props.username} 的密码, 该密码仅做首次验证使用,不会存储该密码。`}>
Expand Down

0 comments on commit 9998ae4

Please sign in to comment.