From 0069b25d77cf2dd36b030fa4c86d4f3738f552e8 Mon Sep 17 00:00:00 2001
From: pang.jiabao <pang_jiabao@163.com>
Date: 星期二, 13 五月 2025 08:44:37 +0800
Subject: [PATCH] 跑库测试程序
---
src/main/webapp/views/login.html | 64 +++++++++++++++++++++++++++----
1 files changed, 55 insertions(+), 9 deletions(-)
diff --git a/src/main/webapp/views/login.html b/src/main/webapp/views/login.html
index b657740..e10979a 100644
--- a/src/main/webapp/views/login.html
+++ b/src/main/webapp/views/login.html
@@ -2,7 +2,7 @@
<html>
<head>
<meta charset="utf-8">
- <title>鍐犻缚 鈹� login of zoneyung wcs</title>
+ <title>wcs 鈹� login of wcs</title>
<style>
* {
padding: 0;
@@ -90,7 +90,7 @@
align-items: center;
}
- #login-button {
+ .login-button {
position: relative;
width: 100%;
border: 2px solid #8000ff;
@@ -106,7 +106,7 @@
overflow: hidden;
}
- #login-button::after {
+ .login-button::after {
content: "";
position: absolute;
background-color: rgba(255, 255, 255, 0.253);
@@ -120,7 +120,7 @@
transition-duration: .5s;
}
- #login-button:hover::after {
+ .login-button:hover::after {
transform: translateX(600px);
transition-duration: .5s;
}
@@ -209,12 +209,19 @@
<input placeholder="璇疯緭鍏ュ瘑鐮�" id="password" name="pass" class="inputField" type="password">
</div>
- <input type="button" id="login-button" value="鐧诲綍">
+ <input type="button" id="login-button" class="login-button" value="鐧诲綍">
+
+ <div style="display: none;margin-top: 5px;width: 100%;" id="updateLicense">
+ <form enctype="multipart/form-data" style="display: none;">
+ <input id="license" type="file" name="file" >
+ </form>
+ <input type="button" id="submitLicense" class="login-button" style="margin: 0;" value="鏇存柊璁稿彲璇�">
+ </div>
</div>
</div>
<div class="login-copyright">
- <div class="copyright-text">Copyright 漏2023 娴欐睙涓壃绔嬪簱鎶�鏈湁闄愬叕鍙哥増鏉冩墍鏈�</div>
+<!-- <div class="copyright-text">Copyright 漏2023 wcs</div>-->
<div id="copyright-img1" class="copyright-img">
<img class="copyright-img-url" src="../static/wcs/images/weixin_qrcode.jpg" />
<div id="copyright-img-large1" class="copyright-img-large"><img class="copyright-img-url" src="../static/wcs/images/weixin_qrcode.jpg" /></div>
@@ -239,6 +246,10 @@
$(".copyright-text").text(data.loginCopyrightText);
$(".copyright-img-url").attr("src", data.loginCopyrightImg1);
$(".loginLogoUrl").attr("src", data.loginLogo);
+
+ if (data.loginCopyrightImg1 == "") {
+ $(".copyright-img-url").hide()
+ }
}
});
@@ -283,9 +294,12 @@
layer.tips(res.msg, '#username', {tips: [4, '#ff0000']});
} else if (res.code === 10003) {
layer.tips(res.msg, '#password', {tips: [4, '#ff0000']});
- } else {
- layer.tips(res.msg, '.login-btn', {tips: [3, '#ff0000']});
- }
+ } else if (res.code === 20001) {
+ layer.tips(res.msg, '#login-button', {tips: [3, '#ff0000']});
+ $("#updateLicense").show()
+ } else {
+ layer.tips(res.msg, '#login-button', {tips: [3, '#ff0000']});
+ }
}
});
});
@@ -303,6 +317,38 @@
$("#copyright-img1").on("mouseout", () => {
$("#copyright-img-large1").hide()
})
+
+ //鏇存柊璁稿彲璇�
+ $("#submitLicense").on("click",() => {
+ $("#license").click()
+ })
+
+ //涓婁紶骞舵洿鏂拌鍙瘉
+ $("#license").on("change",(evt) => {
+ var files = evt.target.files;
+ console.log(files)
+ let formData = new FormData();
+ formData.append("file", files[0])
+ $.ajax({
+ url: baseUrl+"/license/updateLicense",
+ data: formData,
+ method: 'POST',
+ cache: false,
+ processData: false,
+ contentType: false,
+ success: function (res) {
+ if (res.code == 200) {
+ layer.msg('鏇存柊鎴愬姛', {time: 1000}, () => {
+ parent.location.reload()
+ });
+ }else{
+ layer.msg(res.msg,{time:2000},() => {
+ parent.location.reload()
+ })
+ }
+ }
+ })
+ })
</script>
</body>
</html>
--
Gitblit v1.9.1