From c0021c3cd65029b7fbda1da1547d2eb1010d98f5 Mon Sep 17 00:00:00 2001 From: justin Date: Sat, 30 May 2026 23:57:44 -0500 Subject: [PATCH] DOT checker: add business close-out mode + sell-your-trucks routing - Intent toggle: 'staying in business' (compliance) vs 'closing my business' - Closing mode shows a green, personalized wind-down checklist from FMCSA data (final MCS-150/USDOT deactivation, MC revoke, UCR, IFTA/IRP, state permits, insurance, entity dissolution) + 'let us handle the shutdown' lead capture - Sell-your-trucks box: quick cash -> ByeTruck referral lead + handoff; marketplace -> email capture for follow-up guide - Deep link via ?intent=closing for the email CTAs Co-Authored-By: Claude Opus 4.8 (1M context) --- .../tools/dot-compliance-check/index.html | 213 +++++++++++++++++- 1 file changed, 212 insertions(+), 1 deletion(-) diff --git a/site/public/tools/dot-compliance-check/index.html b/site/public/tools/dot-compliance-check/index.html index 77d245a..a476f96 100644 --- a/site/public/tools/dot-compliance-check/index.html +++ b/site/public/tools/dot-compliance-check/index.html @@ -13,7 +13,10 @@ Client Portal Sign out

DOT / FMCSA Compliance Check

Look up any motor carrier by USDOT number or name to instantly check MCS-150 status, insurance, operating authority, and safety rating.

Disclaimer: This tool queries publicly available FMCSA data. While we strive for accuracy, always confirm critical compliance matters directly with FMCSA. This is not legal advice.

+DOT Compliance Check

DOT / FMCSA Compliance Check

Look up any motor carrier by USDOT number or name to instantly check MCS-150 status, insurance, operating authority, and safety rating.

Disclaimer: This tool queries publicly available FMCSA data. While we strive for accuracy, always confirm critical compliance matters directly with FMCSA. This is not legal advice.

What brings you here?

+ + +

Your USDOT number is assigned by the Federal Motor Carrier Safety Administration. Don't know it? Use the name search tab.

@@ -113,6 +116,25 @@ Send reset link dotBtn.addEventListener("click", runDotCheck); dotInput.addEventListener("keydown", function(e) { if (e.key === "Enter") runDotCheck(); }); + // --- Intent selector (staying in business vs closing) --- + var pwIntent = "compliance"; + var intentBtns = document.querySelectorAll(".intent-btn"); + function setIntent(intent) { + pwIntent = intent; + intentBtns.forEach(function(b) { + var on = b.dataset.intent === intent; + var closing = b.dataset.intent === "closing"; + b.style.borderColor = on ? (closing ? "#16a34a" : "#f97316") : "#e2e8f0"; + b.style.background = on ? (closing ? "#f0fdf4" : "#fff7ed") : "#fff"; + b.style.color = on ? (closing ? "#166534" : "#9a3412") : "#64748b"; + var sub = b.querySelector("span"); + if (sub) sub.style.color = on ? (closing ? "#166534" : "#9a3412") : "#94a3b8"; + }); + // Re-render if a result is already on screen so the mode swaps live + if (!resultsEl.classList.contains("hidden") && window.__pwLastData) renderResults(window.__pwLastData); + } + intentBtns.forEach(function(b) { b.addEventListener("click", function() { setIntent(b.dataset.intent); }); }); + function markStep(stepId, status) { var el = document.getElementById(stepId); if (!el) return; @@ -252,11 +274,190 @@ Send reset link var checkBg = { green: "bg-green-50 border border-green-200", yellow: "bg-yellow-50 border border-yellow-200", red: "bg-red-50 border border-red-200", unknown: "bg-gray-50 border border-gray-200" }; var labelColor = { green: "text-green-800", yellow: "text-yellow-800", red: "text-red-800", unknown: "text-gray-700" }; + // ── Business close-out (winding down) ────────────────────────────── + var STATE_CLOSEOUT = { + CA: "Cancel your California Motor Carrier Permit (MCP) and CA# with the DMV / CHP.", + OR: "Close your Oregon Weight-Mile Tax account with ODOT and file a final mileage return.", + NY: "Cancel your New York HUT registration and destroy your HUT decals.", + KY: "Cancel your Kentucky KYU number so you stop accruing quarterly filings.", + NM: "Close your New Mexico Weight-Distance Tax account.", + CT: "Close your Connecticut Highway Use Fee account." + }; + + function buildCloseoutHtml(data) { + var state = data.phy_state || ""; + var steps = []; + steps.push("File a final MCS-150 marking your carrier “Out of Business.” This deactivates USDOT " + data.dot_number + " so biennial-update obligations and $1,000/day late penalties stop accruing."); + steps.push("Voluntarily revoke your operating authority (MC) with FMCSA so it isn’t left active and billable after you stop running."); + steps.push("Cancel your UCR registration — don’t just skip renewal; confirm you’re marked inactive so you aren’t billed next year."); + steps.push("Close your IFTA account, file a final quarterly return, and return or destroy your IFTA decals."); + steps.push("Return your IRP apportioned plates" + (state ? " to your base state (" + state + ")" : "") + " and close the account so registration fees stop."); + if (STATE_CLOSEOUT[state]) steps.push("State requirement: " + STATE_CLOSEOUT[state]); + steps.push("Cancel your insurance — but only after your authority is revoked, so FMCSA doesn’t flag an insurance lapse on an active carrier."); + steps.push("Dissolve your LLC / corporation with the state and file a final tax return so you stop owing annual-report fees and franchise tax."); + + var h = ''; + // Intro + h += '
'; + h += '

