fix marker css

This commit is contained in:
thinkinggis 2019-09-11 11:22:10 +08:00
parent 9146033db3
commit 1eebca1c4c
3 changed files with 13 additions and 3 deletions

View File

@ -48,7 +48,17 @@
.render();
});
$.getJSON('https://gw.alipayobjects.com/os/basement_prod/0b96cca4-7e83-449a-93d0-2a77053e74ab.json', function(data) {
console.log(data);
scene.PointLayer()
.source(data.nodes,{
parser:{
type:'json',
coordinates:'coordinates',
}
})
.shape('circle')
.color('#f00')
.size(8)
.render();
data.nodes.forEach(item=>{
const el = document.createElement('div');
const total = item.gdp.Agriculture + item.gdp.Industry + item.gdp.Service;

View File

@ -1,5 +1,5 @@
.l7-marker {
position: absolute;
position: absolute !important;
top: 0;
left: 0;
z-index: 5;

View File

@ -110,7 +110,7 @@ export default class GaodeMap extends Base {
this.amapContainer = this.map.getContainer().getElementsByClassName('amap-maps')[0];
this.renderDom = document.createElement('div');
this.renderDom.style.cssText +=
'position: absolute;top: 0; z-index:1;height: 100%;width: 100%;pointer-events: none;';
'position: absolute;top: 0;height: 100%;width: 100%;pointer-events: none;';
this.renderDom.id = 'l7_canvaslayer';
this.amapContainer.appendChild(this.renderDom);