/** * 网格化监测 */ function GridMonitor(options) { this.sites this.showingSites = [] // 信访企业 this.companys = [] // 信访企业地图标记 this.companyMarker = [] this.companyInfoWindow = [] this.isCompanyShow = false this.historyMode = options.historyMode this.timePicker = options.timePicker } GridMonitor.prototype = { init: function () { this.getStats() // this.fetchingData() }, enable: function () { this.isEnable = true this.uiChange(true) }, disable: function () { this.isEnable = false this.uiChange(false) }, getStats: function () { // todo this.sites = { '0d0000000001': { name: '吕巷镇乡间艺墅微型站', code: '0d0000000001', show: false, data: new FactorDatas(), location: [0, 0], // 地图标记点 marker: '', // 标记点信息窗体 infoWindow: '' }, // '0a0000000001': { // name: '测试站点二', // code: '0a0000000001', // show: false, // data: new FactorDatas(), // location: [0, 0], // // 地图标记点 // marker: '', // // 标记点信息窗体 // infoWindow: '' // } } var that = this var group = $('#monitor_sites') group.empty() Object.keys(this.sites).forEach(k => { var s = this.sites[k] var d1 = $('
') var check = $('') check.attr('id', s.code) check.attr('value', s.code) check.on('click', function () { var code = $(this).val() that.showData(code) }) var label = $('