/** * Handle admin tasks for cart66 */ function cc_task_dispatcher() { $task = cc_get('cc-task', 'key'); // CC_Log::write( "Task dispatcher found: $task" ); if ($task) { switch ($task) { case 'dismiss_notification_theme_support': CC_Admin_Notifications::dismiss('cart66_theme_support'); break; case 'dismiss_notification_permalinks': CC_Admin_Notifications::dismiss('cart66_permalinks'); break; case 'dismiss_notification_migration': CC_Admin_Notifications::dismiss('cart66_migration'); break; case 'download_log': CC_Log::download(); break; case 'reset_log': CC_Log::reset(); break; case 'test_remote_calls': $tests = new CC_Cloud_Remote_Check(); $tests->run(); break; case 'create_slurp_page': CC_Page_Slurp::create_slurp_page(); break; case 'migrate_settings': $migration = new CC_Migration(); $migration->run(); break; } } }
public function update_core_settings() { CC_Admin_Setting::update_options('cart66_main_settings', $this->main_settings); CC_Admin_Setting::update_options('cart66_labels', $this->labels); CC_Admin_Setting::update_options('cart66_product_options', $this->product_options); CC_Admin_Notifications::dismiss('cart66_migration'); }
function cc_reset_theme_notices() { CC_Admin_Notifications::clear('cart66_theme_support'); }
public static function instance() { if (!isset(self::$manager)) { self::$manager = new CC_Admin_Notification_Manager(); } }