Skip to content
Snippets Groups Projects
Commit ba7fcb4b authored by Andrzej Misiewicz's avatar Andrzej Misiewicz
Browse files

feat: add upgrade_to_pro_url property

parent f8b5de7c
No related branches found
No related tags found
1 merge request!35feat: add upgrade_to_pro_url property
Pipeline #257675 passed
...@@ -56,6 +56,13 @@ abstract class AbstractPlugin extends SlimPlugin { ...@@ -56,6 +56,13 @@ abstract class AbstractPlugin extends SlimPlugin {
*/ */
protected $support_url; protected $support_url;
/**
* Upgrade to pro URL.
*
* @var string
*/
protected $upgrade_to_pro_url;
/** /**
* AbstractPlugin constructor. * AbstractPlugin constructor.
* *
...@@ -216,6 +223,13 @@ abstract class AbstractPlugin extends SlimPlugin { ...@@ -216,6 +223,13 @@ abstract class AbstractPlugin extends SlimPlugin {
$links = array_merge( $plugin_links, $links ); $links = array_merge( $plugin_links, $links );
} }
if ( $this->upgrade_to_pro_url ) {
$plugin_links = [
'<a href="' . $this->upgrade_to_pro_url . '">' . __( 'Upgrade to PRO', $this->get_text_domain() ) . '</a>',
];
$links = array_merge( $plugin_links, $links );
}
return $links; return $links;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment