WooCommerce Checkout Manager - Version 6.2.0

Version Description

Download this release

Release Info

Developer quadlayers
Plugin Icon 128x128 WooCommerce Checkout Manager
Version 6.2.0
Comparing to
See all releases

Code changes from version 6.1.9 to 6.2.0

includes/class-wooccm-notices.php CHANGED
@@ -1,167 +1,93 @@
1
  <?php
2
 
3
- class WOOCCM_Notices
4
- {
5
-
6
- protected static $_instance;
7
-
8
- public function __construct()
9
- {
10
- add_action('wp_ajax_wooccm_dismiss_notice', array($this, 'ajax_dismiss_notice'));
11
- add_action('admin_notices', array($this, 'add_notices'));
12
- add_filter('plugin_action_links_' . plugin_basename(WOOCCM_PLUGIN_FILE), array($this, 'add_action_links'));
13
- }
14
-
15
- public static function instance()
16
- {
17
- if (is_null(self::$_instance)) {
18
- self::$_instance = new self();
19
- }
20
- return self::$_instance;
21
- }
22
-
23
- public function ajax_dismiss_notice()
24
- {
25
-
26
- if (check_admin_referer('wooccm_dismiss_notice', 'nonce') && isset($_REQUEST['notice_id'])) {
27
-
28
- $notice_id = sanitize_key($_REQUEST['notice_id']);
29
-
30
- update_user_meta(get_current_user_id(), $notice_id, true);
31
-
32
- wp_send_json($notice_id);
33
- }
34
-
35
- wp_die();
36
- }
37
-
38
- public function add_notices()
39
- {
40
-
41
- if (!get_user_meta(get_current_user_id(), 'wooccm-beta-notice', true) && get_option('wccs_settings')) {
42
- ?>
43
- <div class="wooccm-notice notice is-dismissible" data-notice_id="wooccm-beta-notice">
44
- <div class="notice-container" style="padding-top: 10px; padding-bottom: 10px; display: flex; justify-content: left; align-items: center;">
45
- <div class="notice-image">
46
- <img style="border-radius:50%;max-width: 90px;" src="<?php echo esc_url( plugins_url( '/assets/backend/img/logo.jpg', WOOCCM_PLUGIN_FILE ) ); ?>" alt="<?php echo esc_html( WOOCCM_PLUGIN_NAME ); ?>>">
47
- </div>
48
- <div class="notice-content" style="margin-left: 15px;">
49
- <p>
50
- <h3>Hello! the new admin panel is here!</h3>
51
- </p>
52
- <p>
53
- As you know, we've recently acquired this plugin and we've been working very hard to bring you a quality product.
54
- </p>
55
- <p>
56
- Finally, we're glad to introduce you to the new admin panel available in the WooCommerce &gt; Checkout dashboard.
57
- </p>
58
- <p>
59
- The entire panel has been rebuilt and now each field has its own modal of settings. Also, conditional relationships have been simplified.
60
- </p>
61
- <p>
62
- This has been a titanic task and we were forced to remove some settings. We want to apologies to you if you experience some issues in the last couple of updates or even in this one. :)
63
- </p>
64
- <p>
65
- Don't hesitate to contact us to report any issue or join our community to be in touch.
66
- </p>
67
- <p>
68
- We wish you the best! and good luck with your sales! The QuadLayers team.
69
- </p>
70
- <p>
71
- <a href="<?php echo esc_url(WOOCCM_GROUP_URL); ?>" class="button-primary" target="_blank">
72
- <?php esc_html_e('Join Community!', 'woocommerce-checkout-manager'); ?>
73
- </a>
74
- <a href="<?php echo esc_url(WOOCCM_SUPPORT_URL); ?>" class="button-secondary" target="_blank">
75
- <?php esc_html_e('Report a bug', 'woocommerce-checkout-manager'); ?>
76
- </a>
77
- <a style="margin-left: 10px;" href="https://quadlayers.com/?utm_source=wooccm_admin" target="_blank">
78
- <?php esc_html_e('About us', 'woocommerce-checkout-manager'); ?>
79
- </a>
80
- </p>
81
- </div>
82
- </div>
83
- </div>
84
- <?php
85
- } elseif (!get_user_meta(get_current_user_id(), 'wooccm-user-rating', true) && !get_transient('wooccm-first-rating') && !get_option('wccs_settings')) {
86
- ?>
87
- <div class="wooccm-notice notice is-dismissible" data-notice_id="wooccm-user-rating">
88
- <div class="notice-container" style="padding-top: 10px; padding-bottom: 10px; display: flex; justify-content: left; align-items: center;">
89
- <div class="notice-image">
90
- <img style="border-radius:50%;max-width: 90px;" src="<?php echo esc_url( plugins_url( '/assets/backend/img/logo.jpg', WOOCCM_PLUGIN_FILE ) ); ?>" alt="<?php echo esc_html(WOOCCM_PLUGIN_NAME); ?>>">
91
- </div>
92
- <div class="notice-content" style="margin-left: 15px;">
93
- <p>
94
- <?php printf(esc_html__('Hello! We\'ve recently acquired this plugin!', 'woocommerce-checkout-manager'), esc_html( WOOCCM_PLUGIN_NAME ) ); ?>
95
- <br />
96
- <?php esc_html_e('We will do our best to improve it and include new features gradually. Please be patient and let us know about the issues and improvements that you want to see in this plugin.', 'woocommerce-checkout-manager'); ?>
97
- </p>
98
- <a href="<?php echo esc_url(WOOCCM_GROUP_URL); ?>" class="button-primary" target="_blank">
99
- <?php esc_html_e('Join Community!', 'woocommerce-checkout-manager'); ?>
100
- </a>
101
- <a href="<?php echo esc_url(WOOCCM_SUPPORT_URL); ?>" class="button-secondary" target="_blank">
102
- <?php esc_html_e('Report a bug', 'woocommerce-checkout-manager'); ?>
103
- </a>
104
- <a style="margin-left: 10px;" href="https://quadlayers.com/?utm_source=wooccm_admin" target="_blank">
105
- <?php esc_html_e('About us', 'woocommerce-checkout-manager'); ?>
106
- </a>
107
- </div>
108
- </div>
109
- </div>
110
- <?php } elseif (!get_user_meta(get_current_user_id(), 'wooccm-update-5', true)) { ?>
111
- <div id="wooccm-update-5" class="wooccm-notice notice is-dismissible" data-notice_id="wooccm-update-5">
112
- <div class="notice-container" style="padding-top: 10px; padding-bottom: 10px; display: flex; justify-content: left; align-items: center;">
113
- <div class="notice-image">
114
- <img style="border-radius:50%;max-width: 90px;" src="<?php echo esc_url( plugins_url( '/assets/backend/img/logo.jpg', WOOCCM_PLUGIN_FILE ) ); ?>" alt="<?php echo esc_html(WOOCCM_PLUGIN_NAME); ?>>">
115
- </div>
116
- <div class="notice-content" style="margin-left: 15px;">
117
- <p>
118
- <b><?php printf(esc_html__('Important! Manual update is required.', 'woocommerce-checkout-manager'), esc_html( WOOCCM_PLUGIN_NAME ) ); ?></b>
119
- <br />
120
- <?php esc_html_e('Due to the recent WooCommerce 4.0 changes it is necessary to reconfigure conditional fields. If you have conditional fields, please go to the billing, shipping and advanced sections and set conditionals relationships again.', 'woocommerce-checkout-manager'); ?>
121
- </p>
122
- <a href="<?php echo esc_url( admin_url( 'admin.php?page=wc-settings&tab=wooccm' ) ); ?>" class="button-primary" target="_blank">
123
- <?php esc_html_e('Settings', 'woocommerce-checkout-manager'); ?>
124
- </a>
125
- <a href="<?php echo esc_url( str_replace( '/?utm_source=wooccm_admin', '/conditional/?utm_source=wooccm_admin', WOOCCM_DOCUMENTATION_URL ) ); ?>" class="button-secondary" target="_blank">
126
- <?php esc_html_e('Documentation', 'woocommerce-checkout-manager'); ?>
127
- </a>
128
- </div>
129
- </div>
130
- </div>
131
- <?php
132
- }
133
- ?>
134
- <script>
135
- (function($) {
136
- $('.wooccm-notice').on('click', '.notice-dismiss', function(e) {
137
- e.preventDefault();
138
- var notice_id = $(e.delegateTarget).data('notice_id');
139
- $.ajax({
140
- type: 'POST',
141
- url: ajaxurl,
142
- data: {
143
- notice_id: notice_id,
144
- action: 'wooccm_dismiss_notice',
145
- nonce: '<?php echo esc_attr( wp_create_nonce( 'wooccm_dismiss_notice' ) ); ?>'
146
- },
147
- success: function(response) {
148
- console.log(response);
149
- },
150
- });
151
- });
152
- })(jQuery);
153
- </script>
154
- <?php
155
- }
156
-
157
- public function add_action_links($links)
158
- {
159
-
160
- $links[] = '<a target="_blank" href="' . WOOCCM_PURCHASE_URL . '">' . esc_html__('Premium', 'woocommerce-checkout-manager') . '</a>';
161
- $links[] = '<a href="' . admin_url('admin.php?page=wc-settings&tab=' . sanitize_title(WOOCCM_PREFIX)) . '">' . esc_html__('Settings', 'woocommerce-checkout-manager') . '</a>';
162
-
163
- return $links;
164
- }
165
  }
