Printful Integration for WooCommerce - Version 2.0.8

Version Description

Shipping & Tax information improvements

Download this release

Release Info

Developer printful
Plugin Icon 128x128 Printful Integration for WooCommerce
Version 2.0.8
Comparing to
See all releases

Code changes from version 2.0.7 to 2.0.8

includes/class-printful-admin-settings.php CHANGED
@@ -16,6 +16,12 @@ class Printful_Admin_Settings {
16
  */
17
  public static function getIntegrationFields()
18
  {
 
 
 
 
 
 
19
  return array(
20
  'printful_key' => array(
21
  'title' => __( 'Printful store API key', 'printful' ),
@@ -27,7 +33,10 @@ class Printful_Admin_Settings {
27
  'calculate_tax' => array(
28
  'title' => __( 'Calculate sales tax', 'printful' ),
29
  'type' => 'checkbox',
30
- 'label' => __( 'Calculated for all products shipped to North Carolina and California', 'printful' ),
 
 
 
31
  'default' => 'no',
32
  ),
33
  'disable_ssl' => array(
@@ -125,11 +134,22 @@ class Printful_Admin_Settings {
125
  * @throws PrintfulException
126
  */
127
  public function setup_carrier_fields() {
 
 
 
 
 
128
 
129
  $carrier_settings = array(
130
- 'title' => __( 'Carriers & Services', 'printful' ),
131
- 'description' => __( "You can specify here which shipping carriers are available for this store.\n
132
- Uncheck the ones you want to disable. If you leave “Flat rate” checked it means that any order where flat rate was selected can still ship with any carrier and service.", 'printful' ),
 
 
 
 
 
 
133
  'settings' => array(),
134
  );
135
 
16
  */
17
  public static function getIntegrationFields()
18
  {
19
+ $sales_tax_link = sprintf(
20
+ '<a href="%s" target="_blank">%s</a>',
21
+ esc_url( 'https://www.printful.com/faq/taxes-and-billing/sales-tax/371-which-states-does-printful-charge-sales-tax-in-' ),
22
+ esc_html__( 'states where Printful applies sales tax', 'printful' )
23
+ );
24
+
25
  return array(
26
  'printful_key' => array(
27
  'title' => __( 'Printful store API key', 'printful' ),
33
  'calculate_tax' => array(
34
  'title' => __( 'Calculate sales tax', 'printful' ),
35
  'type' => 'checkbox',
36
+ 'label' => sprintf(
37
+ 'Calculated for all products shipped to %s',
38
+ $sales_tax_link
39
+ ),
40
  'default' => 'no',
41
  ),
42
  'disable_ssl' => array(
134
  * @throws PrintfulException
135
  */
136
  public function setup_carrier_fields() {
137
+ $flat_rate_link = sprintf(
138
+ '<a href="%s" target="_blank">%s</a>',
139
+ esc_url( 'https://www.printful.com/shipping' ),
140
+ esc_html__( 'flat rates', 'printful' )
141
+ );
142
 
143
  $carrier_settings = array(
144
+ 'title' => __( 'Shipping Methods', 'printful' ),
145
+ 'description' => sprintf(
146
+ "Here you can choose the shipping methods you want Printful to use for shipping your orders.
147
+ Uncheck the ones you want to disable. From your selection, our algorithm will determine the fastest, most cost-effective, and most reliable method for each order. <br /><br />
148
+ Checking “Flat Rate” enables Printful %s as a shipping option. When an order comes in and “Flat Rate” is the most cost-effective shipping option you’ve enabled, that’s the rate we’ll charge you.
149
+ The order will be shipped with the least expensive shipping method available, regardless of what others you’ve enabled.
150
+ So if you want to use only specific shipping methods, make sure “Flat Rate” is disabled.",
151
+ $flat_rate_link
152
+ ),
153
  'settings' => array(),
154
  );
155
 
includes/templates/setting-group.php CHANGED
@@ -9,7 +9,7 @@
9
  <div class="printful-setting-group">
10
 
11
  <h2><?php echo esc_html($title); ?></h2>
12
- <p><?php echo esc_html($description); ?></p>
13
 
14
  <?php if ( !empty( $settings ) ) : ?>
15
 
@@ -41,7 +41,10 @@
41
  <?php elseif ($setting['type'] == 'checkbox') : ?>
42
 
43
  <label for="<?php echo esc_attr($key); ?>">
44
- <input class="" type="checkbox" name="<?php echo esc_attr($key); ?>" id="<?php echo esc_attr($key); ?>" value="1" <?php if($setting['value'] == 'yes') { echo 'checked="checked"'; } ?>><?php echo esc_html($setting['label']); ?></label><br>
 
 
 
45
 
46
  <?php elseif ($setting['type'] == 'checkbox-group') : ?>
47
 
9
  <div class="printful-setting-group">
10
 
11
  <h2><?php echo esc_html($title); ?></h2>
12
+ <p><?php _e( $description, 'printful' ); ?></p>
13
 
14
  <?php if ( !empty( $settings ) ) : ?>
15
 
41
  <?php elseif ($setting['type'] == 'checkbox') : ?>
42
 
43
  <label for="<?php echo esc_attr($key); ?>">
44
+ <input class="" type="checkbox" name="<?php echo esc_attr($key); ?>" id="<?php echo esc_attr($key); ?>" value="1" <?php if($setting['value'] == 'yes') { echo 'checked="checked"'; } ?>>
45
+ <?php _e( $setting['label'] , 'printful' ); ?>
46
+ </label>
47
+ <br>
48
 
49
  <?php elseif ($setting['type'] == 'checkbox-group') : ?>
50
 
printful-shipping.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Printful Integration for WooCommerce
4
  Plugin URI: https://wordpress.org/plugins/printful-shipping-for-woocommerce/
5
  Description: Calculate correct shipping and tax rates for your Printful-Woocommerce integration.
6
- Version: 2.0.7
7
  Author: Printful
8
  Author URI: http://www.printful.com
9
  License: GPL2 http://www.gnu.org/licenses/gpl-2.0.html
@@ -20,7 +20,7 @@ if ( ! defined( 'PF_PLUGIN_FILE' ) ) {
20
 
21
  class Printful_Base {
22
 
23
- const VERSION = '2.0.7';
24
  const PF_HOST = 'https://www.printful.com/';
25
  const PF_API_HOST = 'https://api.printful.com/';
26
 
3
  Plugin Name: Printful Integration for WooCommerce
4
  Plugin URI: https://wordpress.org/plugins/printful-shipping-for-woocommerce/
5
  Description: Calculate correct shipping and tax rates for your Printful-Woocommerce integration.
6
+ Version: 2.0.8
7
  Author: Printful
8
  Author URI: http://www.printful.com
9
  License: GPL2 http://www.gnu.org/licenses/gpl-2.0.html
20
 
21
  class Printful_Base {
22
 
23
+ const VERSION = '2.0.8';
24
  const PF_HOST = 'https://www.printful.com/';
25
  const PF_API_HOST = 'https://api.printful.com/';
26
 
readme.txt CHANGED
@@ -2,8 +2,8 @@
2
  Contributors: girts_u, kievins, kberzins
3
  Tags: woocommerce, printful, drop shipping, shipping, shipping rates, fulfillment, printing, fedex, carriers, checkout, t-shirts
4
  Requires at least: 3.8
5
- Tested up to: 5.0
6
- Stable tag: 2.0.7
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -19,7 +19,7 @@ See your order, revenue and profit statistics on WooCommerce Printful's dashboar
19
  1. Click the "Connect" button or add your Printful API key manually to Printful->Settings tab
20
  1. Enable shipping rate calculation in WooCommerce->Settings->Shipping->Printful Shipping tab
21
  1. To automatically calculate taxes please check 'Enable taxes and tax calculations' under WooCommerce Tax settings.
22
- 1. Then go to Printful->Settings tab and check 'Calculated for all products shipped to North Carolina and California'.
23
 
24
  == Frequently Asked Questions ==
25
 
@@ -38,6 +38,9 @@ Go to https://www.printful.com/dashboard/store , select your WooCommerce store,
38
 
39
  == Upgrade Notice ==
40
 
 
 
 
41
  = 2.0.7 =
42
  Bug fixes, security improvements and improved i18n support
43
 
@@ -109,6 +112,9 @@ First release
109
 
110
  == Changelog ==
111
 
 
 
 
112
  = 2.0.7 =
113
  * Bug fixes, security improvements and improved i18n support
114
 
2
  Contributors: girts_u, kievins, kberzins
3
  Tags: woocommerce, printful, drop shipping, shipping, shipping rates, fulfillment, printing, fedex, carriers, checkout, t-shirts
4
  Requires at least: 3.8
5
+ Tested up to: 5.1
6
+ Stable tag: 2.0.8
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
19
  1. Click the "Connect" button or add your Printful API key manually to Printful->Settings tab
20
  1. Enable shipping rate calculation in WooCommerce->Settings->Shipping->Printful Shipping tab
21
  1. To automatically calculate taxes please check 'Enable taxes and tax calculations' under WooCommerce Tax settings.
22
+ 1. Then go to Printful->Settings tab and check 'Calculated for all products shipped to states where Printful applies sales tax'.
23
 
24
  == Frequently Asked Questions ==
25
 
38
 
39
  == Upgrade Notice ==
40
 
41
+ = 2.0.8 =
42
+ Shipping & Tax information improvements
43
+
44
  = 2.0.7 =
45
  Bug fixes, security improvements and improved i18n support
46
 
112
 
113
  == Changelog ==
114
 
115
+ = 2.0.8 =
116
+ * Shipping & Tax information improvements
117
+
118
  = 2.0.7 =
119
  * Bug fixes, security improvements and improved i18n support
120