-
Notifications
You must be signed in to change notification settings - Fork 14.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: alert/report execution log list view #11937
Conversation
Codecov Report
@@ Coverage Diff @@
## master #11937 +/- ##
==========================================
- Coverage 63.59% 54.57% -9.03%
==========================================
Files 939 431 -508
Lines 45580 15160 -30420
Branches 4371 3874 -497
==========================================
- Hits 28988 8273 -20715
+ Misses 16416 6887 -9529
+ Partials 176 0 -176
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
superset-frontend/src/views/CRUD/alert/components/AlertStatusIcon.tsx
Outdated
Show resolved
Hide resolved
afa7bed
to
90e3899
Compare
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, just 1 typo to fix though
const handleEdit = () => {}; // handleAnnotationEdit(original); | ||
const handleDelete = () => {}; // setAlertCurrentlyDeleting(original); | ||
const hanldeGotoExecutionLog = () => |
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.
const hanldeGotoExecutionLog = () => | |
const handleGotoExecutionLog = () => |
tooltip: t('Execution Log'), | ||
placement: 'bottom', | ||
icon: 'note' as IconName, | ||
onClick: handleEdit, | ||
onClick: hanldeGotoExecutionLog, |
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.
onClick: hanldeGotoExecutionLog, | |
onClick: handleGotoExecutionLog, |
addDangerToast, | ||
); | ||
|
||
const [alert, setAlert] = useState<AlertObject | null>(null); |
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 this? Isn't alertResource
the same thing?
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.
dont really need this. I will remove this line of code
if (alertId !== null && !alertLoading) { | ||
fetchResource(alertId); | ||
} |
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.
I haven't tested this, but it looks like this would cause an infinite fetch loop. Let's wrap it in a useEffect to be safe
if (alertId !== null && !alertLoading) { | |
fetchResource(alertId); | |
} | |
useEffect(() => { | |
if (alertId !== null) { | |
fetchResource(alertId); | |
} | |
}, [alertId]) | |
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.
yup, just tested this. It results in an infinite fetchResource
loop
350102c
to
0b120b2
Compare
SUMMARY
Back to all
redirect back to alert/report listBEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
Alert Execution Log
Report Execution Log
TEST PLAN
ADDITIONAL INFORMATION