Winding down ' + data.legal_name + '? Here’s your exit checklist.

'; + h += '

Closing a trucking business is more than parking the truck. Skip a step and the bills — UCR, IRP, state permits, annual reports — keep coming. Here’s what to wrap up, based on your FMCSA record:

'; + h += '
    '; + steps.forEach(function(s) { + h += '
  1. '; + h += ''; + h += '' + s + '
  2. '; + }); + h += '
'; + + // "Let us handle it" lead capture (green) + h += '
'; + h += '

Let us handle the shutdown paperwork

'; + h += '

We’ll deactivate your USDOT, revoke your authority, cancel UCR, and close your state accounts — so nothing keeps billing you after you’re out. No Login.gov, no government portals.

'; + h += ''; + h += ''; + h += ''; + h += ''; + h += ''; + h += '
'; + + // Sell-your-trucks box (green) + h += '
'; + h += '

Looking to sell your trucks?

'; + h += '

Two ways to go — pick what fits your timeline:

'; + h += '
'; + h += ''; + h += ''; + h += '
'; + // Quick-cash form (hidden until chosen) + h += ''; + // Marketplace form (hidden until chosen) + h += ''; + h += '
'; + + return h; + } + + // Shared lead submitter — mirrors the insurance lead flow + function pwSubmitLead(o) { + o.statusEl.classList.add("hidden"); + if (o.requireEmail && !o.email) { + o.statusEl.textContent = "Please enter your email."; + o.statusEl.className = "text-xs text-red-600"; + o.statusEl.classList.remove("hidden"); + return; + } + o.btn.disabled = true; + var origText = o.btn.textContent; + o.btn.textContent = "Submitting..."; + fetch(API + "/api/v1/tickets", { + method: "POST", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ category: o.category, subject: o.subject, message: o.message, email: o.email, name: o.name }) + }).then(function(r) { + if (!r.ok) throw new Error("Failed"); + o.statusEl.textContent = o.okMsg; + o.statusEl.className = "text-xs text-green-700"; + o.statusEl.classList.remove("hidden"); + o.btn.textContent = "Submitted"; + if (o.onOk) o.onOk(); + }).catch(function() { + o.statusEl.textContent = "Something went wrong. Email info@performancewest.net instead."; + o.statusEl.className = "text-xs text-red-600"; + o.statusEl.classList.remove("hidden"); + o.btn.disabled = false; + o.btn.textContent = origText; + }); + } + + function wireCloseout(data) { + var loc = (data.phy_city || "") + ", " + (data.phy_state || ""); + var fleet = data.fleet ? (data.fleet.power_units + " trucks, " + data.fleet.drivers + " drivers") : "unknown"; + + // "Handle my shutdown" lead + var coBtn = document.getElementById("co-submit"); + if (coBtn) coBtn.addEventListener("click", function() { + var name = document.getElementById("co-name").value.trim(); + var email = document.getElementById("co-email").value.trim(); + var phone = document.getElementById("co-phone").value.trim(); + pwSubmitLead({ + category: "business_closeout", requireEmail: true, email: email, name: name, + btn: coBtn, statusEl: document.getElementById("co-status"), + okMsg: "Got it! We'll reach out within 1 business day to start your wind-down.", + subject: "Business Close-Out — " + data.legal_name + " (DOT " + data.dot_number + ")", + message: ["Business close-out / wind-down request from DOT Compliance Checker.", "", + "Carrier: " + data.legal_name, "DOT#: " + data.dot_number, "Location: " + loc, "Fleet: " + fleet, + "", "Contact: " + name, "Email: " + email, "Phone: " + (phone || data.telephone || "not provided")].join("\n") + }); + }); + + // Sell-trucks option reveal + document.querySelectorAll(".sell-opt").forEach(function(b) { + b.addEventListener("click", function() { + var qc = document.getElementById("sell-quickcash"); + var mp = document.getElementById("sell-marketplace"); + qc.style.display = b.dataset.opt === "quickcash" ? "block" : "none"; + mp.style.display = b.dataset.opt === "marketplace" ? "block" : "none"; + document.querySelectorAll(".sell-opt").forEach(function(x) { + x.style.background = x === b ? "#dcfce7" : "#fff"; + }); + }); + }); + + // Quick-cash → ByeTruck referral lead + var qcBtn = document.getElementById("qc-submit"); + if (qcBtn) qcBtn.addEventListener("click", function() { + var name = document.getElementById("qc-name").value.trim(); + var phone = document.getElementById("qc-phone").value.trim(); + var email = document.getElementById("qc-email").value.trim(); + var truck = document.getElementById("qc-truck").value.trim(); + pwSubmitLead({ + category: "truck_sale_quickcash", requireEmail: false, email: email, name: name, + btn: qcBtn, statusEl: document.getElementById("qc-status"), + okMsg: "Sent to ByeTruck — they'll contact you with a cash offer. Opening ByeTruck in a new tab...", + subject: "Truck Sale (Quick Cash / ByeTruck) — " + data.legal_name + " (DOT " + data.dot_number + ")", + message: ["Quick-cash truck sale lead from DOT Compliance Checker — route to ByeTruck.", "", + "Carrier: " + data.legal_name, "DOT#: " + data.dot_number, "Location: " + loc, "Fleet: " + fleet, + "Vehicle(s): " + (truck || "not specified"), "", + "Contact: " + name, "Email: " + email, "Phone: " + (phone || data.telephone || "not provided")].join("\n"), + onOk: function() { setTimeout(function() { window.open("https://www.byetruck.com/", "_blank"); }, 1200); } + }); + }); + + // Marketplace → guide follow-up lead + var mpBtn = document.getElementById("mp-submit"); + if (mpBtn) mpBtn.addEventListener("click", function() { + var email = document.getElementById("mp-email").value.trim(); + pwSubmitLead({ + category: "truck_sale_marketplace", requireEmail: true, email: email, name: data.legal_name, + btn: mpBtn, statusEl: document.getElementById("mp-status"), + okMsg: "Done! Watch your inbox for our truck-marketplace guide.", + subject: "Truck Sale (Marketplace guide) — " + data.legal_name + " (DOT " + data.dot_number + ")", + message: ["Marketplace truck-sale lead from DOT Compliance Checker — send marketplace guide follow-up.", "", + "Carrier: " + data.legal_name, "DOT#: " + data.dot_number, "Location: " + loc, "Fleet: " + fleet, + "", "Email: " + email].join("\n") + }); + }); + } + function renderResults(data) { if (!data || !data.legal_name) { showError("No data returned. The carrier may not exist or the lookup timed out."); return; } + window.__pwLastData = data; var html = ''; // Entity header card @@ -297,6 +498,9 @@ Send reset link html += '
'; }); + if (pwIntent === "closing") { + html += buildCloseoutHtml(data); + } else { // Insurance lead capture — auto-checked if insurance issue found var hasInsuranceIssue = (data.checks || []).some(function(c) { return (c.id === "insurance" || c.id === "insurance_bipd" || c.id === "insurance_cargo" || c.id === "insurance_bond") && c.status === "red"; @@ -389,6 +593,8 @@ Send reset link html += '
'; } + } // end compliance-mode block + // Recent update notice + disclaimer html += '
'; html += '

Think something is wrong? If you recently filed an update, it may take 5-10 business days for FMCSA to reflect changes in their system. If you believe this report is in error, contact FMCSA directly at (800) 832-5660.

'; @@ -398,6 +604,8 @@ Send reset link resultsEl.innerHTML = html; resultsEl.classList.remove("hidden"); + if (pwIntent === "closing") { wireCloseout(data); return; } + // Insurance lead checkbox toggle var insCheck = document.getElementById("ins-lead-check"); var insForm = document.getElementById("ins-lead-form"); @@ -466,6 +674,9 @@ Send reset link // Auto-fill from URL (function() { var params = new URLSearchParams(window.location.search); + if (params.get("intent") === "closing" || params.get("closing") === "1") { + setIntent("closing"); + } var dot = params.get("dot"); if (dot) { dotInput.value = dot;