Add Configuracoes review section for shared numbers
Adds an admin-only "Numeros compartilhados entre leads" section to the settings modal, wired to the Task 4 shared-numbers routes: lists detected groups, lets an admin liberar (with an inline motivo input) or bloquear de novo. Updates the two frontend VM-based test files' default API mocks to answer GET /api/outreach/shared-numbers so existing settings-modal tests keep passing, and adds a new interaction test covering the liberar round trip.
This commit is contained in:
@@ -78,6 +78,7 @@ async function executeApp({ get, post, patch, del, put } = {}) {
|
||||
if (url === '/api/outreach/templates') return { templates: [] };
|
||||
if (url === '/api/outreach/status') return { enviadosHoje: 0, mensagensPorDia: 10, ultimos: [] };
|
||||
if (url === '/api/outreach/opt-outs') return { optOuts: [] };
|
||||
if (url === '/api/outreach/shared-numbers') return { groups: [] };
|
||||
if (url === '/api/whatsapp/status') return { state: 'READY' };
|
||||
if (get) return get(url);
|
||||
throw new Error(`GET inesperado: ${url}`);
|
||||
@@ -177,6 +178,7 @@ async function renderCampaign(app, campaigns, options = {}) {
|
||||
if (url === '/api/outreach/templates') return { templates: [] };
|
||||
if (url === '/api/outreach/status') return { enviadosHoje: 0, mensagensPorDia: 10, ultimos: [] };
|
||||
if (url === '/api/outreach/opt-outs') return { optOuts: [] };
|
||||
if (url === '/api/outreach/shared-numbers') return { groups: [] };
|
||||
if (url === '/api/whatsapp/status') return { state: 'READY' };
|
||||
if (origGet) return origGet(url);
|
||||
throw new Error(`GET inesperado (campaign): ${url}`);
|
||||
|
||||
Reference in New Issue
Block a user