166
 
167
  WOOCCM_Notices::instance();
1
  <?php
2
 
3
+ class WOOCCM_Notices {
4
+
5
+ protected static $_instance;
6
+
7
+ public function __construct() {
8
+ add_action( 'wp_ajax_wooccm_dismiss_notice', array( $this, 'ajax_dismiss_notice' ) );
9
+ add_action( 'admin_notices', array( $this, 'add_notices' ) );
10
+ add_filter( 'plugin_action_links_' . plugin_basename( WOOCCM_PLUGIN_FILE ), array( $this, 'add_action_links' ) );
11
+ }
12
+
13
+ public static function instance() {
14
+ if ( is_null( self::$_instance ) ) {
15
+ self::$_instance = new self();
16
+ }
17
+ return self::$_instance;
18
+ }
19
+
20
+ public function ajax_dismiss_notice() {
21
+ if ( check_admin_referer( 'wooccm_dismiss_notice', 'nonce' ) && isset( $_REQUEST['notice_id'] ) ) {
22
+
23
+ $notice_id = sanitize_key( $_REQUEST['notice_id'] );
24
+
25
+ update_user_meta( get_current_user_id(), $notice_id, true );
26
+
27
+ wp_send_json( $notice_id );
28
+ }
29
+
30
+ wp_die();
31
+ }
32
+
33
+ public function add_notices() {
34
+ if ( ! get_user_meta( get_current_user_id(), 'wooccm-user-rating', true ) && ! get_transient( 'wooccm-first-rating' ) && ! get_option( 'wccs_settings' ) ) {
35
+ ?>
36
+ <div class="wooccm-notice notice is-dismissible" data-notice_id="wooccm-user-rating">
37
+ <div class="notice-container" style="padding-top: 10px; padding-bottom: 10px; display: flex; justify-content: left; align-items: center;">
38
+ <div class="notice-image">
39
+ <img style="border-radius:50%;max-width: 90px;" src="<?php echo esc_url( plugins_url( '/assets/backend/img/logo.jpg', WOOCCM_PLUGIN_FILE ) ); ?>" alt="<?php echo esc_html( WOOCCM_PLUGIN_NAME ); ?>>">
40
+ </div>
41
+ <div class="notice-content" style="margin-left: 15px;">
42
+ <p>
43
+ <?php printf( esc_html__( 'Hello! We\'ve recently acquired this plugin!', 'woocommerce-checkout-manager' ), esc_html( WOOCCM_PLUGIN_NAME ) ); ?>
44
+ <br />
45
+ <?php esc_html_e( 'We will do our best to improve it and include new features gradually. Please be patient and let us know about the issues and improvements that you want to see in this plugin.', 'woocommerce-checkout-manager' ); ?>
46
+ </p>
47
+ <a href="<?php echo esc_url( WOOCCM_GROUP_URL ); ?>" class="button-primary" target="_blank">
48
+ <?php esc_html_e( 'Join Community!', 'woocommerce-checkout-manager' ); ?>
49
+ </a>
50
+ <a href="<?php echo esc_url( WOOCCM_SUPPORT_URL ); ?>" class="button-secondary" target="_blank">
51
+ <?php esc_html_e( 'Report a bug', 'woocommerce-checkout-manager' ); ?>
52
+ </a>
53
+ <a style="margin-left: 10px;" href="https://quadlayers.com/?utm_source=wooccm_admin" target="_blank">
54
+ <?php esc_html_e( 'About us', 'woocommerce-checkout-manager' ); ?>
55
+ </a>
56
+ </div>
57
+ </div>
58
+ </div>
59
+ <?php
60
+ }
61
+ ?>
62
+ <script>
63
+ (function($) {
64
+ $('.wooccm-notice').on('click', '.notice-dismiss', function(e) {
65
+ e.preventDefault();
66
+ var notice_id = $(e.delegateTarget).data('notice_id');
67
+ $.ajax({
68
+ type: 'POST',
69
+ url: ajaxurl,
70
+ data: {
71
+ notice_id: notice_id,
72
+ action: 'wooccm_dismiss_notice',
73
+ nonce: '<?php echo esc_attr( wp_create_nonce( 'wooccm_dismiss_notice' ) ); ?>'
74
+ },
75
+ success: function(response) {
76
+ console.log(response);
77
+ },
78
+ });
79
+ });
80
+ })(jQuery);
81
+ </script>
82
+ <?php
83
+ }
84
+
85
+ public function add_action_links( $links ) {
86
+ $links[] = '<a target="_blank" href="' . WOOCCM_PURCHASE_URL . '">' . esc_html__( 'Premium', 'woocommerce-checkout-manager' ) . '</a>';
87
+ $links[] = '<a href="' . admin_url( 'admin.php?page=wc-settings&tab=' . sanitize_title( WOOCCM_PREFIX ) ) . '">' . esc_html__( 'Settings', 'woocommerce-checkout-manager' ) . '</a>';
88
+
89
+ return $links;
90
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
91
  }
92
 
93
  WOOCCM_Notices::instance();
readme.txt CHANGED
@@ -5,7 +5,7 @@ Tags: checkout field editor, woocommerce checkout field editor, checkout manager
5
  Requires at least: 4.9
6
  Tested up to: 6.0.1
7
  Requires PHP: 5.6
8
- Stable tag: 6.1.9
9
  WC requires at least: 3.1.0
10
  WC tested up to: 6.8
11
  License: GPLv3
@@ -149,6 +149,9 @@ Your Order data can be reviewed in each order within the default WooCommerce Ord
149
 
150
  == Changelog ==
151
 
 
 
 
152
  = 6.1.9
153
  * Fix. WooCommerce Checkout WPML compatibility
154
  * Fix. WooCommerce Checkout Polylang compatibility
5
  Requires at least: 4.9
6
  Tested up to: 6.0.1
7
  Requires PHP: 5.6
8
+ Stable tag: 6.2.0
9
  WC requires at least: 3.1.0
10
  WC tested up to: 6.8
11
  License: GPLv3
149
 
150
  == Changelog ==
151
 
152
+ = 6.2.0
153
+ * Fix. PHP erros
154
+
155
  = 6.1.9
156
  * Fix. WooCommerce Checkout WPML compatibility
157
  * Fix. WooCommerce Checkout Polylang compatibility
woocommerce-checkout-manager.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin Name: Checkout Fields Manager for WooCommerce
5
  * Plugin URI: https://quadlayers.com/portfolio/woocommerce-checkout-manager/
6
  * Description: Manage and customize WooCommerce Checkout fields (Add, Edit, Delete or re-order fields).
7
- * Version: 6.1.9
8
  * Author: QuadLayers
9
  * Author URI: https://quadlayers.com
10
  * License: GPLv3
@@ -20,7 +20,7 @@ if ( ! defined( 'WOOCCM_PLUGIN_NAME' ) ) {
20
  define( 'WOOCCM_PLUGIN_NAME', 'Checkout Fields Manager for WooCommerce' );
21
  }
22
  if ( ! defined( 'WOOCCM_PLUGIN_VERSION' ) ) {
23
- define( 'WOOCCM_PLUGIN_VERSION', '6.1.9' );
24
  }
25
  if ( ! defined( 'WOOCCM_PLUGIN_FILE' ) ) {
26
  define( 'WOOCCM_PLUGIN_FILE', __FILE__ );
4
  * Plugin Name: Checkout Fields Manager for WooCommerce
5
  * Plugin URI: https://quadlayers.com/portfolio/woocommerce-checkout-manager/
6
  * Description: Manage and customize WooCommerce Checkout fields (Add, Edit, Delete or re-order fields).
7
+ * Version: 6.2.0
8
  * Author: QuadLayers
9
  * Author URI: https://quadlayers.com
10
  * License: GPLv3
20
  define( 'WOOCCM_PLUGIN_NAME', 'Checkout Fields Manager for WooCommerce' );
21
  }
22
  if ( ! defined( 'WOOCCM_PLUGIN_VERSION' ) ) {
23
+ define( 'WOOCCM_PLUGIN_VERSION', '6.2.0' );
24
  }
25
  if ( ! defined( 'WOOCCM_PLUGIN_FILE' ) ) {
26
  define( 'WOOCCM_PLUGIN_FILE', __FILE__ );