-
Notifications
You must be signed in to change notification settings - Fork 31
Use new API to Generate Reports from Existing Definitions #213
Use new API to Generate Reports from Existing Definitions #213
Conversation
reportDefinitionRawResponse.report_definition.report_params.core_params | ||
.time_duration; | ||
const fromDate = getRelativeStartDate(duration); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we still need all these?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, good catch. Will remove
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you verify if it's the same situation for logic in create_report_defintion.ts? I always have an impression that lots of code can be removed with this new API
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you mean create_report_definition.tsx
? If so, yes. From the code change in the PR, the only parameter that is created is a reportDefinitionId
constant based on the response from the Create
API call
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, merge after github action test and build is passed
Issue #, if available:
N/A
Description of changes:
Refactored to call new API for generating reports from existing definitions- instead of passing in the entire metadata of creating a report, we only have to pass in the
reportDefinitionId
now.Usages:
Generate report
button on theReport definition details
page for an on-demand definition.File format
withinReport definition details
.By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.