<!DOCTYPE html>
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
<head>
|
<title>上传接口测试</title>
|
<meta http-equiv="Expires" content="0" />
|
<meta http-equiv="Cache" content="no-cache" />
|
<meta http-equiv="Pragma" content="no-cache" />
|
<meta http-equiv="Cache-control" content="no-cache" />
|
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
<script src="js/jquery.1.12.4.js"></script>
|
<script src="js/rsa.min.js"></script>
|
<script src="js/rollups.js"></script>
|
<script src="js/turf.min.6.5.js"></script>
|
<script src="js/insertFiles.js"></script>
|
<script>
|
var app = {};
|
var path = "20230803";
|
var url = "http://127.0.0.1:12316/server/";
|
//var token = "c36e4f94-dfde-401e-9967-2c4a449f1300";
|
var token = "50b3fd35-7f5b-471e-974c-6240da4b3855";
|
|
$(function () {
|
//var flag = testArcGISServer();
|
|
$("#pathSpan").html(path);
|
$("#tokenSpan").html(token);
|
//getPublicKey();
|
});
|
|
// Ajax
|
function ajax(url, type, data, dataType, contentType, fn) {
|
$.ajax({
|
url: url,
|
type: type,
|
data: data,
|
dataType: dataType || "json", // html、json、jsonp、script、text
|
contentType: contentType || "application/json", // "application/x-www-form-urlencoded"
|
success: function (data) {
|
fn(data);
|
},
|
error: function (e) {
|
console.error(e);
|
}
|
});
|
}
|
|
// 获取URL
|
function getUrl(method) {
|
return url + method + "?token=" + token;
|
}
|
|
function getPublicKey() {
|
$.get(url + "sign/getPublicKey", function (rs) {
|
if (rs && rs.code == 200) {
|
window.encrypt = new JSEncrypt();
|
encrypt.setPublicKey(rs.result);
|
}
|
});
|
}
|
</script>
|
<script>
|
// 查询目录
|
function selectPath() {
|
ajax(getUrl("dataUpload/selectPath"), "GET", null, null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
path = rs.result;
|
});
|
}
|
|
// 上传文件
|
function uploadFiles() {
|
var formData = new FormData();
|
var fs = document.getElementById("file1");
|
for (var i = 0, c = fs.files.length; i < c; i++) {
|
formData.append(fs.files[i].name, fs.files[i]); // fs.files[i].name,file
|
}
|
|
$.ajax(getUrl("dataUpload/uploadFiles") + "&path=" + path, {
|
type: "post",
|
data: formData,
|
async: true,
|
cache: false,
|
processData: false,
|
contentType: false,
|
success: function (rs) {
|
document.getElementById("file1").value = "";
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
},
|
error: function (e) {
|
document.getElementById("file1").value = "";
|
console.error(e);
|
alert("上传文件失败!");
|
}
|
});
|
}
|
|
// 查询文件
|
function selectFiles() {
|
ajax(getUrl("dataUpload/selectFiles") + "&path=" + path, "GET", null, null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
app.data = rs.result;
|
});
|
}
|
|
// 删除文件
|
function deleteFiles() {
|
if (app.data == null) return;
|
|
ajax(getUrl("dataUpload/deleteFiles"), "POST", JSON.stringify([data[0]]), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
selectFiles();
|
});
|
}
|
|
// 读取映射
|
function readMappers() {
|
ajax(getUrl("dataUpload/selectMappers") + "&path=" + path + "&dirid=163&verid=0&epsgCode=EPSG:4490", "GET", null, null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
if (rs.code == 200) {
|
app.mappers = rs.result;
|
}
|
});
|
}
|
|
// Xls入库
|
function insertXls() {
|
ajax(getUrl("dataUpload/insertFiles"), "POST", JSON.stringify(xlsFiles), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
</script>
|
<script>
|
// 上传附件
|
function uploadAttach() {
|
var formData = new FormData();
|
var fs = document.getElementById("file3");
|
if (fs.files.length == 0) {
|
alert("请选择要上传的文件!");
|
return;
|
}
|
for (var i = 0, c = fs.files.length; i < c; i++) {
|
formData.append("file", fs.files[i]); // fs.files[i].name,file
|
}
|
|
$.ajax(getUrl("dataQuery/uploadFiles") + "&tabName=lf.sys_style&eventid=fa25979a5ef8b43ba82a0be35b3fb0d4", {
|
type: "post",
|
data: formData,
|
async: true,
|
cache: false,
|
processData: false,
|
contentType: false,
|
success: function (rs) {
|
console.log(rs);
|
document.getElementById("file3").value = "";
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
},
|
error: function (e) {
|
console.error(e);
|
document.getElementById("file3").value = "";
|
alert("上传文件失败!");
|
}
|
});
|
}
|
</script>
|
<script>
|
// 元数据-请求下载
|
function metaDownloadReq() {
|
var obj = {
|
pwd: encrypt.encrypt("Test!321&456"),
|
ids: [1411, 1412, 8, 2140]
|
};
|
|
ajax(getUrl("meta/downloadReq"), "POST", JSON.stringify(obj), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 下载文件
|
function selectDownloadFile() {
|
var guid = $.trim($("#fileId").val()); // var guid = "55269c88c147fb894c27e3de7076877d";
|
if (!guid) return;
|
var pwd = encodeURIComponent(encrypt.encrypt("Test!321&456")); // Admin@123
|
|
ajax(getUrl("meta/selectDownloadFile") + "&guid=" + guid + "&pwd=" + pwd, "GET", null, null, null, function (rs) {
|
console.log(rs);
|
//alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
if (rs.code != 200 || !rs.result) {
|
alert(rs.msg);
|
return;
|
}
|
|
downloadFile(guid, pwd);
|
});
|
}
|
|
function downloadFile(guid, pwd) {
|
//var a = document.createElement('a');
|
//a.style.display = 'none';
|
//a.href = getUrl("meta/downloadFile") + "&guid=" + guid + "&pwd=" + encodeURIComponent(encrypt.encrypt("Admin@123"));
|
|
//document.body.appendChild(a);
|
//a.click();
|
//document.body.removeChild(a);
|
|
var url = getUrl("meta/downloadFile") + "&guid=" + guid + "&pwd=" + pwd;
|
$("#downFrame").attr("src", url).click();
|
}
|
</script>
|
<script>
|
// 请求下载
|
function downloadReq() {
|
var obj = {
|
pwd: encrypt.encrypt("Test!321&456"),
|
entities: ["dlgagnp", "dlg25wboul", "dlg25wresa"],
|
// entities: ["dlgagnp"],
|
wkt: aesEncrypt("POLYGON ((115.949 32.375 0,121.989 32.276 0,121.850 29.687 0,115.972 29.783 0,115.949 32.375 0))")
|
};
|
|
ajax(getUrl("dataLib/downloadDbReq"), "POST", JSON.stringify(obj), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 下载DB数据
|
function downloadDbData() {
|
var obj = {
|
pwd: encrypt.encrypt("Test!321&456"),
|
entities: ["dlgagnp", "dlg25wboul", "dlg25wresa"], // "sexplorationpoint"
|
filter: "gid > 1", // "exppointid like 'EA12'"
|
//ids: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10],
|
dirs: "01,02,03,04,06,07",
|
depcode: "00",
|
wkt: aesEncrypt("POLYGON ((115.949 32.375 0,121.989 32.276 0,121.850 29.687 0,115.972 29.783 0,115.949 32.375 0))")
|
};
|
|
ajax(getUrl("dataLib/downloadDbData"), "POST", JSON.stringify(obj), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
var codes = "QSNzX3paM3NlUnZlX2sueQ=="; // "QSNzX2xGX3NFcnZlX2sueQ==";
|
function aesEncrypt(word) {
|
return CryptoJS.AES.encrypt(CryptoJS.enc.Utf8.parse(word), CryptoJS.enc.Utf8.parse(base64Decode(codes)), { mode: CryptoJS.mode.ECB, padding: CryptoJS.pad.Pkcs7 }).toString();
|
}
|
|
function aesDecrypt(word) {
|
return CryptoJS.enc.Utf8.stringify(CryptoJS.AES.decrypt(word, CryptoJS.enc.Utf8.parse(base64Decode(codes)), { mode: CryptoJS.mode.ECB, padding: CryptoJS.pad.Pkcs7 })).toString();
|
}
|
</script>
|
<script>
|
// 查询元数据中溢出的单位ID
|
function selectMetaOverflowDep() {
|
ajax(getUrl("meta/selectMetaOverflowDep"), "POST", JSON.stringify({ ids: [1393, 1392, 1383, 1382] }), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 插入元数据申请
|
function insertMetaApply() {
|
/*var obj = {
|
ids: [1393, 1392, 1383, 1382],
|
pwd: aesEncrypt("Test!321&456"),
|
tabs: ["元数据表"],
|
entities: ["sysmeta"],
|
descr: "测试元数据申请~",
|
depcodes: ["00"]
|
};*/
|
var obj = {
|
ids: [7095, 7079],
|
pwd: aesEncrypt("Test!321&456"),
|
tabs: ["元数据表"],
|
entities: ["sysmeta"],
|
descr: "测试元数据申请~",
|
depcodes: ["00"],
|
descr: "请审核~"
|
};
|
|
ajax(getUrl("apply/insertApply"), "POST", JSON.stringify(obj), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
function selectDbOverflowDep() {
|
//selectDbOverflowDep4Wkt();
|
//selectDbOverflowDep4Prop1();
|
selectDbOverflowDep4Prop2();
|
}
|
|
function selectDbOverflowDep4Wkt() {
|
var obj = {
|
entities: ["dlgagnp", "dlg25wboul", "dlg25wresa"],
|
wkt: aesEncrypt("POLYGON ((115.94927385452 32.3754479115071 0,121.989371092554 32.2766788010181 0,121.850621222894 29.6874200067864 0,115.9727267226 29.7835368627922 0,115.94927385452 32.3754479115071 0))")
|
};
|
|
ajax(getUrl("dataLib/selectDbOverflowDep"), "POST", JSON.stringify(obj), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
function selectDbOverflowDep4Prop1() {
|
var obj = {
|
entities: ["dlgagnp"],
|
filter: "name like '县'"
|
};
|
|
ajax(getUrl("dataLib/selectDbOverflowDep"), "POST", JSON.stringify(obj), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
function selectDbOverflowDep4Prop2() {
|
var obj = {
|
entities: ["dlgagnp"],
|
ids: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
|
};
|
|
ajax(getUrl("dataLib/selectDbOverflowDep"), "POST", JSON.stringify(obj), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
function insertApply() {
|
var obj = {
|
ids: [20, 21, 22],
|
pwd: aesEncrypt("Test!321&456"),
|
tabs: ["城市点", "行政区划线", "居民地面"],
|
entities: ["dlgagnp", "dlg25wboul", "dlg25wresa"],
|
wkt: aesEncrypt("POLYGON ((115.94927385452 32.3754479115071 0,121.989371092554 32.2766788010181 0,121.850621222894 29.6874200067864 0,115.9727267226 29.7835368627922 0,115.94927385452 32.3754479115071 0))"),
|
descr: "用于生产项目,请批准"
|
};
|
|
ajax(getUrl("apply/insertApply"), "POST", JSON.stringify(obj), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 综合数据入库
|
function insertAllFiles() {
|
app.mappers = metaFiles;
|
ajax(getUrl("dataUpload/insertFiles"), "POST", JSON.stringify(app.mappers), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 多文件入库
|
function insertMultiFiles() {
|
if (!app.mappers) return;
|
ajax(getUrl("dataUpload/insertFiles"), "POST", JSON.stringify(app.mappers), null, null, function (rs) {
|
console.log(rs);
|
app.mappers = null;
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 挂载附件
|
function uploadAnnex() {
|
var formData = new FormData();
|
var fs = document.getElementById("file1");
|
if (fs.files.length == 0) {
|
alert("请选择要上传的文件!");
|
return;
|
}
|
for (var i = 0, c = fs.files.length; i < c; i++) {
|
formData.append("file", fs.files[i]); // fs.files[i].name,file
|
}
|
formData.append("ids", 1658);
|
//formData.append("ids", 1180);
|
//formData.append("ids", 1387);
|
|
//$.ajax(getUrl("dataUpload/uploadXlsAnnex") + "&path=" + path + "&ids=1209&ids=1180&ids=1387", {
|
$.ajax(getUrl("dataUpload/uploadXlsAnnex") + "&path=" + path, {
|
type: "post",
|
data: formData,
|
async: true,
|
cache: false,
|
processData: false,
|
contentType: false,
|
success: function (rs) {
|
console.log(rs);
|
document.getElementById("file1").value = "";
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
},
|
error: function (e) {
|
console.error(e);
|
document.getElementById("file3").value = "";
|
alert("上传文件失败!");
|
}
|
});
|
}
|
|
// 空间数据入库
|
function insertDbFiles() {
|
ajax(getUrl("dataUpload/insertFiles"), "POST", JSON.stringify(dbFiles), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 请求管线分析
|
function selectPipeAnalysis() {
|
var data = {
|
gid: 24,
|
tabs: ["bd.dlg_25w_hydl", "bd.dlg_25w_lrdl", "bd.dlg_25w_lrrl", "bd.dlg_25w_hyda"]
|
};
|
ajax(getUrl("pipeline/selectPipeAnalysis"), "POST", JSON.stringify(data), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 管线分析结果下载
|
function downloadPipeAnalysis() {
|
var data = {
|
pwd: encrypt.encrypt("Test!321&456"),
|
gid: 24,
|
tabs: ["bd.dlg_25w_hydl", "bd.dlg_25w_lrdl", "bd.dlg_25w_lrrl", "bd.dlg_25w_hyda"]
|
};
|
ajax(getUrl("pipeline/downloadReq"), "POST", JSON.stringify(data), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 附件下载1-样式表
|
function downloadReqForGuids() {
|
var data = {
|
guids: ["e5b6ae0889b88111f13a4b6e048348db", "fa4f299e901a0c46e634f8fcc8185c0c"]
|
};
|
ajax(getUrl("res/downloadReqForGuids"), "POST", JSON.stringify(data), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 附件下载2-附件表
|
function downloadReqForTabGuids() {
|
var data = {
|
tab: "bd.b_borehole",
|
guids: ["08e5b4ad-93b8-46f6-adaa-46a6274af4ce", "6f94f4f8-6e8d-44e7-8803-3d068d34983f"]
|
};
|
ajax(getUrl("res/downloadReqForTabGuids"), "POST", JSON.stringify(data), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 生成缓冲区
|
function generateBuffer() {
|
var strs = $("#inpPoint").val().replace("POINT (", "").replace(")", "").split(" ");
|
var x = parseFloat(strs[0]), y = parseFloat(strs[1]);
|
|
var buffer = parseFloat($("#buffer").val()) / 1000;
|
var steps = parseInt($("#steps").val());
|
//var point = turf.point([x, y]);
|
//var buffered = turf.buffer(point, buffer, { units: 'kilometers', steps: 16 });
|
//var options = { precision: 6, coordinates: 2 };
|
//var truncated = turf.truncate(buffered, options);
|
|
var circle = turf.circle([x, y], buffer, { steps: steps, units: 'kilometers' });
|
var cc = turf.truncate(circle, { precision: 6, coordinates: 2 });
|
|
var arr = [], cs = cc.geometry.coordinates[0];
|
for (var i = 0, c = cs.length; i < c; i++) {
|
arr.push(cs[i][0] + " " + cs[i][1]);
|
}
|
var wkt = "POLYGON((" + arr.join(",") + "))";
|
|
$("#oupArea").html(wkt);
|
}
|
|
// 测试发布
|
function testPublish() {
|
var type = $("#selectPubType").find("option:selected").text().split("(")[0];
|
var vals = $("#selectPubType").find("option:selected").val();
|
console.log("测试发布", type, vals);
|
|
var data = { "ids": vals.split(","), "type": type, "name": "DOM_0.2m", "min": 12, "max": 18, depcode: "000305", dircode: "0102" };
|
ajax(getUrl("publish/insertForPub"), "POST", JSON.stringify(data), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// 下载瓦片
|
function downloadTiles() {
|
var data = {
|
pwd: encrypt.encrypt("Test!321&456"),
|
//pubid: 15, xmin: 112.9534213185, ymin: 32.1588839103, xmax: 112.9734893228, ymax: 32.1736306779
|
pubid: 15, xmin: 112.943013, ymin: 32.158525, xmax: 112.974408, ymax: 32.174741
|
};
|
ajax(getUrl("inquiry/downloadTiles"), "POST", JSON.stringify(data), null, null, function (rs) {
|
console.log(rs);
|
alert("code = " + rs.code + ", msg = " + rs.msg + ", result = " + rs.result);
|
});
|
}
|
|
// downFrame
|
function downFastbeeFile() {
|
var url = "http://192.168.11.203/prod-api/model/downloadFile?guid=babbfbedd596f2dfd6b45c1f17e6861b";
|
var token = "Bearer " + "eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6IjM1MmJlZGQxLTg0YzctNDQxNC1hODA0LTg5NzU0NjU3NDEwMyJ9.agRhJllLb8IrUk5VhZKJBdyu8SaW2H_-PFgmot5ZlsIJQv-pqsdcdH0jlwnh0nuFc7qLf0NdR59v1yYqnnbZhA";
|
|
/*var xhr = new XMLHttpRequest();
|
xhr.open("GET", url);
|
xhr.setRequestHeader("Authorization", token);
|
xhr.onload = function (res, status, xhr) {
|
var url = URL.createObjectURL(res.currentTarget.response);
|
var filename = decodeURL(res.headers['content-disposition'].split("filename="))[1];
|
var link = document.createElement('a');
|
link.style.display = 'none';
|
link.href = downloadUrl;
|
link.setAttribute('download', filename);
|
document.body.appendChild(link);
|
link.click();
|
// 释放URL对象所占资源
|
URL.revokeObjectURL(downloadUrl);
|
// 销毁节点
|
document.body.removeChild(link);
|
};
|
xhr.send();*/
|
|
//Admin-Token=eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6IjFiNDI0NWU0LWViY2MtNDc3Ni1hNDQ0LTc5MzdiYzk3YjUwMiJ9.agyF7aFvfm4JzFAuWtRCPWnagjlpL-O792r-6ihyCXRHXMlim6MF5D6ZU3Mvy33DmP6gAKVjc4l-KlCs7cCZ9A
|
|
//$("#downFrame").attr("src", url).click();
|
|
var doc = document.getElementById("downFrame").contentWindow.document;
|
doc.cookie = "Admin-Token=eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6IjFiNDI0NWU0LWViY2MtNDc3Ni1hNDQ0LTc5MzdiYzk3YjUwMiJ9.agyF7aFvfm4JzFAuWtRCPWnagjlpL-O792r-6ihyCXRHXMlim6MF5D6ZU3Mvy33DmP6gAKVjc4l-KlCs7cCZ9A" + "; path=/;";
|
|
$("#downFrame").attr("src", url).click();
|
}
|
|
function readSignal() {
|
/*var xhr = new XMLHttpRequest();
|
xhr.open("GET", "http://192.168.11.69:8086/cs/getSignalByTime?time=202407130000");
|
xhr.onload = function () {
|
if (xhr.status == 200) {
|
var bytes = xhr.response;
|
//var buffer = xhr.
|
|
var dv = new DataView(buffer);
|
for (var i = 0, c = dv.byteLength; i < c; i += 10) {
|
var x = dv.getFloat16(i, true);
|
var y = dv.getFloat16(i + 4, true);
|
var v = dv.getInt16(i + 6, true);
|
console.log("x=" + x + " y=" + y + " v=" + v);
|
}
|
}
|
}
|
xhr.send();*/
|
|
$.ajax({
|
method: "GET",
|
responseType: "arraybuffer",
|
url: "http://192.168.11.69:8086/cs/getSignalByTime?time=202407171500",
|
success: function (rs, s, e) {
|
var b = new Blob([rs]);
|
b.arrayBuffer().then(function (buffer) {
|
var dv = new DataView(buffer);
|
for (var i = 0, c = dv.byteLength; i < c; i += 10) {
|
var x = dv.getFloat32(i, true);
|
var y = dv.getFloat32(i + 4, true);
|
var v = dv.getInt16(i + 6, true);
|
console.log("i=" + i + " x=" + x + " y=" + y + " v=" + v);
|
}
|
});
|
}
|
});
|
}
|
</script>
|
</head>
|
<body>
|
<!--<form id="upForm" name="upForm" method="post" enctype="multipart/form-data" action="http://127.0.0.1:12316/file/upload">-->
|
<form id="upForm" name="upForm" method="post" enctype="multipart/form-data" action="Upload/Post?path=20230728">
|
上传路径:<span id="pathSpan"></span>,当前令牌:<span id="tokenSpan"></span>
|
<hr />
|
<br />
|
|
数据入库:
|
<input id="file1" type="file" multiple="multiple" accept=".xls,.xlsx,.mdb,.zip" />
|
<input value="查询目录 *" type="button" onclick="selectPath();" />
|
<input value="上传文件" type="button" onclick="uploadFiles();" />
|
<input value="查询文件 *" type="button" onclick="selectFiles();" />
|
<input value="删除文件" type="button" onclick="deleteFiles();" />
|
<input value="Xls入库" type="button" onclick="insertXls();" />
|
<input value="读取映射 *" type="button" onclick="readMappers();" />
|
<input value="综合数据入库 *" type="button" onclick="insertAllFiles();" />
|
<input value="空间数据入库 *" type="button" onclick="insertDbFiles();" />
|
<input value="多文件入库 *" type="button" onclick="insertMultiFiles();" />
|
<input value="挂载附件 *" type="button" onclick="uploadAnnex();" />
|
<hr />
|
<br />
|
|
数据检索:
|
<input id="file3" type="file" multiple="multiple" />
|
<input value="上传附件" type="button" onclick="uploadAttach();" />
|
<hr />
|
<br />
|
|
元数据:
|
<input value="查询元数据中溢出的单位ID" type="button" onclick="selectMetaOverflowDep();" />
|
<input value="插入元数据申请" type="button" onclick="insertMetaApply();" />
|
<input value="请求下载" type="button" onclick="metaDownloadReq();" />
|
<input value="下载文件" type="button" onclick="selectDownloadFile();" />
|
<iframe id="downFrame" src="" style="display: none; border: 0; padding: 0; height: 0; width: 0"></iframe>
|
<hr />
|
<br />
|
|
空间数据:
|
<!--<input value="请求下载" type="button" onclick="downloadReq();" />-->
|
<input id="fileId" value="" type="text" />
|
<input value="下载文件" type="button" onclick="selectDownloadFile();" />
|
<input value="下载DB数据" type="button" onclick="downloadDbData();" />
|
<hr />
|
<br />
|
|
数据申请:
|
<input value="查询DB中溢出的单位ID" type="button" onclick="selectDbOverflowDep();" />
|
<input value="插入数据申请" type="button" onclick="insertApply();" />
|
<input value="请求管线分析" type="button" onclick="selectPipeAnalysis();" />
|
<input value="管线分析结果下载" type="button" onclick="downloadPipeAnalysis();" />
|
<hr />
|
<br />
|
|
附件下载:
|
<input value="附件下载1" type="button" onclick="downloadReqForGuids();" />
|
<input value="附件下载2" type="button" onclick="downloadReqForTabGuids();" />
|
<hr />
|
|
Turf:
|
<input id="inpPoint" type="text" value="POINT (100.746244878 35.588071316)" style="width: 256px;" />
|
<input id="buffer" value="1" type="text" style="width: 30px;" />米
|
<input id="steps" value="8" type="text" style="width: 30px;" />步数
|
<textarea id="oupArea" style="width: 512px; vertical-align: bottom;"></textarea>
|
<input value="生成" type="button" onclick="generateBuffer();" />
|
<hr />
|
<br />
|
|
发布管理:
|
<select id="selectPubType">
|
<option value="1526,1527" selected="selected">DOM</option>
|
<option value="1521">BIM(rvt)</option>
|
<option value="1522">BIM(fbx)</option>
|
<option value="1528">BIM(ifc)</option>
|
<option value="1523">3DML</option>
|
<option value="1525">MPT</option>
|
</select>
|
<input value="测试发布" type="button" onclick="testPublish();" />
|
<input value="下载瓦片" type="button" onclick="downloadTiles();" />
|
<hr />
|
<br />
|
|
上传测试:
|
<div>
|
<label for="apifiles">请选择文件:</label>
|
<input name="apifiles" type="file" multiple="multiple" />
|
<input type="submit" value="Upload" />
|
</div>
|
|
Fastbee下载文件:<input value="蜂信下载" type="button" onclick="downFastbeeFile();" />
|
<input value="读取信令" type="button" onclick="readSignal();" />
|
<hr />
|
<br />
|
</form>
|
<br />
|
<br />
|
</body>
|
</html>
|