Skip to content

Commit

Permalink
enable to save default MapProjection on catalog
Browse files Browse the repository at this point in the history
  • Loading branch information
lubojr committed Jul 18, 2024
1 parent 3d49c6c commit 08746fb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/eodash_catalog/generate_indicators.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@ def process_catalog_file(file_path: str, options: Options):
)
else:
print(f"Warning: neither collection nor indicator found for {collection}")
if "MapProjection" in catalog_config:
catalog.extra_fields["eodash:mapProjection"] = catalog_config["MapProjection"]

strategy = TemplateLayoutStrategy(item_template="${collection}/${year}")
# expecting that the catalog will be hosted online, self url should correspond to that
Expand Down
2 changes: 1 addition & 1 deletion src/eodash_catalog/stac_handling.py
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ def add_base_overlay_info(
collection.add_link(create_web_map_link(layer, role="overlay"))


def add_extra_fields(stac_object: Collection | Catalog | Link, collection_config: dict) -> None:
def add_extra_fields(stac_object: Collection | Link, collection_config: dict) -> None:
if "yAxis" in collection_config:
stac_object.extra_fields["yAxis"] = collection_config["yAxis"]
if "Themes" in collection_config:
Expand Down

0 comments on commit 08746fb

Please sign in to comment.