diff --git a/backend/e2e/mobile-viewport.spec.js b/backend/e2e/mobile-viewport.spec.js index 6ad9f1ca..b62a4f8b 100644 --- a/backend/e2e/mobile-viewport.spec.js +++ b/backend/e2e/mobile-viewport.spec.js @@ -39,7 +39,7 @@ const ROUTES = [ { path: '/calendar', ready: '.calendar-surface', content: '.calendar-grid', contentReady: '.calendar-grid', mockCalendar: true }, { path: '/processes', ready: '.ops-surface-docs', content: '.ops-docs-catalog, .ops-docs-state, .ops-docs-state-detail' }, { path: '/operating-model', ready: '.operating-model-surface', content: '.operating-model-surface strong, .operating-model-surface table, .operating-model-surface .status-text' }, - { path: '/admin', ready: '.ops-surface-admin', content: '.ops-admin-card, .ops-admin-intake-recovery' }, + { path: '/admin', ready: '.ops-surface-admin', content: '.ops-admin-card' }, { path: '/users', ready: '.ops-surface-users', content: '.ops-users-outcome, .ops-users-toolbar, .ops-users-table' }, ]; diff --git a/frontend/src/styles/overrides.css b/frontend/src/styles/overrides.css index 0aad056a..6ba974a0 100644 --- a/frontend/src/styles/overrides.css +++ b/frontend/src/styles/overrides.css @@ -494,8 +494,7 @@ body[data-workspace-view] .task-modal-panel button, .invoice-fields select { width: 100%; } .invoice-destinations { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: var(--dk-space-4); padding: 0; list-style: none; } .invoice-destinations li { border: 1px solid var(--dk-border-default); padding: var(--dk-space-4); overflow-wrap: anywhere; } -[data-invoice-detail] details, -[data-invoice-process] { margin: var(--dk-space-4) 0; } +[data-invoice-detail] details { margin: var(--dk-space-4) 0; } [data-invoice-detail] fieldset { margin-top: var(--dk-space-4); } [data-invoice-detail] small { display: block; } .invoice-ledger-summary { margin: 0 0 var(--dk-space-2); color: var(--dk-text-muted); font-size: var(--dk-text-sm); } diff --git a/frontend/src/surfaces/finance/invoices.js b/frontend/src/surfaces/finance/invoices.js index ec71f7c7..8747d314 100644 --- a/frontend/src/surfaces/finance/invoices.js +++ b/frontend/src/surfaces/finance/invoices.js @@ -232,45 +232,6 @@ export function invoiceDetailMarkup(record, escapeHtml) { `; } -// Developer recovery for the email-intake pipeline. It lives on the Admin -// surface, not on the bookkeeping page: operators closing a month should not -// meet an intake-ID reprocessor above their ledger (#242). -export function mountIntakeRecovery(host, context) { - const { request, workApiUrl } = context; - host.innerHTML = `
- Process a received intake -
- - -
-

-
`; - const status = host.querySelector("[data-recovery-status]"); - const api = (options) => - request(workApiUrl("/api/bookkeeping/invoices/process"), { - ...options, - headers: { "content-type": "application/json" }, - }); - host - .querySelector("[data-invoice-process]") - .addEventListener("submit", async (event) => { - event.preventDefault(); - const intakeItemId = new FormData(event.target).get("intakeItemId"); - try { - const result = await api({ - method: "POST", - body: JSON.stringify({ intakeItemId }), - }); - status.textContent = - (result.issues || []).join("; ") || - `${result.items?.length || 0} invoice draft(s) available for review on the Bookkeeping page. Ingestion does not verify fields or publish.`; - } catch (error) { - status.textContent = `Needs attention: ${error.message}`; - } - }); -} - export async function mountInvoiceReview(host, context) { const { request, workApiUrl, escapeHtml } = context; const e = (value) => escapeHtml(String(value ?? "")); diff --git a/frontend/src/surfaces/operations/admin.js b/frontend/src/surfaces/operations/admin.js index e597e424..ea978e1c 100644 --- a/frontend/src/surfaces/operations/admin.js +++ b/frontend/src/surfaces/operations/admin.js @@ -6,7 +6,6 @@ import { reportFieldValidation, setControlPending, } from "../operations-overview.js"; -import { mountIntakeRecovery } from "../finance/invoices.js"; import { describeOpenWork, openUserLifecycleDialog } from "./user-lifecycle-dialog.js"; import { personAvatar } from "../../core/identity.js"; @@ -63,13 +62,6 @@ export function createAdminSurface(context) { // uppercase kicker over the title is the admin-template tell. wrap.append(renderSurfaceHeader("Admin", surfaceDescription("admin"))); wrap.append(renderAdminSurface()); - // The received-intake reprocessor is developer recovery tooling; it lives - // here, off the bookkeeping page it used to open (#242). - const intakeRecovery = document.createElement("section"); - intakeRecovery.className = "ops-admin-intake-recovery"; - intakeRecovery.setAttribute("aria-label", "Intake recovery"); - wrap.append(intakeRecovery); - mountIntakeRecovery(intakeRecovery, context); documentList.replaceChildren(wrap); } diff --git a/frontend/test/operations-surface.test.mjs b/frontend/test/operations-surface.test.mjs index 8035bf48..c53b196c 100644 --- a/frontend/test/operations-surface.test.mjs +++ b/frontend/test/operations-surface.test.mjs @@ -209,6 +209,14 @@ describe("Operations surface boundary", () => { }, }); harness.api.renderAdminSurfaceView([]); + assert.equal( + harness.documentList.querySelector(".ops-admin-intake-recovery"), + null, + ); + assert.equal( + harness.documentList.querySelector("[data-invoice-process]"), + null, + ); const pendingDiagnostics = harness.documentList.querySelector( ".ops-admin-diagnostics", );