feat(tradein/lead): persist 152-ФЗ proof-of-consent (LOW audit R2 #9) #2511

Merged
bot-backend merged 1 commit from fix/tradein-lead-consent-columns into main 2026-07-12 22:13:38 +00:00
Collaborator

LOW audit round-2 #9, user-approved. Consent was a bare boolean; #2497 wrote client_ip + policy version to the audit log only (TODO, no columns). Migration 182 adds nullable client_ip (inet) / consent_policy_version / consent_text_snapshot to trade_in_leads; create_trade_in_lead now persists them per-row. consent_text_snapshot is sourced verbatim from the LeadForm.tsx checkbox. Additive/nullable, idempotent, no backfill (pre-migration rows honestly keep NULL). Migrate-before-app (#2216). 14 tests pass (fully mocked db).

LOW audit round-2 #9, user-approved. Consent was a bare boolean; #2497 wrote client_ip + policy version to the audit log only (TODO, no columns). Migration 182 adds nullable client_ip (inet) / consent_policy_version / consent_text_snapshot to trade_in_leads; create_trade_in_lead now persists them per-row. consent_text_snapshot is sourced verbatim from the LeadForm.tsx checkbox. Additive/nullable, idempotent, no backfill (pre-migration rows honestly keep NULL). Migrate-before-app (#2216). 14 tests pass (fully mocked db).
bot-backend added 1 commit 2026-07-12 22:11:51 +00:00
feat(tradein/lead): persist 152-ФЗ proof-of-consent (client_ip, policy version, text snapshot)
All checks were successful
CI Trade-In / changes (pull_request) Successful in 9s
CI / backend-tests (pull_request) Has been skipped
CI / frontend-tests (pull_request) Has been skipped
CI / changes (pull_request) Successful in 9s
CI Trade-In / frontend-checks (pull_request) Has been skipped
CI / openapi-codegen-check (pull_request) Has been skipped
CI Trade-In / backend-tests (pull_request) Successful in 1m6s
55e40814a6
Migration 182 adds nullable client_ip/consent_policy_version/consent_text_snapshot
to trade_in_leads; create_trade_in_lead now writes them (previously audit-log only,
#2497 TODO). Migrate-before-app (#2216 precedent). LOW audit R2 (#9).
bot-backend merged commit 60c21ae2a5 into main 2026-07-12 22:13:38 +00:00
bot-backend deleted branch fix/tradein-lead-consent-columns 2026-07-12 22:13:38 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: lekss361/gendesign#2511
No description provided.