/** * Return the plugin action links. This will only be called if the plugin * is active. * * @since 1.0.0 * @see SV_WC_Plugin::plugin_action_links() * @param array $actions associative array of action names to anchor tags * @return array associative array of plugin action links */ public function plugin_action_links($actions) { $actions = parent::plugin_action_links($actions); // remove the configure plugin link if it exists, since we'll be adding a link per available gateway if (isset($actions['configure'])) { unset($actions['configure']); } // a configure link per gateway $custom_actions = array(); foreach ($this->get_gateway_ids() as $gateway_id) { $custom_actions['configure_' . $gateway_id] = $this->get_settings_link($gateway_id); } // add the links to the front of the actions list return array_merge($custom_actions, $actions); }