Skip to content

Commit

Permalink
初始化流程添加校验条件
Browse files Browse the repository at this point in the history
  • Loading branch information
matrixbingo committed Feb 23, 2021
1 parent ebadd3b commit be898b4
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions das-console-static/src/view/components/pages/init/Init.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,10 @@ export default class Init extends Component {

initAdminInfo(current) {
const admin = this.getValueToJson(this.admin)
if(!admin.password || admin.password.length < 6 || admin.password.length >20){
this.showErrorsMsg('密码长度6~20位')
return
}
this.props.initAdminInfo(admin, this, (_this, data) => {
if (data.code == 200) {
_this.showSuccessMsg('admin初始化成功')
Expand Down

0 comments on commit be898b4

Please sign in to comment.