Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/assets/js/selectedIndicatorsModal.js
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,12 @@ async function checkFluviewGeoCoverage(geoValue) {
indicators: JSON.stringify(checkedIndicatorMembers.filter((indicator) => indicator["_endpoint"] === "fluview" || indicator["_endpoint"] === "fluview_clinical")),
}
});
for (const checkedIndicator of checkedIndicatorMembers.filter((indicator) => indicator["_endpoint"] === "fluview" || indicator["_endpoint"] === "fluview_clinical")) {
if (result["not_covered_indicators"].some((indicator) => indicator.indicator === checkedIndicator.indicator)) {
checkedIndicator["notCoveredGeos"] = [geoValue];
}
}
console.log(checkedIndicatorMembers);
return result["not_covered_indicators"];
} catch (error) {
console.error("Error fetching fluview geo coverage:", error);
Expand Down
2 changes: 1 addition & 1 deletion src/epiportal/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
from sentry_sdk.integrations.django import DjangoIntegration
from sentry_sdk.integrations.redis import RedisIntegration

APP_VERSION = "1.0.22"
APP_VERSION = "1.0.23"
ALTERNATIVE_INTERFACE_VERSION = "1.0.9"


Expand Down
37 changes: 19 additions & 18 deletions src/indicatorsets/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,25 +166,26 @@ def generate_covidcast_dataset_epivis(indicator, covidcast_geos):
def generate_fluview_dataset_epivis(indicator, fluview_geos):
datasets = []
for geo in fluview_geos:
datasets.append(
{
"color": generate_random_color(),
"title": FLUVIEW_INDICATORS_MAPPING.get(
indicator["indicator"], indicator["indicator"]
),
"params": {
"_endpoint": (
indicator["_endpoint"]
if indicator["data_source"] == "fluview"
else "fluview_clinical"
),
"regions": geo["id"],
"custom_title": generate_epivis_custom_title(
indicator, geo["text"]
if geo["id"] not in indicator.get("notCoveredGeos", []):
datasets.append(
{
"color": generate_random_color(),
"title": FLUVIEW_INDICATORS_MAPPING.get(
indicator["indicator"], indicator["indicator"]
),
},
}
)
"params": {
"_endpoint": (
indicator["_endpoint"]
if indicator["data_source"] == "fluview"
else "fluview_clinical"
),
"regions": geo["id"],
"custom_title": generate_epivis_custom_title(
indicator, geo["text"]
),
},
}
)
return datasets


Expand Down
Loading