Allow parent component to pass tags to issue report panel (#2247)

This commit is contained in:
bymyself
2025-01-14 21:34:11 -07:00
committed by GitHub
parent bf90b458d3
commit dd005f5fa5
2 changed files with 8 additions and 3 deletions

View File

@@ -30,6 +30,7 @@
v-if="sendReportOpen"
error-type="graphExecutionError"
:extra-fields="[stackTraceField]"
:tags="{ exceptionMessage: props.error.exception_message }"
/>
<div class="action-container">
<FindIssueButton

View File

@@ -75,9 +75,12 @@ const props = defineProps<{
errorType: string
defaultFields?: DefaultField[]
extraFields?: ReportField[]
tags?: Record<string, string>
}>()
const { defaultFields = ['Workflow', 'Logs', 'SystemStats', 'Settings'] } =
props
const {
defaultFields = ['Workflow', 'Logs', 'SystemStats', 'Settings'],
tags = {}
} = props
const { t } = useI18n()
const toast = useToast()
@@ -168,7 +171,8 @@ const createCaptureContext = async (): Promise<CaptureContext> => {
user: getUserInfo(),
level: 'error',
tags: {
errorType: props.errorType
errorType: props.errorType,
...tags
},
extra: {
...createFeedback(),