You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
148 lines
3.7 KiB
148 lines
3.7 KiB
11 months ago
|
<!DOCTYPE html>
|
||
|
<html xmlns:th="http://www.thymeleaf.org">
|
||
|
<html lang="zh-CN">
|
||
|
|
||
|
<head>
|
||
|
<meta charset="UTF-8">
|
||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||
|
<title>添加联系人</title>
|
||
|
<style>
|
||
|
* {
|
||
|
margin: 0;
|
||
|
padding: 0;
|
||
|
box-sizing: border-box;
|
||
|
}
|
||
|
|
||
|
a {
|
||
|
text-decoration: none;
|
||
|
color: black;
|
||
|
}
|
||
|
|
||
|
button,
|
||
|
input {
|
||
|
border: 0;
|
||
|
outline: none;
|
||
|
}
|
||
|
|
||
|
section {
|
||
|
border-radius: 15px;
|
||
|
width: 560px;
|
||
|
height: 700px;
|
||
|
margin: 0 auto;
|
||
|
background-image: url(../static/bg2.jpg);
|
||
|
box-shadow: 10px 10px 10px 10px rgba(0, 0, 0, .1);
|
||
|
}
|
||
|
|
||
|
.title {
|
||
|
width: 560px;
|
||
|
height: 100px;
|
||
|
line-height: 100px;
|
||
|
text-align: center;
|
||
|
}
|
||
|
|
||
|
.xinxi {
|
||
|
width: 560px;
|
||
|
height: 400px;
|
||
|
font-size: 20px;
|
||
|
text-align: center;
|
||
|
|
||
|
}
|
||
|
|
||
|
tr td {
|
||
|
height: 100px;
|
||
|
text-align: center;
|
||
|
line-height: 100px;
|
||
|
}
|
||
|
|
||
|
.name,
|
||
|
.php {
|
||
|
width: 249px;
|
||
|
height: 30px;
|
||
|
}
|
||
|
|
||
|
.submit {
|
||
|
width: 200px;
|
||
|
height: 30px;
|
||
|
color: aqua;
|
||
|
border-radius: 5px;
|
||
|
}
|
||
|
|
||
|
.submit:hover {
|
||
|
background-color: skyblue;
|
||
|
cursor: pointer;
|
||
|
}
|
||
|
|
||
|
footer {
|
||
|
width: 560px;
|
||
|
height: 100px;
|
||
|
font-size: 20px;
|
||
|
text-align: center;
|
||
|
line-height: 100px;
|
||
|
}
|
||
|
|
||
|
footer a {
|
||
|
display: block;
|
||
|
margin: 0 auto;
|
||
|
width: 560px;
|
||
|
height: 100px;
|
||
|
}
|
||
|
|
||
|
footer a:hover {
|
||
|
color: aqua;
|
||
|
}
|
||
|
</style>
|
||
|
</head>
|
||
|
|
||
|
<body>
|
||
|
<section class="add">
|
||
|
<header class="title">
|
||
|
<h1>添加联系人</h1>
|
||
|
</header>
|
||
|
<div class="xinxi">
|
||
|
<form th:action="@{/add_user_data}" target="_self" >
|
||
|
<table width="600px">
|
||
|
<tr>
|
||
|
<td><label for="m">添加的联系人姓名:</label></td>
|
||
|
<td><input class="name" type="text" id="m" name="name" placeholder="请输入联系人姓名" required="required"></td>
|
||
|
</tr>
|
||
|
<!-- <tr>-->
|
||
|
<!-- <td>性别:</td>-->
|
||
|
<!-- <td><label for="nan">男</label><input type="radio" name="sex" id="nan"> -->
|
||
|
<!-- <label for="nv">女</label><input type="radio" name="sex" id="nv">-->
|
||
|
<!-- </td>-->
|
||
|
<!-- </tr>-->
|
||
|
<tr>
|
||
|
<td><label for="php">电话号码:</label></td>
|
||
|
<td><input class="php" type="password" id="php" name="contact_phone_number" placeholder="请输入电话号码" required="required">
|
||
|
</td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td colspan="2"><input class="submit" type="submit" value="确认添加" name="上传"></td>
|
||
|
</tr>
|
||
|
|
||
|
|
||
|
</table>
|
||
|
|
||
|
</form>
|
||
|
<div id="message"><p></p></div>
|
||
|
</div>
|
||
|
<footer>
|
||
|
<a th:href="@{/data}">返回联系人列表</a>
|
||
|
</footer>
|
||
|
</section>
|
||
|
|
||
|
|
||
|
|
||
|
</body>
|
||
|
<script th:inline="javascript">
|
||
|
var message = [[${message}]];
|
||
|
if(message != null){
|
||
|
var p = document.querySelector("p");
|
||
|
p.innerText = message;
|
||
|
p.style.color='red';
|
||
|
console.log(message);
|
||
|
}
|
||
|
console.log("message");
|
||
|
</script>
|
||
|
|
||
|
</html>
|