init
This commit is contained in:
88
ruoyi-ui/public/baidu/huitu.html
Normal file
88
ruoyi-ui/public/baidu/huitu.html
Normal file
@@ -0,0 +1,88 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Document</title>
|
||||
<style>
|
||||
html,
|
||||
body,
|
||||
#box {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
</style>
|
||||
<script type="text/javascript" src="./script/axios.min.js"></script>
|
||||
|
||||
<script>
|
||||
const result = new URLSearchParams(window.location.search)
|
||||
const params = {}
|
||||
for (const [key, value] of result) {
|
||||
params[key] = value
|
||||
}
|
||||
window.NODE_ENV = params.NODE_ENV
|
||||
if(params.NODE_ENV === 'production'){
|
||||
window.ENV_URL = 'http://64.202.32.20:5001'
|
||||
}else{
|
||||
window.ENV_URL = 'http://158.234.96.76:5001'
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="box"></div>
|
||||
<script type="text/javascript" src="./script/index.umd.min.js"></script>
|
||||
<script>
|
||||
const sdk = new QuHuaSdk({
|
||||
ak: 'L7KaAZUYPVSD40nYT09rWWgIdZKUesiX',
|
||||
webAk: 't6k6UC2IZR40Un8kkqM4RXlaQb4FulyM',
|
||||
domId: 'box',
|
||||
defaultCenterCity: "杭州市", // 非必填
|
||||
_baseUrl: window.NODE_ENV === "production" ? "http://64.202.32.20:5001/logisticsWeb-quhua-intranet" : "http://158.234.96.76:5001/logisticsWeb-quhua-intranet", // 固定格式,必填
|
||||
// baseMapId: 'f6ac3fadbe3542adbccc85489935f67d',
|
||||
// defaultLayerId: 'a59d30a64242420382365f40eecc2fdd',
|
||||
// readOnly:true,
|
||||
functionField: {
|
||||
peripheral_search: false,
|
||||
draw_line: false,
|
||||
draw_point: false,
|
||||
editlayers_add_aoi: false,
|
||||
editlayers_add_attribute: false,
|
||||
editlayers_mass_upload: false,
|
||||
editlayers_back_home: true,
|
||||
baseLog: false,
|
||||
administrative: false,
|
||||
textToLine: false,
|
||||
roadPlanSave: false,
|
||||
textToLineLog: false,
|
||||
storeroadLog: false,
|
||||
},
|
||||
eventCallBack: (...arg) => {
|
||||
console.log("===", arg)
|
||||
},
|
||||
whiteList: [
|
||||
{
|
||||
url: '/logistics_region/v1/region/list',
|
||||
method: 'GET'
|
||||
}
|
||||
],
|
||||
whiteListProxy: async(value) => {
|
||||
console.log(value)
|
||||
const response = await axios({
|
||||
...value.newOptions,
|
||||
url: window.ENV_URL + value.url
|
||||
});
|
||||
console.log(response)
|
||||
return response;
|
||||
}
|
||||
});
|
||||
// 一定要卸载
|
||||
//sdk.destroy();
|
||||
</script>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
Reference in New Issue
Block a user