fisjac commented on code in PR #26327:
URL: https://github.com/apache/superset/pull/26327#discussion_r1501003955
##########
superset-frontend/src/features/alerts/AlertReportModal.tsx:
##########
@@ -1160,6 +1167,18 @@ const AlertReportModal:
FunctionComponent<AlertReportModalProps> = ({
setIsHidden(false);
}
+ const updateEmailSubject = () => {
+ if (contentType === 'chart') {
+ setEmailSubject(
+ `${currentAlert?.name}: ${currentAlert?.chart?.label || ''}`,
+ );
+ } else {
+ setEmailSubject(
+ `${currentAlert?.name}: ${currentAlert?.dashboard?.label || ''}`,
+ );
+ }
Review Comment:
Perhaps the placeholder could show the default if empty? This would also
allow for users to revert back to default if they've saved a report with a
name, but want to return to the Superset default subject line.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]