mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-20 17:51:12 -05:00
Fix Resolve button flow
Investigate and address why the Resolve action isn’t triggering despite superuser role. Add diagnostic logging and ensure the resolve mutation is invoked with correct data, plus prep for validating frontend event wiring and mutation calls.
This commit is contained in:
@@ -37,6 +37,11 @@ export function GroupedAlertsPanel({ alerts, isLoading }: GroupedAlertsPanelProp
|
|||||||
});
|
});
|
||||||
|
|
||||||
const handleResolveGroup = (alert: GroupedAlert) => {
|
const handleResolveGroup = (alert: GroupedAlert) => {
|
||||||
|
console.log('🔴 Resolve button clicked', {
|
||||||
|
alertIds: alert.alert_ids,
|
||||||
|
source: alert.source,
|
||||||
|
alert,
|
||||||
|
});
|
||||||
resolveGroup.mutate({
|
resolveGroup.mutate({
|
||||||
alertIds: alert.alert_ids,
|
alertIds: alert.alert_ids,
|
||||||
source: alert.source,
|
source: alert.source,
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ export function useResolveAlertGroup() {
|
|||||||
alertIds: string[];
|
alertIds: string[];
|
||||||
source: 'system' | 'rate_limit';
|
source: 'system' | 'rate_limit';
|
||||||
}) => {
|
}) => {
|
||||||
|
console.log('🟢 Mutation function called', { alertIds, source });
|
||||||
const table = source === 'system' ? 'system_alerts' : 'rate_limit_alerts';
|
const table = source === 'system' ? 'system_alerts' : 'rate_limit_alerts';
|
||||||
|
|
||||||
// Log breadcrumb for debugging
|
// Log breadcrumb for debugging
|
||||||
|
|||||||
Reference in New Issue
Block a user