From: Steve Sutton Date: Wed, 14 Aug 2019 10:11:10 +0000 (-0400) Subject: Update for saving billing data with new account X-Git-Tag: v1.0.34^2 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/?a=commitdiff_plain;h=d8d56ee0d62da57b29c43c2c7b44b3cd7008cb9a;p=WP-Plugins%2Fglm-member-db-billing.git Update for saving billing data with new account when $invoic_type is 0 This is for free member types --- diff --git a/classes/billingSupport.php b/classes/billingSupport.php index b54a77f..7fc9d7c 100644 --- a/classes/billingSupport.php +++ b/classes/billingSupport.php @@ -1709,7 +1709,6 @@ class GlmBillingSupport $account = $this->getAccountByRefDest( $member_id ); // New Billing Data If using Billing Fields - // echo '
$billing_updated: ' . print_r( $billing_updated, true ) . '
'; // Check for required fields foreach ( $billing_updated as $field_name => $field_value ) { $key = array_search( $field_name, $required_fields ); @@ -1753,7 +1752,7 @@ class GlmBillingSupport $billing_updated['ref_name'] = $member_name; // Use members name $billing_updated['ref_dest'] = $member_id; $billing_updated['anniversary_date'] = date('Y-m-d H:i:s'); - $billing_updated['invoice_type'] = $invoice_type; + $billing_updated['invoice_type'] = ( $invoice_type ) ? $invoice_type : 0; $billing_updated_format[] = '%s'; $billing_updated_format[] = '%d'; $billing_updated_format[] = '%s'; @@ -1768,7 +1767,6 @@ class GlmBillingSupport return $errors; } } - // echo '
$errors: ' . print_r( $errors, true ) . '
'; return true; } diff --git a/index.php b/index.php index cd73b5a..d1bd2f9 100644 --- a/index.php +++ b/index.php @@ -3,7 +3,7 @@ * Plugin Name: GLM Members Billing * Plugin URI: http://www.gaslightmedia.com/ * Description: This is glmAssociate Billing Module - * Version: 1.0.33 + * Version: 1.0.34 * Author: Gaslight Media * Author URI: http://www.gaslightmedia.com/ * License: GPL2 @@ -19,7 +19,7 @@ * @package glmMembersBillingAddOn * @author Chuck Scott * @license http://www.gaslightmedia.com Gaslightmedia - * @version 1.0.33 + * @version 1.0.34 */ /* @@ -37,7 +37,7 @@ * so that we're sure the other add-ons see an up to date * version from this plugin. */ -define('GLM_MEMBERS_BILLING_PLUGIN_VERSION', '1.0.33'); +define('GLM_MEMBERS_BILLING_PLUGIN_VERSION', '1.0.34'); // Database Version define('GLM_MEMBERS_BILLING_PLUGIN_DB_VERSION', '0.0.26');