Skip to content

Commit

Permalink
release 1.0.4
Browse files Browse the repository at this point in the history
  • Loading branch information
JserWang committed May 7, 2019
1 parent e8a8629 commit 9452809
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 15 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rc-bmap",
"version": "1.0.3",
"version": "1.0.4",
"main": "lib/index.js",
"repository": {
"type": "git",
Expand Down
23 changes: 9 additions & 14 deletions src/core/Library/HeatMap.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,29 +15,24 @@ class HeatMap {
const options = getHeatMapOptions(config);
this.instance = new global.BMapLib.HeatmapOverlay(options);
this.map.addOverlay(this.instance);
if (config.data) {
this.instance.setDataSet({
max: config.max,
data: config.data,
});
}
this.setData(config);
}

repaint = (config) => {
if (this.instance) {
const options = getHeatMapOptions(config);
this.instance.setOptions(options);
if (config.data) {
this.instance.setDataSet({
max: config.max,
data: config.data,
});
}
this.setData(config);
}
}

setData = () => {

setData = (config) => {
if (config.data) {
this.instance.setDataSet({
max: config.max,
data: config.data,
});
}
}

destroy = () => {
Expand Down

0 comments on commit 9452809

Please sign in to comment.