static* getSubnational() { logger.info('Obtaining subnational data'); const thresh = this.query.thresh || '30'; let data = yield CartoDBService.getSubnational(this.params.iso, this.params.id1, thresh, this.query.period); let dataArea = yield GeostoreService.getGeostoreByIsoAndId(this.params.iso, this.params.id1); data.total.area_ha = dataArea.areaHa; data.years.map(el => el.area_ha = dataArea.areaHa); this.body = UMDSerializer.serialize(data); }
static * getSubnational() { logger.info('Obtaining subnational data'); let data = yield CartoDBService.getSubnational(this.params.iso, this.params.id1, this.query.forSubscription, this.query.period); this.body = FormaAlertsSerializer.serialize(data); }
static * getSubnational() { logger.info('Obtaining subnational data'); let data = yield CartoDBService.getSubnational(this.params.iso, this.params.id1, this.query.alertQuery, this.query.period); this.body = ImazonAlertsSerializer.serialize(data); }