修复notify中mail模块的bug
This commit is contained in:
14
test/src/main/resources/application.yml
Normal file
14
test/src/main/resources/application.yml
Normal file
@@ -0,0 +1,14 @@
|
||||
notify:
|
||||
mail:
|
||||
host: smtp.qq.com
|
||||
protocol: smtp
|
||||
default-encoding: UTF-8
|
||||
password: bjmtskwfjrvqdhgb
|
||||
username: 2202043370@qq.com
|
||||
port: 587
|
||||
properties:
|
||||
mail:
|
||||
debug: false
|
||||
stmp:
|
||||
socketFactory:
|
||||
class: javax.net.ssl.SSLSocketFactory
|
@@ -1,129 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
|
||||
<!--${government}-->
|
||||
<!--${title}-->
|
||||
<!--${suggestion}-->
|
||||
<!--${deadline}-->
|
||||
<!--${secret}-->
|
||||
<!--${url}-->
|
||||
<!--${officeName}-->
|
||||
<!--${createTime}-->
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, shrink-to-fit=no">
|
||||
<title>${title}</title>
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/css/bootstrap.min.css">
|
||||
<style>
|
||||
.contact-clean {
|
||||
background: #f1f7fc;
|
||||
padding: 80px 0;
|
||||
}
|
||||
|
||||
a {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
@media (max-width: 767px) {
|
||||
.contact-clean {
|
||||
padding: 20px 0;
|
||||
}
|
||||
}
|
||||
|
||||
.contact-clean form {
|
||||
max-width: 480px;
|
||||
width: 90%;
|
||||
margin: 0 auto;
|
||||
background-color: #ffffff;
|
||||
padding: 40px;
|
||||
border-radius: 4px;
|
||||
color: #505e6c;
|
||||
box-shadow: 1px 1px 5px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
@media (max-width: 767px) {
|
||||
.contact-clean form {
|
||||
padding: 30px;
|
||||
}
|
||||
}
|
||||
|
||||
.contact-clean h2 {
|
||||
margin-top: 5px;
|
||||
font-weight: bold;
|
||||
font-size: 28px;
|
||||
margin-bottom: 36px;
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.contact-clean .form-group:last-child {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
.contact-clean form .form-control {
|
||||
background: #fff;
|
||||
border-radius: 2px;
|
||||
box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.05);
|
||||
outline: none;
|
||||
color: inherit;
|
||||
padding-left: 12px;
|
||||
height: 42px;
|
||||
}
|
||||
|
||||
.contact-clean form .form-control:focus {
|
||||
border: 1px solid #b2b2b2;
|
||||
}
|
||||
|
||||
.contact-clean form textarea.form-control {
|
||||
min-height: 100px;
|
||||
max-height: 260px;
|
||||
padding-top: 10px;
|
||||
resize: vertical;
|
||||
}
|
||||
|
||||
.contact-clean form .btn {
|
||||
padding: 16px 32px;
|
||||
border: none;
|
||||
background: none;
|
||||
box-shadow: none;
|
||||
text-shadow: none;
|
||||
opacity: 0.9;
|
||||
text-transform: uppercase;
|
||||
font-weight: bold;
|
||||
font-size: 13px;
|
||||
letter-spacing: 0.4px;
|
||||
line-height: 1;
|
||||
outline: none !important;
|
||||
}
|
||||
|
||||
.contact-clean form .btn:hover {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.contact-clean form .btn:active {
|
||||
transform: translateY(1px);
|
||||
}
|
||||
|
||||
.contact-clean form .btn-primary {
|
||||
background-color: #055ada !important;
|
||||
margin-top: 15px;
|
||||
color: #fff;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="contact-clean">
|
||||
<form method="post">
|
||||
<h2 class="text-center" th:text="${mail.getSubject()}"></h2>
|
||||
<p th:utext="${mail.getContent()}"></p>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
<span>
|
||||
<strong>注意</strong>本邮件由系统自动发送,请勿回复本邮件,如果邮件内容您并不知情,请忽略本邮件
|
||||
</span>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/js/bootstrap.bundle.min.js"></script>
|
||||
</body>
|
||||
|
||||
</html>
|
Reference in New Issue
Block a user