测试环境

This commit is contained in:
haozq 2026-02-06 10:38:18 +08:00
parent 6333758883
commit 38f3c33c5b
3 changed files with 39 additions and 11 deletions

View File

@ -10,7 +10,15 @@ layui.use(['form', 'layer', 'laydate', 'upload'], function () {
layer = layui.layer;
laydate = layui.laydate;
upload = layui.upload;
let token = getUrlParam('token');
if (!token) {
let gz_token = sessionStorage.getItem("gz-token");
if (gz_token) {
token = gz_token;
}
}else{
sessionStorage.setItem("gz-token",token)
}
// 检查是否有从选择页面返回的数据
checkSelectedData();
@ -46,7 +54,7 @@ layui.use(['form', 'layer', 'laydate', 'upload'], function () {
// 优化下拉选择框宽度
optimizeSelectWidth();
getProList();
// 监听下拉框打开事件,确保宽度一致
$(document).on('click', '.layui-form-select .layui-select-title', function () {
setTimeout(function () {
@ -837,7 +845,7 @@ function closePage() {
}
}
getProList();
// 确认提交
function submitApply() {

View File

@ -8,7 +8,15 @@ layui.use(['form', 'layer', 'laydate', 'upload'], function () {
layer = layui.layer;
laydate = layui.laydate;
upload = layui.upload;
let token = getUrlParam('token');
if (!token) {
let gz_token = sessionStorage.getItem("gz-token");
if (gz_token) {
token = gz_token;
}
}else{
sessionStorage.setItem("gz-token",token)
}
// 检查是否有从选择页面返回的数据
checkSelectedData();
@ -67,7 +75,7 @@ layui.use(['form', 'layer', 'laydate', 'upload'], function () {
}, 50);
}
});
getProList();
// 不拦截layui的搜索事件让layui自己处理过滤
// layui会自动处理搜索过滤我们只需要确保样式正确
});
@ -784,7 +792,7 @@ function closePage() {
}
}
getProList();
// 确认提交
function submitApply() {

View File

@ -1,12 +1,24 @@
// const dataUrl = 'http://localhost:21522/'; // 数据请求路径
// const fileUrl = 'http://127.0.0.1:21522/gz_car/statics'; // 文件路径
const viewFileUrl = 'http://192.168.0.14:8012/onlinePreview?url=' //14服务器预览文件
//本地
const dataUrl = 'http://192.168.0.16:21522/gz-car/'; // 数据请求路径
const fileUrl = 'http://192.168.0.16:21522/gz-car/statics'; // 文件路径
const dataUrl = 'http://127.0.0.1:21522/gz-car/'; // 数据请求路径
const fileUrl = 'http://127.0.0.1:21522/gz-car/statics'; // 文件路径
const signFileUrl = 'http://127.0.0.1:21995/statics'; // 签名文件路径
const viewFileUrl = 'http://192.168.0.14:8012/onlinePreview?url=' //14服务器预览文件 */
// let http=window.location.protocol;
// let host=window.location.host;
// const dataUrl =http+"//"+host+"/gz-car/"
// const fileUrl =http+"//"+host+"/gz-car/statics"
// const viewFileUrl = 'http://192.168.0.14:8012/onlinePreview?url=' //14服务器预览文件 */
//生产文件路径
// const dataUrl ='http://10.1.0.142:1999/gz_car/'; // 数据请求路径
// const fileUrl ='http://10.1.0.142:1999/statics'; // 文件路径
// const viewFileUrl ='http://10.1.0.142:8012/onlinePreview?url=' //14服务器预览文件
//const signFileUrl = 'http://10.1.0.142:1999/statics'; // 签名文件路径
/* 请求 */
function ajaxRequest(url, type, data, async, beforeFn, successFn, errorFn, contentType) {
$.ajax({