2 Commits

Author SHA1 Message Date
f65f793c95 Rename leads field: Google Ads as 'leads', Airtable as 'leads_lake'
- MetricasDiarias now stores both: leads (Google conv) and leads_lake (Airtable count)
- Update backfill and migration scripts accordingly
- migrate_leads_field.py executed: 49 May records updated

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-04 10:36:20 +02:00
f1dec1c887 Add daily leads count per campaign to MetricasDiarias
- Fetch leads from Airtable per campaign on yesterday's date before second pass
- Include 'leads' field in MetricasDiarias JSON alongside coste/ingreso/margen
- Add get_leads_by_campaign_on_date() bulk fetch in AirtableClient
- Add backfill_leads_mayo.py one-off script (already executed for days 01-03)
- Fix UnboundLocalError: remove duplicate local timedelta import inside run()

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-04 10:24:28 +02:00