feat: initial project structure (Model Project) - Backend + Multi-Frontend + Docker

This commit is contained in:
VPS 4 Builder
2026-05-15 10:39:35 +02:00
commit 3beac0e0f2
288 changed files with 78761 additions and 0 deletions
+15
View File
@@ -0,0 +1,15 @@
-- ─────────────────────────────────────────────────────────────────
-- FASE 7: Logs do Motor de WhatsApp (NewWhats)
-- ─────────────────────────────────────────────────────────────────
CREATE TABLE IF NOT EXISTS whatsapp_logs (
id SERIAL PRIMARY KEY,
user_id INTEGER REFERENCES users(id) ON DELETE SET NULL,
phone TEXT NOT NULL,
type TEXT NOT NULL, -- 'purchase_confirmed', 'winner', 'last_hours', etc
payload TEXT, -- O JSON da request final
status TEXT DEFAULT 'queued' CHECK (status IN ('queued', 'processing', 'sent', 'failed', 'retrying')),
response TEXT, -- Resposta de erro ou sucesso do NewWhats HTTP
created_at TIMESTAMPTZ DEFAULT NOW(),
updated_at TIMESTAMPTZ DEFAULT NOW()
);