实现注册功能

This commit is contained in:
F嘉阳
2018-02-05 12:48:44 +08:00
parent be2072f0f2
commit 8e4fde4e4f
4 changed files with 341 additions and 113 deletions

View File

@@ -2,6 +2,7 @@
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:th="http://www.thymeleaf.org">
<head th:include="dist/thymeleaf/common_head :: header('登录')"></head>
<link th:href="@{css/style.css}" rel="stylesheet">
<body>
<div th:insert="~{dist/thymeleaf/common_head :: #body_js}"></div>
<div id="app">
@@ -25,16 +26,16 @@
:rules="rules2" ref="ruleForm2" label-width="100px"
class="demo-ruleForm"
action="/cms/login/dologin"
method="POST" name="loginTest">
method="POST" name="login">
<el-form-item label="用户名"
prop="userName">
prop="colname">
<el-input
v-model="ruleForm2.userName" name="colname"></el-input>
v-model="ruleForm2.colname" name="colname"></el-input>
</el-form-item>
<el-form-item
label="密码" prop="pass">
label="密码" prop="colpassword">
<el-input type="password"
v-model="ruleForm2.pass" auto-complete="off" name="colpassword"></el-input>
v-model="ruleForm2.colpassword" auto-complete="off" name="colpassword"></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary"
@@ -50,28 +51,38 @@
:model="ruleForm2" status-icon :rules="rules2" ref="ruleForm2"
label-width="100px" class="demo-ruleForm"
action="/cms/register/doregister"
method="POST" name="loginTest">
method="POST" name="register">
<el-form-item label="用户名"
prop="userName">
prop="colname">
<el-input
v-model="ruleForm2.userName" name="userName"></el-input>
v-model="ruleForm2.colname" name="colname"></el-input>
</el-form-item>
<el-form-item
label="密码" prop="pass">
label="密码" prop="colpassword">
<el-input type="password"
v-model="ruleForm2.pass" auto-complete="off" name="passWord"></el-input>
v-model="ruleForm2.colpassword" auto-complete="off" name="colpassword"></el-input>
</el-form-item>
<el-form-item label="确认密码" prop="checkPass">
<el-input
type="password" v-model="ruleForm2.checkPass"
auto-complete="off"></el-input>
auto-complete="off" name="checkPass"></el-input>
</el-form-item>
<el-form-item prop="email" label="邮箱"
<el-form-item prop="colemail" label="邮箱"
:rules="[
{ required: true, message: '请输入邮箱地址', trigger: 'blur' },
{ type: 'email', message: '请输入正确的邮箱地址', trigger: 'blur,change' }
]">
<el-input v-model="ruleForm2.email"></el-input>
<el-input v-model="ruleForm2.colemail" name="colemail"></el-input>
</el-form-item>
<el-form-item label="学号"
prop="colstudentno">
<el-input
v-model="ruleForm2.colstudentno" name="colstudentno"></el-input>
</el-form-item>
<el-form-item label="真实姓名"
prop="colrealname">
<el-input
v-model="ruleForm2.colrealname" name="colrealname"></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary"
@@ -87,7 +98,7 @@
</el-col>
</el-row>
</div>
<script th:src="@{js/LoginStyle.js}"></script>
<script th:src="@{js/loginstyle.js}"></script>
<!--<body>
&lt;!&ndash;<center>
<h1>登录系统</h1>