iachat/app/models/landing_host.rb
Rodrigo Borba 118f52e239 feat: lead attribution tracking - landing page origin detection
- Cria modelo LeadClick para registrar cliques das landing pages
- Cria modelo LandingHost para mapear hostname → inbox_id
- Endpoint público POST /track/click para receber eventos de clique
- Leads::AttributionMatcherService para correlacionar clique com conversa
- Integração com IncomingMessageWuzapiService para atribuição automática
- API REST para gerenciar LandingHosts por inbox (index/create/destroy)
- UI: nova aba 'Landing Pages' nas configurações da caixa de entrada
- Dashboard API client dedicado (landingHosts.js)
- RuboCop: refatora shift_signature_name, TrackingController, AttributionMatcherService e WuzapiService
2026-03-02 14:40:35 -03:00

19 lines
394 B
Ruby

# == Schema Information
#
# Table name: landing_hosts
#
# id :bigint not null, primary key
# active :boolean
# hostname :string
# unit_code :string
# created_at :datetime not null
# updated_at :datetime not null
# inbox_id :integer
#
# Indexes
#
# index_landing_hosts_on_hostname (hostname) UNIQUE
#
class LandingHost < ApplicationRecord
end