创建新仓库
This commit is contained in:
69
static/example/加载arcgis卫图.html
Normal file
69
static/example/加载arcgis卫图.html
Normal file
@ -0,0 +1,69 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Title</title>
|
||||
<script src="../sdk/YJEarth.min.js"></script>
|
||||
<script src="vue.js"></script>
|
||||
<style>
|
||||
body {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="app" class="fullSize">
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
<script>
|
||||
new Vue({
|
||||
el: "#app",
|
||||
data: {
|
||||
sdk: null,
|
||||
},
|
||||
|
||||
async mounted() {
|
||||
await YJ.on()
|
||||
this.createEarth()
|
||||
this.ArcgisWXImagery()
|
||||
// this.ArcgisLWImagery()
|
||||
this.ArcgisBLUEImagery()
|
||||
},
|
||||
methods: {
|
||||
createEarth() {
|
||||
this.sdk = new YJ.YJEarth("app")
|
||||
},
|
||||
ArcgisWXImagery() {
|
||||
//卫星影响
|
||||
let layer = new YJ.Obj.ArcgisWXImagery(this.sdk, {
|
||||
id: 123,
|
||||
show: true,
|
||||
layer_index: 1
|
||||
})
|
||||
console.log(layer)
|
||||
},
|
||||
ArcgisLWImagery() {
|
||||
//路网 尽量不用这个
|
||||
let layer = new YJ.Obj.ArcgisLWImagery(this.sdk, {
|
||||
id: 1234,
|
||||
show: true,
|
||||
layer_index: 2
|
||||
})
|
||||
console.log(layer)
|
||||
},
|
||||
ArcgisBLUEImagery() {
|
||||
//暗黑
|
||||
let layer = new YJ.Obj.ArcgisBLUEImagery(this.sdk, {
|
||||
id: 1234,
|
||||
show: true,
|
||||
layer_index: 3
|
||||
})
|
||||
console.log(layer)
|
||||
}
|
||||
}
|
||||
})
|
||||
</script>
|
Reference in New Issue
Block a user