From b26903c4eee0893d074ae1a1ca0f11a8436cf7b0 Mon Sep 17 00:00:00 2001 From: olsch01 Date: Wed, 11 Mar 2026 11:12:02 -0400 Subject: [PATCH] Hide AI recommendation from results view; keep DB capture MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit AI text is still generated and saved to calc_submissions for internal follow-up, but no longer displayed to the user — keeps the detailed analysis behind the product sign-up wall. Co-Authored-By: Claude Sonnet 4.6 --- app.js | 14 +++----------- index.html | 6 ++---- 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/app.js b/app.js index 9c73f53..2cec577 100644 --- a/app.js +++ b/app.js @@ -129,9 +129,9 @@ ai += `This would represent entirely new interest income for your community at no additional risk.`; } - // ── AI recommendation — call server; fall back to client-side text ── + // ── AI recommendation — call server to generate & save to DB (not displayed) ── try { - const aiRes = await fetch('/api/calculate', { + await fetch('/api/calculate', { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({ @@ -140,15 +140,7 @@ totalPotential, opInterest, resInterest, }), }); - if (aiRes.ok) { - const { recommendation } = await aiRes.json(); - document.getElementById('calcAiText').textContent = recommendation; - } else { - document.getElementById('calcAiText').textContent = ai; - } - } catch (_) { - document.getElementById('calcAiText').textContent = ai; - } + } catch (_) { /* best-effort — DB save failed silently */ } // ── Animate the main number ── animateValue(document.getElementById('resultAmount'), 0, totalPotential); diff --git a/index.html b/index.html index 5d96657..374cae8 100644 --- a/index.html +++ b/index.html @@ -532,10 +532,8 @@ -
- ✦ HOA LedgerIQ AI Estimate -

-
+ +