Changeset 2994180
- Timestamp:
- 11/10/2023 08:14:48 PM (2 years ago)
- Location:
- activecampaign-for-woocommerce/trunk
- Files:
-
- 14 edited
-
README.txt (modified) (3 diffs)
-
ac_vendor/autoload.php (modified) (1 diff)
-
ac_vendor/composer/autoload_real.php (modified) (5 diffs)
-
ac_vendor/composer/autoload_static.php (modified) (2 diffs)
-
activecampaign-for-woocommerce.php (modified) (1 diff)
-
admin/class-activecampaign-for-woocommerce-admin.php (modified) (1 diff)
-
admin/scripts/activecampaign-for-woocommerce-connection-settings.js (modified) (1 diff)
-
admin/trait-activecampaign-for-woocommerce-admin-connections.php (modified) (1 diff)
-
admin/views/activecampaign-for-woocommerce-admin-display.php (modified) (3 diffs)
-
admin/views/activecampaign-for-woocommerce-status-display.php (modified) (1 diff)
-
includes/class-activecampaign-for-woocommerce.php (modified) (1 diff)
-
includes/commands/class-activecampaign-for-woocommerce-create-or-update-connection-option-command.php (modified) (10 diffs)
-
includes/config/activecampaign-for-woocommerce-global-constants.php (modified) (1 diff)
-
includes/products/class-activecampaign-for-woocommerce-product-sync-job.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
activecampaign-for-woocommerce/trunk/README.txt
r2988259 r2994180 3 3 Tags: marketing, ecommerce, woocommerce, email, activecampaign, abandoned cart 4 4 Requires at least: 6.0 5 Tested up to: 6. 3.26 Stable tag: 2.5. 05 Tested up to: 6.4.1 6 Stable tag: 2.5.1 7 7 Requires PHP: 7.4 8 8 License: GPLv2 or later … … 48 48 49 49 = WooCommerce Compatibility = 50 * Tested up to version: 8. 2.150 * Tested up to version: 8.3.0 51 51 * Minimal version requirement: 7.0.0 52 52 * HPOS Compatible … … 84 84 == Changelog == 85 85 86 == 2.5.1 2023-11-10 == 87 * Bugfix for product types missing from product sync 88 * Deprecating connection option id 89 86 90 == 2.5.0 2023-11-02 == 87 91 * Adding save option to support logs -
activecampaign-for-woocommerce/trunk/ac_vendor/autoload.php
r2988259 r2994180 5 5 require_once __DIR__ . '/composer/autoload_real.php'; 6 6 7 return ComposerAutoloaderInit bf676c12852dd0e3db88a089cf454723::getLoader();7 return ComposerAutoloaderInit1ad1f41efc084e1ae73102c451263a68::getLoader(); -
activecampaign-for-woocommerce/trunk/ac_vendor/composer/autoload_real.php
r2988259 r2994180 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit bf676c12852dd0e3db88a089cf4547235 class ComposerAutoloaderInit1ad1f41efc084e1ae73102c451263a68 6 6 { 7 7 private static $loader; … … 25 25 require __DIR__ . '/platform_check.php'; 26 26 27 spl_autoload_register(array('ComposerAutoloaderInit bf676c12852dd0e3db88a089cf454723', 'loadClassLoader'), true, true);27 spl_autoload_register(array('ComposerAutoloaderInit1ad1f41efc084e1ae73102c451263a68', 'loadClassLoader'), true, true); 28 28 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__))); 29 spl_autoload_unregister(array('ComposerAutoloaderInit bf676c12852dd0e3db88a089cf454723', 'loadClassLoader'));29 spl_autoload_unregister(array('ComposerAutoloaderInit1ad1f41efc084e1ae73102c451263a68', 'loadClassLoader')); 30 30 31 31 $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); … … 33 33 require __DIR__ . '/autoload_static.php'; 34 34 35 call_user_func(\Composer\Autoload\ComposerStaticInit bf676c12852dd0e3db88a089cf454723::getInitializer($loader));35 call_user_func(\Composer\Autoload\ComposerStaticInit1ad1f41efc084e1ae73102c451263a68::getInitializer($loader)); 36 36 } else { 37 37 $map = require __DIR__ . '/autoload_namespaces.php'; … … 54 54 55 55 if ($useStaticLoader) { 56 $includeFiles = Composer\Autoload\ComposerStaticInit bf676c12852dd0e3db88a089cf454723::$files;56 $includeFiles = Composer\Autoload\ComposerStaticInit1ad1f41efc084e1ae73102c451263a68::$files; 57 57 } else { 58 58 $includeFiles = require __DIR__ . '/autoload_files.php'; 59 59 } 60 60 foreach ($includeFiles as $fileIdentifier => $file) { 61 composerRequire bf676c12852dd0e3db88a089cf454723($fileIdentifier, $file);61 composerRequire1ad1f41efc084e1ae73102c451263a68($fileIdentifier, $file); 62 62 } 63 63 … … 66 66 } 67 67 68 function composerRequire bf676c12852dd0e3db88a089cf454723($fileIdentifier, $file)68 function composerRequire1ad1f41efc084e1ae73102c451263a68($fileIdentifier, $file) 69 69 { 70 70 if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { -
activecampaign-for-woocommerce/trunk/ac_vendor/composer/autoload_static.php
r2988259 r2994180 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit bf676c12852dd0e3db88a089cf4547237 class ComposerStaticInit1ad1f41efc084e1ae73102c451263a68 8 8 { 9 9 public static $files = array ( … … 476 476 { 477 477 return \Closure::bind(function () use ($loader) { 478 $loader->prefixLengthsPsr4 = ComposerStaticInit bf676c12852dd0e3db88a089cf454723::$prefixLengthsPsr4;479 $loader->prefixDirsPsr4 = ComposerStaticInit bf676c12852dd0e3db88a089cf454723::$prefixDirsPsr4;480 $loader->classMap = ComposerStaticInit bf676c12852dd0e3db88a089cf454723::$classMap;478 $loader->prefixLengthsPsr4 = ComposerStaticInit1ad1f41efc084e1ae73102c451263a68::$prefixLengthsPsr4; 479 $loader->prefixDirsPsr4 = ComposerStaticInit1ad1f41efc084e1ae73102c451263a68::$prefixDirsPsr4; 480 $loader->classMap = ComposerStaticInit1ad1f41efc084e1ae73102c451263a68::$classMap; 481 481 482 482 }, null, ClassLoader::class); -
activecampaign-for-woocommerce/trunk/activecampaign-for-woocommerce.php
r2988259 r2994180 17 17 * Plugin URI: https://www.activecampaign.com/ 18 18 * Description: Add Abandoned Cart functionality to your WooCommerce store, synchronize order & customer information using ActiveCampaign. 19 * Version: 2.5. 019 * Version: 2.5.1 20 20 * WC requires at least: 7.4 21 21 * WC tested up to: 8.2.0 -
activecampaign-for-woocommerce/trunk/admin/class-activecampaign-for-woocommerce-admin.php
r2973117 r2994180 909 909 910 910 update_option( ACTIVECAMPAIGN_FOR_WOOCOMMERCE_DB_CONNECTION_STORAGE_NAME, $data ); 911 911 912 delete_transient( 'activecampaign_for_woocommerce_all_connections' ); 912 913 delete_transient( 'activecampaign_for_woocommerce_connection' ); -
activecampaign-for-woocommerce/trunk/admin/scripts/activecampaign-for-woocommerce-connection-settings.js
r2931548 r2994180 110 110 function rowStatusSuccess(id, tooltip){ 111 111 updateRowStatus(id, 'Success', 'success', tooltip); 112 setTimeout(function(){document.location.reload()}, 1000); 112 113 } 113 114 -
activecampaign-for-woocommerce/trunk/admin/trait-activecampaign-for-woocommerce-admin-connections.php
r2966088 r2994180 205 205 delete_option( 'activecampaign_for_woocommerce_connection_health_check_last_run' ); 206 206 $this->update_storage_from_connection( $connection ); 207 207 208 wp_send_json_success( 'Connection saved.' ); 208 209 } -
activecampaign-for-woocommerce/trunk/admin/views/activecampaign-for-woocommerce-admin-display.php
r2977226 r2994180 56 56 } 57 57 58 $activecampaign_for_woocommerce_connection_created_in = 'WooCommerce'; 59 58 60 if ( isset( $activecampaign_for_woocommerce_storage['is_internal'] ) ) { 59 if ( 1 === $activecampaign_for_woocommerce_storage['is_internal'] ) {61 if ( 1 === $activecampaign_for_woocommerce_storage['is_internal'] || '1' === $activecampaign_for_woocommerce_storage['is_internal'] ) { 60 62 $activecampaign_for_woocommerce_connection_created_in = 'ActiveCampaign'; 61 } else {62 $activecampaign_for_woocommerce_connection_created_in = 'WooCommerce';63 63 } 64 64 } … … 82 82 if ( isset( $activecampaign_for_woocommerce_storage['connection_id'] ) ) { 83 83 $activecampaign_for_woocommerce_connection_id = $activecampaign_for_woocommerce_storage['connection_id']; 84 }85 86 $activecampaign_for_woocommerce_connection_option_id = 'UNKNOWN';87 if ( isset( $activecampaign_for_woocommerce_storage['connection_option_id'] ) ) {88 $activecampaign_for_woocommerce_connection_option_id = $activecampaign_for_woocommerce_storage['connection_option_id'];89 84 } 90 85 … … 662 657 <p> 663 658 <?php 664 esc_html_e( ' ActiveCampaign connection option ID: ', ACTIVECAMPAIGN_FOR_WOOCOMMERCE_LOCALIZATION_DOMAIN );659 esc_html_e( 'Connection managed in: ', ACTIVECAMPAIGN_FOR_WOOCOMMERCE_LOCALIZATION_DOMAIN ); 665 660 ?> 666 <?php if ( ! isset( $activecampaign_for_woocommerce_connection_ option_id) ) : ?>667 <?php esc_html_e( 'Error: No connection option ID found in settings! ', ACTIVECAMPAIGN_FOR_WOOCOMMERCE_LOCALIZATION_DOMAIN ); ?>661 <?php if ( ! isset( $activecampaign_for_woocommerce_connection_created_in ) ) : ?> 662 <?php esc_html_e( 'Error: connection source not determined! ', ACTIVECAMPAIGN_FOR_WOOCOMMERCE_LOCALIZATION_DOMAIN ); ?> 668 663 <?php else : ?> 669 <?php echo esc_html( $activecampaign_for_woocommerce_connection_ option_id); ?>664 <?php echo esc_html( $activecampaign_for_woocommerce_connection_created_in ); ?> 670 665 <?php endif; ?> 671 666 </p> -
activecampaign-for-woocommerce/trunk/admin/views/activecampaign-for-woocommerce-status-display.php
r2988259 r2994180 138 138 <td> 139 139 <?php 140 esc_html_e( 'ActiveCampaign connection option ID: ', ACTIVECAMPAIGN_FOR_WOOCOMMERCE_LOCALIZATION_DOMAIN ); 141 ?> 142 </td> 143 <td> 144 <?php if ( empty( $this->get_storage() ) || ! $this->get_storage() || ! isset( $this->get_storage()['connection_option_id'] ) ) : ?> 140 esc_html_e( 'ActiveCampaign connection managed in: ', ACTIVECAMPAIGN_FOR_WOOCOMMERCE_LOCALIZATION_DOMAIN ); 141 ?> 142 </td> 143 <td> 145 144 <?php if ( 0 === $this->get_storage()['is_internal'] || '0' === $this->get_storage()['is_internal'] ) : ?> 146 <?php $this->output_yes_mark( 'Third Party' ); ?> 145 <?php $this->output_yes_mark( 'Third Party managed in WooCommerce' ); ?> 146 <?php elseif ( 1 === $this->get_storage()['is_internal'] || '1' === $this->get_storage()['is_internal'] ) : ?> 147 <?php $this->output_yes_mark( 'Internal Integration managed in Hosted' ); ?> 147 148 <?php else : ?> 148 <?php esc_html_e( 'Error: No connection option ID found in settings! ', ACTIVECAMPAIGN_FOR_WOOCOMMERCE_LOCALIZATION_DOMAIN); ?>149 <?php $this->output_yes_mark( 'Third Party managed in WooCommerce' ); ?> 149 150 <?php endif; ?> 150 <?php else : ?>151 <?php if ( 1 === $this->get_storage()['is_internal'] || '1' === $this->get_storage()['is_internal'] ) : ?>152 <?php $this->output_yes_mark( $this->get_storage()['connection_option_id'] . ' | Internal Integration' ); ?>153 <?php else : ?>154 <?php $this->output_yes_mark( $this->get_storage()['connection_option_id'] ) . ' | Third Party'; ?>155 <?php endif; ?>156 <?php endif; ?>157 151 </td> 158 152 </tr> -
activecampaign-for-woocommerce/trunk/includes/class-activecampaign-for-woocommerce.php
r2988259 r2994180 898 898 ); 899 899 900 // This is for repair connection button 900 901 $this->loader->add_action( 901 902 'wp_ajax_activecampaign_for_woocommerce_reset_connection_id', -
activecampaign-for-woocommerce/trunk/includes/commands/class-activecampaign-for-woocommerce-create-or-update-connection-option-command.php
r2966088 r2994180 25 25 * @subpackage Activecampaign_For_Woocommerce/includes/commands 26 26 * @author acteamintegrations <team-integrations@activecampaign.com> 27 * @deprecated 27 28 */ 28 29 class Activecampaign_For_Woocommerce_Create_Or_Update_Connection_Option_Command implements Executable { … … 109 110 * @throws Activecampaign_For_Woocommerce_Resource_Unprocessable_Exception When the Connection Option is 110 111 * unprocessable. 112 * @deprecated 111 113 * @since 1.0.0 112 114 */ … … 154 156 * @since 1.0.0 155 157 * @access private 158 * @deprecated 156 159 */ 157 160 private function necessary_values_are_missing() { … … 165 168 * @since 1.0.0 166 169 * @access private 170 * @deprecated 167 171 */ 168 172 private function get_connection_option() { … … 187 191 * @since 1.0.0 188 192 * @access private 193 * @deprecated 189 194 */ 190 195 private function connection_option_id_cache_is_missing() { … … 198 203 * @since 1.0.0 199 204 * @access private 205 * @deprecated 200 206 */ 201 207 private function create_connection_option() { … … 232 238 /** 233 239 * Attempts to find the connection option by its connection id before creating. 240 * 241 * @deprecated 234 242 */ 235 243 private function maybe_find_connection_option_by_connection_id() { … … 271 279 * @since 1.0.0 272 280 * @access private 281 * @deprecated 273 282 */ 274 283 private function update_connection_option( $attempts = 0 ) { … … 276 285 277 286 // Don't override an existing ID. 287 if ( $this->storage['connection_id'] === $connection_option->get_connectionid() && 288 $this->storage['connection_option_id'] !== $connection_option->get_value() 289 ) { 290 $connection_option->set_id( $this->storage['connection_option_id'] ); 291 } 292 278 293 if ( ! $connection_option->get_id() ) { 279 294 $connection_option->set_id( $this->storage['connection_option_id'] ); … … 319 334 * @since 1.0.0 320 335 * @access private 336 * @deprecated 321 337 */ 322 338 private function update_connection_option_id_cache( $id ) { -
activecampaign-for-woocommerce/trunk/includes/config/activecampaign-for-woocommerce-global-constants.php
r2988259 r2994180 26 26 */ 27 27 if ( ! defined( 'ACTIVECAMPAIGN_FOR_WOOCOMMERCE_VERSION' ) ) { 28 define( 'ACTIVECAMPAIGN_FOR_WOOCOMMERCE_VERSION', '2.5. 0' );28 define( 'ACTIVECAMPAIGN_FOR_WOOCOMMERCE_VERSION', '2.5.1' ); 29 29 } 30 30 -
activecampaign-for-woocommerce/trunk/includes/products/class-activecampaign-for-woocommerce-product-sync-job.php
r2973117 r2994180 244 244 // Do not include groups for now. 245 245 try { 246 $safe_product_types = $this->get_cofe_safe_product_types(); 247 246 248 $data = [ 247 249 'limit' => (int) $limit, 248 250 'offset' => (int) $offset, 249 'type' => array( 'simple', 'variable', 'external', 'subscription', 'variable-subscription' ),251 'type' => $safe_product_types, 250 252 'orderby' => 'none', 251 253 'order' => 'ASC', … … 259 261 'Getting products by offset', 260 262 [ 263 'producttypes' => $safe_product_types, 261 264 'data' => $data, 262 265 'return_id_only' => $return_id_only, … … 748 751 wp_send_json_success( 'Product sync data reset.' ); 749 752 } 753 754 /** 755 * Gets the safe COFE product types. This is a blacklist to remove any types that cause duplicates, conflicts, or issues with sync. 756 * 757 * @return int[]|string[] 758 */ 759 private function get_cofe_safe_product_types() { 760 $product_types = wc_get_product_types(); 761 762 // Blacklist certain types that cause conflicts & duplicates 763 if ( isset( $product_types['grouped'] ) ) { 764 unset( $product_types['grouped'] ); 765 } 766 767 // WC returns array as type_name: type readable so return only the keys 768 return array_keys( $product_types ); 769 } 770 750 771 }
Note: See TracChangeset
for help on using the changeset viewer.