Compare commits

...

3 Commits

Author SHA1 Message Date
haozq b1871fbdfa 修改post请求 2024-12-13 14:34:16 +08:00
haozq 323acc427c Merge branch 'main' of http://192.168.0.56:3000/haozq/jjsp_web 2024-12-13 14:33:35 +08:00
haozq 4afb0649bd 越权日志 2024-12-13 14:10:18 +08:00
5 changed files with 36 additions and 22 deletions

View File

@ -6,11 +6,11 @@
<title>系统日志</title>
<!--拦截及公共ip-->
<script src="../../../../js/public/jquery-3.6.0.js" type="text/javascript"></script>
<script src="../../../js/system/IPUtils.js"></script>
<script src="../../../js/system/ajax_intercept.js"></script>
<script src="../../../js/system/public_utils.js"></script>
<script src="../../../js/smutil/sm2Utils.js"></script>
<script src="../../../js/smutil/smUtil.js"></script>
<script src="../../../../js/system/IPUtils.js"></script>
<script src="../../../../js/system/ajax_intercept.js"></script>
<script src="../../../../js/system/public_utils.js"></script>
<script src="../../../../js/smutil/sm2Utils.js"></script>
<script src="../../../../js/smutil/smUtil.js"></script>
<!--拦截及公共ip-->
<link href="../../../../js/layui/css/layui.css" rel="stylesheet">
<script src="../../../../js/layui/layui.js"></script>

View File

@ -352,8 +352,8 @@ function getWzXx(orgId) {
},
error: function (err) {
console.log("err")
}
console.log("err")
}
});
}
@ -427,8 +427,6 @@ function openNewTab(url, id, title) {
$(".layui-nav-item").each(function () {
$(this).removeClass('layui-that');
$(this).removeClass('layui-this');
console.log($(this).text());
console.log($(this).attr("idx"))
if ($(this).text() == '综合展示' && imea == 0) {
$(this).addClass('layui-that');
$(this).addClass('layui-this');

View File

@ -242,7 +242,7 @@ var Ajax = function () {
// post方式需要自己设置http的请求头来模仿表单提交。
// 放在open方法之后send方法之前。
xhr.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
xhr.setRequestHeader('token', token);
xhr.setRequestHeader('Authorization', token);
//xhr.setRequestHeader("key","222"); //将token放在header 里面
if (that.headers != '') {
xhr.setRequestHeader("encrypt", that.headers);
@ -271,7 +271,7 @@ var Ajax = function () {
// 它接受三个参数:请求类型(get、post)、请求的URL和表示是否异步。
xhr.open(that.method, that.url, that.async);
xhr.setRequestHeader('Authorization', token);
xhr.send(null); // get方式则填null
if (that.headers != '') {
xhr.setRequestHeader("encrypt", that.headers);

View File

@ -7,7 +7,7 @@ function getLocalpath(){
let yq=getHtmlPermission(usJosn.menus,url[1]);
console.log(yq)
if(!yq){
console.log(url[1])
addLogs(url,url[1],usJosn.nickName);
top.window.location.href = login_url;
}
}
@ -26,4 +26,20 @@ function getHtmlPermission(menus,html){
}
}
return false;
}
function addLogs(url,urlParam,userName) {
$.ajax({
url: dataUrl + 'system/sys/logs/addLogs' ,
headers: {
'Authorization': localStorage.getItem("tokens")
},
data: {
'userName': userName ,
'operParam': url,
'operMeth': urlParam
},
type: 'post',
success: function () {
}
});
}

View File

@ -14,13 +14,13 @@ function error(event, xhr, settings, er){
console.error(settings);
console.error(er);
}
(() => {
function ban() {
setInterval(() => {
debugger;
}, 50);
}
try {
ban();
} catch (err) { }
})();
// (() => {
// function ban() {
// setInterval(() => {
// debugger;
// }, 50);
// }
// try {
// ban();
// } catch (err) { }
// })();