diff --git a/assets/js/admin.js b/assets/js/admin.js
index 34fcb29..9c5ee55 100644
--- a/assets/js/admin.js
+++ b/assets/js/admin.js
@@ -111,4 +111,13 @@
} );
} );
-})( jQuery );
\ No newline at end of file
+ // Dismiss notice
+ $('.wcct-notice-wrap').on( 'click', function() {
+ wp.ajax.send( 'wcct_dismissable_notice', {
+ success: function( response ) {
+ console.log( 'Success' );
+ }
+ } );
+ } );
+
+})( jQuery );
diff --git a/conversion-tracking.php b/conversion-tracking.php
index c291611..6934bae 100644
--- a/conversion-tracking.php
+++ b/conversion-tracking.php
@@ -3,12 +3,12 @@
Plugin Name: WooCommerce Conversion Tracking
Plugin URI: https://wedevs.com/products/plugins/woocommerce-conversion-tracking/
Description: Adds various conversion tracking codes to cart, checkout, registration success and product page on WooCommerce
-Version: 2.0.3
+Version: 2.0.4
Author: Tareq Hasan
Author URI: https://tareq.co/
License: GPL2
WC requires at least: 2.3
-WC tested up to: 3.6.2
+WC tested up to: 3.7.0
*/
/**
@@ -54,7 +54,7 @@ class WeDevs_WC_Conversion_Tracking {
*
* @var string
*/
- public $version = '2.0.3';
+ public $version = '2.0.4';
/**
* Holds various class instances
@@ -301,11 +301,16 @@ public function happy_addons_ads_banner() {
if ( class_exists( '\Happy_Addons\Elementor\Base' ) ) {
return;
}
+ $dismissable = get_option( 'wcct_dismissable_notice' );
+
+ if ( $dismissable == 'closed' ) {
+ return;
+ }
?>
+
diff --git a/includes/class-ajax.php b/includes/class-ajax.php
index 40a79b7..b404216 100644
--- a/includes/class-ajax.php
+++ b/includes/class-ajax.php
@@ -11,6 +11,7 @@ class WCCT_Ajax {
public function __construct() {
add_action( 'wp_ajax_wcct_save_settings', array( $this, 'wcct_save_settings' ) );
add_action( 'wp_ajax_activate_happy_addons', array( $this, 'wcct_install_happy_addons' ) );
+ add_action( 'wp_ajax_wcct_dismissable_notice', array( $this, 'wcct_dismissable_notice' ) );
}
/**
@@ -89,4 +90,18 @@ public function wcct_install_happy_addons() {
]);
}
+ /**
+ * Dismissable notice
+ *
+ * @return object
+ */
+ public function wcct_dismissable_notice() {
+ if ( ! current_user_can( 'manage_options' ) ) {
+ return;
+ }
+
+ update_option( 'wcct_dismissable_notice', 'closed' );
+
+ wp_send_json_success();
+ }
}
diff --git a/includes/integrations/class-integration-google.php b/includes/integrations/class-integration-google.php
index 7850ccb..d9a8958 100644
--- a/includes/integrations/class-integration-google.php
+++ b/includes/integrations/class-integration-google.php
@@ -10,7 +10,7 @@ class WCCT_Integration_Google extends WCCT_Integration {
*/
function __construct() {
$this->id = 'adwords';
- $this->name = __( 'Google Adwords', 'woocommerce-conversion-tracking' );
+ $this->name = __( 'Google Ads', 'woocommerce-conversion-tracking' );
$this->enabled = true;
$this->supports = array(
'checkout',
@@ -30,7 +30,7 @@ public function get_settings() {
'label' => __( 'Account ID', 'woocommerce-conversion-tracking' ),
'value' => '',
'placeholder' => 'AW-123456789',
- 'help' => sprintf( __( 'Provide the AdWords Account ID. Usually it\'s something like
AW-123456789
,
learn more.', 'woocommerce-conversion-tracking' ), 'https://wedevs.com/docs/woocommerce-conversion-tracking/google-adwords/account-id/?utm_source=wp-admin&utm_medium=inline-help&utm_campaign=wcct_docs&utm_content=adwords_learn_more' )
+ 'help' => sprintf( __( 'Provide the Google Ads Account ID. Usually it\'s something like
AW-123456789
,
learn more.', 'woocommerce-conversion-tracking' ), 'https://wedevs.com/docs/woocommerce-conversion-tracking/google-adwords/account-id/?utm_source=wp-admin&utm_medium=inline-help&utm_campaign=wcct_docs&utm_content=adwords_learn_more' )
),
'events' => array(
'type' => 'multicheck',
diff --git a/includes/views/settings.php b/includes/views/settings.php
index 21265e2..a64f06f 100644
--- a/includes/views/settings.php
+++ b/includes/views/settings.php
@@ -146,12 +146,12 @@
diff --git a/package.json b/package.json
index eb9a7c7..e7f192a 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "Woocommerce-Conversion-Tracking",
- "version": "2.0.3",
+ "version": "2.0.4",
"description": "Conversion tracking plugin for WooCommerce",
"author": "Tareq Hasan",
"license": "GPL",
diff --git a/readme.txt b/readme.txt
index ee85e2b..09205c9 100644
--- a/readme.txt
+++ b/readme.txt
@@ -4,7 +4,7 @@ Tags: ecommerce, e-commerce, commerce, woocommerce, tracking, facebook, google,
Donate link: https://tareq.co/donate/
Requires at least: 4.0
Tested up to: 5.1.1
-Stable tag: 2.0.2
+Stable tag: 2.0.4
License: GPLv3
License URI: http://www.gnu.org/licenses/gpl-3.0.html
@@ -88,6 +88,11 @@ We put the JavaScript scripts provided by you in the page and it fires a convers
5. Custom Codes
== Changelog ==
+= Version 2.0.4 (21-August-2019) =
+* [fix] Happyaddons dismissable banner
+* [fix] Getting started link doesn't work
+* [tweak] Change from Google Adwords to Google Ads
+
= Version 2.0.3 (05-August-2019) =
* [fix] AddToCart Event doesn't work for ajax
* [new] Add happy addons banner