- Introduced a new `CampaignAlerts` class for handling alerts logic. - Added database migration for `campaign_alerts` table creation. - Implemented methods for fetching, marking, and deleting alerts in the `CampaignAlerts` factory class. - Created a new view for displaying campaign alerts with filtering options. - Updated the main client view to include a badge for the number of alerts. - Enhanced sync functionality to support campaigns and products separately. - Adjusted styles for alert badges in the UI.
8 lines
330 B
SQL
8 lines
330 B
SQL
-- Migracja: flaga unseen dla alertow kampanii
|
|
-- Opis: nowe alerty sa unseen=1, po wejsciu na strone alertow oznaczane jako unseen=0
|
|
|
|
ALTER TABLE `campaign_alerts`
|
|
ADD COLUMN IF NOT EXISTS `unseen` TINYINT(1) NOT NULL DEFAULT 1 AFTER `meta_json`;
|
|
|
|
CREATE INDEX IF NOT EXISTS `idx_alert_unseen` ON `campaign_alerts` (`unseen`);
|