diff --git a/app/javascript/dashboard/components-next/message/Message.vue b/app/javascript/dashboard/components-next/message/Message.vue index 78888d1e0..66234984c 100644 --- a/app/javascript/dashboard/components-next/message/Message.vue +++ b/app/javascript/dashboard/components-next/message/Message.vue @@ -391,13 +391,17 @@ const shouldRenderMessage = computed(() => { const isUnsupported = props.contentAttributes?.isUnsupported; const isAnIntegrationMessage = props.contentType === CONTENT_TYPES.INTEGRATIONS; + const isFailedMessage = props.status === MESSAGE_STATUS.FAILED; + const hasExternalError = !!props.contentAttributes?.externalError; return ( hasAttachments || props.content || isEmailContentType || isUnsupported || - isAnIntegrationMessage + isAnIntegrationMessage || + isFailedMessage || + hasExternalError ); }); diff --git a/app/javascript/dashboard/components-next/message/MessageError.vue b/app/javascript/dashboard/components-next/message/MessageError.vue index cd17c1e3f..fe508c805 100644 --- a/app/javascript/dashboard/components-next/message/MessageError.vue +++ b/app/javascript/dashboard/components-next/message/MessageError.vue @@ -12,11 +12,16 @@ defineProps({ const emit = defineEmits(['retry']); -const { orientation, status, createdAt } = useMessageContext(); +const { orientation, status, createdAt, content, attachments } = + useMessageContext(); const { t } = useI18n(); -const canRetry = computed(() => !hasOneDayPassed(createdAt.value)); +const canRetry = computed(() => { + const hasContent = content.value !== null; + const hasAttachments = attachments.value && attachments.value.length > 0; + return !hasOneDayPassed(createdAt.value) && (hasContent || hasAttachments); +});