You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

139 lines
3.8 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>登记成功</title>
<script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.4/jquery.min.js"></script>
<script src="./utils.js"></script>
<style>
* {
margin: 0;
padding: 0;
list-style: none;
}
body {
background-color: #F4F5F7;
}
.bg {
position: relative;
width: 100%;
}
.notify {
position: absolute;
left: 50%;
top: 10%;
transform: translate(-50%);
box-sizing: border-box;
display: flex;
flex-direction: column;
align-items: center;
font-size: 15px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #0F5230;
line-height: 25px;
background-image: url("tc.png");
background-size: 100% 100%;
width: 281px;
height: 194px;
padding: 40px 10px 0 10px;
}
.notify span {
text-align: center;
padding: 8px;
height: 124px;
overflow-y: scroll;
}
.info {
position: relative;
width: 100%;
height: 268px;
border-radius: 13px 13px 0 0;
margin-top: -25px;
background-color: #F4F5F7;
box-sizing: border-box;
padding: 23px 13px;
}
.info > div {
width: calc(100vw - 26px);
background-color: #FFFFFF;
box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.08);
border: 1px solid #FFFFFF;
backdrop-filter: blur(5px);
padding: 26px;
box-sizing: border-box;
border-radius: 8px;
}
.info > div > ul {
height: 50px;
display: flex;
align-items: center;
justify-content: space-between;
border-bottom: 1px solid #F4F5F7;
}
</style>
</head>
<body>
<img class="bg" src="bg.jpg" alt="">
<div class="notify">
<span id="notify">
当前风高物燥,极易引发森林火灾,
请您不要在林区及周边用火、吸烟。
不带火种入山,不在林区用火。
</span>
</div>
<div class="info">
<div>
<ul>
<li>进山人员</li>
<li id="name"></li>
</ul>
<ul>
<li>进山时间</li>
<li id="time"></li>
</ul>
<ul>
<li>登记站点</li>
<li id="site"></li>
</ul>
</div>
</div>
</body>
<script>
let message = new $message()
let urlParams = getUrlParse(window.location.search)
let notify = document.getElementById('notify');
let name = document.getElementById('name');
let time = document.getElementById('time');
let site = document.getElementById('site');
if (!urlParams.siteId) {
message('URL参数错误')
}
$.ajax({
method: 'GET',
url: `${URL}/api/FireCodeApp/GetSiteInfo?siteId=${urlParams.siteId}`,
contentType: 'application/json;charset=utf-8',
success: function (response) {
if (response.code === 200) {
let res = response.result
site.innerHTML = res.siteName
time.innerHTML = getNowDate()
name.innerHTML = localStorage.getItem('name');
notify.innerHTML = res.slogan || '当前风高物燥,极易引发森林火灾,<br>请您不要在林区及周边用火、吸烟。<br>不带火种入山,不在林区用火。'
} else {
message("未知错误")
}
}
})
</script>
</html>