HuangHai 4 months ago
commit bffc8843b2

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 326 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

@ -0,0 +1,183 @@
<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<!-- <title>长春市教育装备与信息化项目智慧管理系统</title> -->
<title>长春市装备信息管理系统</title>
<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=no" />
<!-- 手机端禁止缩放 -->
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
<!-- <meta name="keywords" content="长春市教育装备与信息化项目智慧管理系统"> -->
<!--关键词,5个左右,单个8汉字以内-->
<!-- <meta name="description" content="长春市教育装备与信息化项目智慧管理系统"> -->
<!--网站描述-->
<!--自己的样式-->
<link href="./tbcss/public.css" rel="stylesheet" type="text/css" />
<link href="./tbcss/SignIn.css" rel="stylesheet" type="text/css">
<script src="./component/pear/jsencrypt.min.js"></script>
<script src="./admin/js/jquery-3.6.0.min.js"></script>
<script src="./component/pear/base64.js"></script>
<!--添加对公用函数库的引用-->
<!-- <script src="lib/common.js"></script>-->
</head>
<body>
<div class="all-content">
<div class="content clearfix">
<div class="left-img">
<img src="./img/left-img_tk.png">
</div>
<div class="right-content clearfix">
<div class="content-name">
<p style="font-size: 20px;font-weight: bolder;margin-left: 70px;color: #6998F4;" id="system_name">长春市装备信息管理系统</p>
<!-- <p style="font-size: 20px;font-weight: bolder;margin-left: -5px;"><img src="./img/title_tk.png"></p> -->
</div>
<form action="" method="post">
<div class="user-name">
<div class="user-name-li">
<img src="./img/user_tb.png">
<input type="text" placeholder="用户名" name="loginName" id="usernameTxt">
</div>
</div>
<div class="password">
<div class="password-li">
<img src="./img/pass_tb.png">
<input type="password" autocomplete="off" placeholder="密码" name="password" id="passwordTxt">
</div>
</div>
<div class="vcode">
<div class="vcode-li">
<img src="./img/v_code_tb.png">
<input type="text" placeholder="验证码" autocomplete="off" name="captcha" id="captchaTxt"
value="dsideal">
<img class="vcode-img" id="userCaptchaImage" src="/QingLong/loginPerson/getCaptcha"
alt="点击图片刷新校验码" style="cursor:pointer" onclick="javascript:refreshCaptcha()" />
</div>
</div>
<input id="loginBtn" class="input-button" type="button" value="登&nbsp;&nbsp;&nbsp;录"
style="background-color: #6998F4;">
</form>
</div>
</div>
</div>
<div class="footer" id="footer">
</div>
<script>
$(function () {
$("#loginBtn").click(function () {
doLogin();
});
});
//刷新验证码
function refreshCaptcha() {
$("#userCaptchaImage").attr("src", "/QingLong/loginPerson/getCaptcha?rnd=" + Math.random().toString().slice(-6));
}
$(document).keydown(function (event) {
if (event.keyCode === 13) {//回车键对应code值为13
doLogin();
}
});
function doLogin() {
var username = $("#usernameTxt").val();
var password = $("#passwordTxt").val();
var captcha = $("#captchaTxt").val();
if (username.length === 0 || password.length === 0) {
alert("用户名或密码不允许为空!")
return;
}
userLogin(username, password, captcha);
}
//用户名登录
function userLogin(username, password, captcha) {
var publicKey = "-----BEGIN PUBLIC KEY-----\MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCcd+0zTY9Gn94iqkQJTlxYnEnCeFsLkk0a7hoAvi2B74VzDVV3xH0ZO9RkXvo1SgCB+uzbEWdrgQkzTqyjfTtgOguu3OnkVxIMJF34ibchTY0LWHGxq1m2gLGuVVqrlu1LtdV0X7xo/5zc8Mr+46veWb86kSpqe6rOAm69WWo5GwIDAQAB\-----END PUBLIC KEY-----";
var encrypt = new JSEncrypt();
encrypt.setPublicKey(publicKey);
if (userLoginCheck(username, password, captcha)) {
$.ajax({
type: "POST",
dataType: "json",
url: "/QingLong/loginPerson/doLogin",
data: {
"username": username,
"password": encrypt.encrypt(password),
"captcha": captcha
},
async: false,
success: function (result) {
if (result.success) {
window.location.href = '/QingLong/index.html';
} else {
alert(result.msg);
if (result.redirect) {
window.location.href = '/QingLong/plogin.html';
}
refreshCaptcha();
}
}
});
}
}
//用户登录检查
function userLoginCheck(username, password, captcha) {
if (username == null || username == "") {
alert("用户名不允许为空!");
return false;
}
if (password == null || password == "") {
alert("密码不允许为空!");
return false;
}
if (captcha == null || captcha == "") {
alert("验证码不允许为空!");
return false;
}
return true;
}
//开启错误提示
function showError(error) {
$(".form-error").find("label").html(error);
$(".form-error").show();
}
getPageInfo();
//获取页面信息
function getPageInfo() {
$.ajax({
type: "GET",
dataType: "json",
url: "/QingLong/global/getGlobalByCodes",
data: {
"global_codes": Base64.encode("system_name,copy_right")
},
async: false,
success: function (result) {
$('title').html(result.data[0].global_value);
$("#system_name").html(result.data[0].global_value);
$("#footer").html(result.data[1].global_value);
}
});
}
</script>
</body>
</html>
Loading…
Cancel
Save