From 401da88caef79968c8c0b1cb15487c4a554761ec Mon Sep 17 00:00:00 2001
From: zhangchao <zc857179121@qq.com>
Date: 星期三, 23 十月 2024 14:37:04 +0800
Subject: [PATCH] 测试环境暂时注释
---
src/main/webapp/views/login.html | 48 ++++++++++++++++++++++++++++++++++++++++++++----
1 files changed, 44 insertions(+), 4 deletions(-)
diff --git a/src/main/webapp/views/login.html b/src/main/webapp/views/login.html
index 2a45e5c..b2d5d1b 100644
--- a/src/main/webapp/views/login.html
+++ b/src/main/webapp/views/login.html
@@ -52,7 +52,7 @@
z-index: 100;
top: 22px;
left: 20px;">
- <img src="../static/image/logo.png" alt="" style="width: 20%">
+ <img src="../static/image/logo2.png" alt="" style="width: 20%">
</div>
<div class="p-sketch-outline">
<h2 class="p-sketch-outline__title">Automatic Storage and Retrieval System</h2>
@@ -66,9 +66,9 @@
<div id="sidebar">
<div class="login-contain">
<div class="login-box">
- <img src="../static/image/logo.png" alt="" style="width: 80%">
- <span class="login100-form-title p-t-20 p-b-45">涓壃绔嬪簱</span>
- <span class="login100-form-title p-t-20 p-b-45" style="margin: 15px 0;color: #868686;font-size: 24px">WMS</span>
+ <img src="../static/image/logo1.png" alt="" style="width: 80%">
+<!-- <span class="login100-form-title p-t-20 p-b-45">涓壃绔嬪簱</span>-->
+<!-- <span class="login100-form-title p-t-20 p-b-45" style="margin: 15px 0;color: #868686;font-size: 24px">WMS</span>-->
<div class="wrap-input100 validate-input m-b-10" data-validate="璇疯緭鍏ョ敤鎴峰悕">
<input id="username" class="input100" type="text" name="username" placeholder="username" autocomplete="off">
<span class="focus-input100"></span>
@@ -85,6 +85,12 @@
</div>
<div class="container-login100-form-btn p-t-10">
<button class="login100-form-btn login-btn">Login</button>
+ </div>
+ <div class="container-login100-form-btn p-t-10" style="display: none;margin-top: 50px;" id="updateLicense">
+ <form enctype="multipart/form-data" style="display: none;">
+ <input id="license" type="file" name="file" >
+ </form>
+ <button class="login100-form-btn" id="submitLicense">鏇存柊璁稿彲璇�</button>
</div>
</div>
</div>
@@ -139,6 +145,9 @@
layer.tips(res.msg, '#username', {tips: [4, '#ff0000']});
} else if (res.code === 10003) {
layer.tips(res.msg, '#password', {tips: [4, '#ff0000']});
+ } else if (res.code == 20001) {
+ layer.tips(res.msg, '.login-btn', {tips: [3, '#ff0000']});
+ $("#updateLicense").show()
} else {
layer.tips(res.msg, '.login-btn', {tips: [3, '#ff0000']});
}
@@ -151,6 +160,37 @@
$(".login-btn").click();
}
});
+
+ //鏇存柊璁稿彲璇�
+ $("#submitLicense").on("click",() => {
+ $("#license").click()
+ })
+
+ //涓婁紶骞舵洿鏂拌鍙瘉
+ $("#license").on("change",(evt) => {
+ var files = evt.target.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