|
@@ -98,17 +98,6 @@ class Studiou_WC_Product_Cat_Manage {
|
|
|
if (isset($_GET['activate'])) {
|
|
if (isset($_GET['activate'])) {
|
|
|
unset($_GET['activate']);
|
|
unset($_GET['activate']);
|
|
|
}
|
|
}
|
|
|
- return;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- // Check for WooCommerce Protected Categories
|
|
|
|
|
- if (!class_exists('WC_Protected_Categories') || !defined('WC_PROTECTED_CATEGORIES_VERSION') ||
|
|
|
|
|
- version_compare(WC_PROTECTED_CATEGORIES_VERSION, '2.7', '<')) {
|
|
|
|
|
- add_action('admin_notices', array($this, 'protected_categories_missing_notice'));
|
|
|
|
|
- deactivate_plugins(STUDIOU_WCPCM_PLUGIN_BASENAME);
|
|
|
|
|
- if (isset($_GET['activate'])) {
|
|
|
|
|
- unset($_GET['activate']);
|
|
|
|
|
- }
|
|
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -127,21 +116,6 @@ class Studiou_WC_Product_Cat_Manage {
|
|
|
<?php
|
|
<?php
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- /**
|
|
|
|
|
- * WooCommerce Protected Categories missing notice
|
|
|
|
|
- */
|
|
|
|
|
- public function protected_categories_missing_notice() {
|
|
|
|
|
- ?>
|
|
|
|
|
- <div class="error">
|
|
|
|
|
- <p><?php echo sprintf(
|
|
|
|
|
- __('QDR - Studiou WC Export/Import Product Categories requires WooCommerce Protected Categories version 2.7 or higher. Please %sinstall or update WooCommerce Protected Categories%s.', 'studiou-wc-product-cat-manage'),
|
|
|
|
|
- '<a href="https://barn2.com/wordpress-plugins/woocommerce-protected-categories/" target="_blank">',
|
|
|
|
|
- '</a>'
|
|
|
|
|
- ); ?></p>
|
|
|
|
|
- </div>
|
|
|
|
|
- <?php
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
/**
|
|
/**
|
|
|
* Add admin menu items
|
|
* Add admin menu items
|
|
|
*/
|
|
*/
|