|
@ -102,6 +102,13 @@ export class MarkerCluster { |
|
|
"font-size:15px; background:#6f5757; color:#b39b9b;", |
|
|
"font-size:15px; background:#6f5757; color:#b39b9b;", |
|
|
this.infoWindow |
|
|
this.infoWindow |
|
|
); |
|
|
); |
|
|
|
|
|
//data.length 大于 5 取前5个数, 否则直接返回data
|
|
|
|
|
|
const pageSize = 6; |
|
|
|
|
|
let pageNum = 1; |
|
|
|
|
|
const dataFisrtPage = |
|
|
|
|
|
data.length > pageSize |
|
|
|
|
|
? data.slice((pageNum - 1) * pageSize, pageSize) |
|
|
|
|
|
: data; |
|
|
|
|
|
|
|
|
this.infoWindow.setContent(`<div
|
|
|
this.infoWindow.setContent(`<div
|
|
|
style=" |
|
|
style=" |
|
@ -119,7 +126,7 @@ export class MarkerCluster { |
|
|
<img class="info-close" style="width: 12px;cursor: pointer;" src="${require("@screen/images/dialog/icon-close.svg")}" /> |
|
|
<img class="info-close" style="width: 12px;cursor: pointer;" src="${require("@screen/images/dialog/icon-close.svg")}" /> |
|
|
</div> |
|
|
</div> |
|
|
<div style="padding: 15px 9px;flex: 1; overflow: auto;" class="info-window-content"> |
|
|
<div style="padding: 15px 9px;flex: 1; overflow: auto;" class="info-window-content"> |
|
|
${data |
|
|
${dataFisrtPage |
|
|
.map( |
|
|
.map( |
|
|
(item) => ` |
|
|
(item) => ` |
|
|
<div style="cursor: pointer; padding: 3px 6px;display: flex;align-items: center; gap: 6px;" class="info-window-item"> |
|
|
<div style="cursor: pointer; padding: 3px 6px;display: flex;align-items: center; gap: 6px;" class="info-window-item"> |
|
|