Skip to content

Commit

Permalink
Merge pull request #168 from ImMin5/feature-cost-report
Browse files Browse the repository at this point in the history
Remove workspace_id parameter at CostReportConfig
  • Loading branch information
ImMin5 authored Jan 29, 2024
2 parents 1648524 + 8144bc8 commit 479abc7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -63,18 +63,15 @@ class CostReportConfigRunRequest(BaseModel):
class CostReportConfigGetRequest(BaseModel):
cost_report_config_id: str
domain_id: str
workspace_id: Union[str, None] = None


class CostReportConfigSearchQueryRequest(BaseModel):
query: Union[dict, None] = None
cost_report_config_id: Union[str, None] = None
domain_id: str
workspace_id: Union[str, None] = None


class CostReportConfigStatQueryRequest(BaseModel):
query: dict
cost_report_config_id: Union[str, None] = None
domain_id: str
workspace_id: Union[str, None] = None
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ def get(
params (CostReportConfigGetRequest): {
'cost_report_config_id': 'str', # required
'domain_id': 'str' # injected from auth (required)
'workspace_id': 'str'
Returns:
CostReportConfigResponse:
Expand All @@ -237,7 +236,7 @@ def get(
permission="cost-analysis:CostReportConfig.read",
role_types=["DOMAIN_ADMIN", "WORKSPACE_OWNER"],
)
@append_query_filter(["cost_report_config_id", "domain_id", "workspace_id"])
@append_query_filter(["cost_report_config_id", "domain_id"])
@convert_model
def list(
self, params: CostReportConfigSearchQueryRequest
Expand Down Expand Up @@ -275,7 +274,7 @@ def list(
permission="cost-analysis:CostReportConfig.read",
role_types=["DOMAIN_ADMIN", "WORKSPACE_OWNER"],
)
@append_query_filter(["cost_report_config_id", "domain_id", "workspace_id"])
@append_query_filter(["cost_report_config_id", "domain_id"])
@convert_model
def stat(self, params: CostReportConfigStatQueryRequest) -> dict:
"""Stat cost report configs
Expand Down

0 comments on commit 479abc7

Please sign in to comment.