测试环境配置

This commit is contained in:
lSun 2025-03-28 14:10:28 +08:00
parent 005db7d511
commit e374eed897
2 changed files with 257 additions and 257 deletions

View File

@ -28,7 +28,7 @@
</head> </head>
<body class="layui-layout-body layuimini-all"> <body class="layui-layout-body layuimini-all">
<div class="layui-layout layui-layout-admin"> <div class="layui-layout layui-layout-admin">
<div class="layui-header header"> <div class="layui-header header">
<div class="layui-logo layuimini-logo"></div> <div class="layui-logo layuimini-logo"></div>
@ -129,12 +129,12 @@
</div> </div>
</div> </div>
</div> </div>
<script src="lib/layui-v2.6.3/layui.js" charset="utf-8"></script> <script src="lib/layui-v2.6.3/layui.js" charset="utf-8"></script>
<script src="js/lay-config.js?v=2.0.0" charset="utf-8"></script> <script src="js/lay-config.js?v=2.0.0" charset="utf-8"></script>
<script src="lib/jquery-3.4.1/jquery-3.4.1.min.js" charset="utf-8"></script> <script src="lib/jquery-3.4.1/jquery-3.4.1.min.js" charset="utf-8"></script>
<script src="js/public.js" charset="utf-8"></script> <script src="js/public.js" charset="utf-8"></script>
<script> <script>
layui.use(['jquery', 'layer', 'miniAdmin', 'miniTongji'], function () { layui.use(['jquery', 'layer', 'miniAdmin', 'miniTongji'], function () {
var $ = layui.jquery, var $ = layui.jquery,
layer = layui.layer, layer = layui.layer,
@ -148,7 +148,7 @@
} }
} }
console.log('当前登录的token:' + token); console.log('当前登录的token:' + token);
if (token) { if (false) {
console.log('走的跳转登录'); console.log('走的跳转登录');
sessionStorage.setItem('gz-token', token); sessionStorage.setItem('gz-token', token);
// 校验传过来的token是否合法 // 校验传过来的token是否合法
@ -172,8 +172,8 @@
}, null); }, null);
} else { } else {
console.log('走的自己登录'); console.log('走的自己登录');
window.location = 'page/401.html'; // window.location = 'page/401.html';
// login(miniAdmin); login(miniAdmin);
// window.location = 'page/welcome-1.html'; // window.location = 'page/welcome-1.html';
} }
/* var options = { /* var options = {
@ -226,9 +226,10 @@
// 登录获取token // 登录获取token
let login_url = dataUrl + 'login/userLogin' let login_url = dataUrl + 'login/userLogin'
const params = { const params = {
"username": 'sa', // "username": 'sa',
// "password": '3NBzZK7qxhMhrmvi63FnuQ==', // "password": 'ebbd6ea34bbab2b0813afcf59c8c9556',
"password": 'ebbd6ea34bbab2b0813afcf59c8c9556', "username": 'bns',
"password": '1769fb2837e10e9d22c1c25add76355a',
} }
/* const params = { /* const params = {
"username": 'fgs-check-001', "username": 'fgs-check-001',
@ -290,7 +291,7 @@
errorFn(xhr, status, error) errorFn(xhr, status, error)
}, null); }, null);
} }
</script> </script>
</body> </body>
</html> </html>

View File

@ -1,18 +1,17 @@
const dataUrl = 'http://localhost:21520/'; // 数据请求路径--安全工器具 // const dataUrl = 'http://localhost:21520/aqd_screen/'; // 数据请求路径--安全工器具
const dataUrlDevice = 'http://localhost:21521/'; // 数据请求路径-工器具 // const dataUrlDevice = 'http://localhost:21521/'; // 数据请求路径-工器具
const dataUrlCar = 'http://localhost:21522/'; // 数据请求路径-车辆 // const dataUrlCar = 'http://localhost:21522/gz_car/'; // 数据请求路径-车辆
// const dataUrl = 'http://192.168.0.50:21995/'; // 数据请求路径-亮 // const dataUrl = 'http://192.168.0.50:21995/'; // 数据请求路径-亮
// const fileUrl = 'http://127.0.0.1:21995/statics'; // 文件路径
// const signFileUrl = 'http://127.0.0.1:21995/statics'; // 签名文件路径
// const viewFileUrl = 'http://192.168.0.14:8012/onlinePreview?url=' //14服务器预览文件
const fileUrl = 'http://127.0.0.1:21995/statics'; // 文件路径 const dataUrl = 'http://192.168.0.16:21520/gz-aqgqj/'; // 数据请求路径
const fileUrl = 'http://192.168.0.16:21520/gz-aqgqj/statics'; // 文件路径
const signFileUrl = 'http://127.0.0.1:21995/statics'; // 签名文件路径 const signFileUrl = 'http://127.0.0.1:21995/statics'; // 签名文件路径
const viewFileUrl = 'http://192.168.0.14:8012/onlinePreview?url=' //14服务器预览文件 const viewFileUrl = 'http://192.168.0.14:8012/onlinePreview?url=' //14服务器预览文件
/* const dataUrl = 'http://192.168.0.14:21520/'; // 数据请求路径
const fileUrl = 'http://192.168.0.14:21520/statics'; // 文件路径
const signFileUrl = 'http://127.0.0.1:21995/statics'; // 签名文件路径
const viewFileUrl = 'http://192.168.0.14:8012/onlinePreview?url=' //14服务器预览文件 */
/* 请求 */ /* 请求 */
function ajaxRequest(url, type, data, async, beforeFn, successFn, errorFn, contentType) { function ajaxRequest(url, type, data, async, beforeFn, successFn, errorFn, contentType) {
$.ajax({ $.ajax({