fix: fallback_flow por categoria, menu directo en saludo/fallback

This commit is contained in:
Lizandro Guarnizo
2026-06-27 18:53:41 -05:00
parent 02108b7ffa
commit 932a7a78a7
2 changed files with 26 additions and 10 deletions
+7
View File
@@ -59,8 +59,15 @@ class NormalBot
return $response;
}
$fallbackFlowId = $perType['fallback_flow'] ?? $config['fallback_flow'] ?? null;
if ($fallbackFlowId !== null && isset($flows[$fallbackFlowId])) {
ConversationContext::updateNode($ctxId, $fallbackFlowId);
return self::handleFlow($flows[$fallbackFlowId], $context, $company, $ctxId);
}
$fallback = $perType['fallback'] ?? $config['fallback'] ?? null;
if ($fallback !== null) {
ConversationContext::updateNode($ctxId, null);
return self::sendText($fallback, $context['from'], $company);
}