Skip to content

Commit

Permalink
use BI group name
Browse files Browse the repository at this point in the history
  • Loading branch information
cnolanminich committed Oct 31, 2024
1 parent f59360f commit 4c51d6c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions hooli_data_eng/assets/powerbi_assets.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,21 @@

class MyCustomPowerBITranslator(DagsterPowerBITranslator):
def get_report_spec(self, data: PowerBIContentData) -> AssetSpec:
return super().get_report_spec(data)._replace(group_name="FORECASTING")
return super().get_report_spec(data)._replace(group_name="BI")

def get_semantic_model_spec(self, data: PowerBIContentData) -> AssetSpec:
spec = super().get_semantic_model_spec(data)
return replace_attributes(
spec,
group_name="FORECASTING",
group_name="BI",
deps=[AssetKey(path=[dep.asset_key.path[1].upper(), dep.asset_key.path[2]]) for dep in spec.deps],
tags={"core_kpis":"","dagster-powerbi/asset_type": "semantic_model"})

def get_dashboard_spec(self, data: PowerBIContentData) -> AssetSpec:
return super().get_dashboard_spec(data)._replace(group_name="FORECASTING")
return super().get_dashboard_spec(data)._replace(group_name="BI")

def get_data_source_spec(self, data: PowerBIContentData) -> AssetSpec:
return super().get_data_source_spec(data)._replace(group_name="FORECASTING")
return super().get_data_source_spec(data)._replace(group_name="BI")

powerbi_assets = [
build_semantic_model_refresh_asset_definition(resource_key="power_bi", spec=spec)
Expand Down

0 comments on commit 4c51d6c

Please sign in to comment.