peptide-geo-monitor v0.1.0: internal AI-visibility dashboard (#1)
New internal plugin: weekly LLM probes of core peptides (Perplexity sonar + GPT/Gemini-search via OpenRouter/CF gateway) -> custom table -> wp-admin trendline + standings. Provider interface + cost ledger w/ hard $5/mo cap + collector/panel seam (AI-visibility only). v1 = AI-visibility only. QA: APPROVE-WITH-P2-NOTES — qa-reviews/peptide-geo-monitor/2026-06-13-f488f4a966cbb9e771d3abc20daee3fa49074520.md (P2 follow-ups: ltrim www display bug, PHPCS mandatory, dead cache) Agent-Session: geomonitor v0.1.0 merge
This commit is contained in:
32
includes/core/class-pgm-activator.php
Normal file
32
includes/core/class-pgm-activator.php
Normal file
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* Plugin activation handler.
|
||||
*
|
||||
* Creates the custom database table via dbDelta and registers the weekly
|
||||
* WP-Cron probe schedule. Safe to call on re-activation — dbDelta is
|
||||
* idempotent and the cron schedule is only added when absent.
|
||||
*
|
||||
* Who triggers: register_activation_hook() in peptide-geo-monitor.php.
|
||||
* Dependencies: PGM_Table_Manager, PGM_Cron, PGM_Config.
|
||||
*
|
||||
* @see class-pgm-table-manager.php — Database schema creation.
|
||||
* @see class-pgm-cron.php — Cron scheduling.
|
||||
* @package PeptideGeoMonitor
|
||||
*/
|
||||
class PGM_Activator {
|
||||
|
||||
/**
|
||||
* Run all activation tasks.
|
||||
*
|
||||
* Side effects: Creates DB table, writes default options, schedules cron.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public static function activate(): void {
|
||||
PGM_Table_Manager::create_table();
|
||||
PGM_Config::seed_defaults();
|
||||
PGM_Cron::schedule_weekly();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user