Plugin Directory

Changeset 2687864


Ignore:
Timestamp:
03/02/2022 11:43:14 PM (4 years ago)
Author:
wpconcierges
Message:

1.0.6 fixing bugs with Revcent

Location:
autopopulate-checkout-for-woocommerce/trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • autopopulate-checkout-for-woocommerce/trunk/README.txt

    r2687799 r2687864  
    55Requires at least: 3.0.1
    66Tested up to: 5.9.1
    7 Stable tag: 1.0.5
     7Stable tag: 1.0.6
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    4545
    4646== Changelog ==
     47= 1.0.6 =
     48Fixed bugs with Revcent integration
    4749= 1.0.5 =
    4850= 1.0.4 =
  • autopopulate-checkout-for-woocommerce/trunk/admin/class-autopopulate-checkout-woo-admin.php

    r2687776 r2687864  
    179179
    180180      add_settings_field(
    181         $field,
     181        'add-prospect-revcent',
    182182        apply_filters( $this->plugin_name . 'label-add-prospect-revcent', esc_html__('Enable Send Prospect to Revcent ',$this->plugin_name) ),
    183         array( $this, 'field_checkout' ),
     183        array( $this, 'field_select' ),
    184184        $this->plugin_name,
    185185        $this->plugin_name . '-messages',
     
    187187            'description'   => 'Enable Revcent',
    188188            'id'            => 'add-prospect-revcent',
    189             'value'         => '1',
     189            'value'         => '',
    190190        )
    191191    );   
     
    211211        $defaults['label']          = '';
    212212        $defaults['name']           = $this->plugin_name . '-options[' . $args['id'] . ']';
    213         $defaults['selections']     =array('post','get');
     213        $defaults['selections']     =array('no','yes');
    214214        $defaults['value']          = '';
    215215
     
    338338        }
    339339       
     340        $options[] = array('add-prospect-revcent','select','Enable Revcent');
    340341       
    341342        return $options;
  • autopopulate-checkout-for-woocommerce/trunk/admin/partials/autopopulate-checkout-woo-admin-field-checkbox.php

    r2354888 r2687864  
    2121        type="checkbox"
    2222        value="1" />
    23     <span class="description"><?php esc_html_e( $atts['description'], 'pixelforms' ); ?></span>
     23    <span class="description"><?php esc_html_e( $atts['description'], 'autopopulate-checkout-woo' ); ?></span>
    2424</label>
  • autopopulate-checkout-for-woocommerce/trunk/admin/partials/autopopulate-checkout-woo-admin-field-select.php

    r2354888 r2687864  
    11<?php
    22
    3 /**a
     3/**
    44 * Provide a view for a section
    55 *
     
    1212 * @subpackage order_postback_woo/admin/partials
    1313 */
    14 
    1514if ( ! empty( $atts['label'] ) ) {
    16 
    17     ?><label for="<?php echo esc_attr( $atts['id'] ); ?>"><?php esc_html_e( $atts['label'], 'pixels' ); ?>: </label><?php
    18 
     15    ?><label for="<?php echo esc_attr( $atts['id'] ); ?>"><?php esc_html_e( $atts['label'], 'autopopulate-checkout-woo' ); ?>: </label><?php
    1916}
    20 
    2117?><select
    22     aria-label="<?php esc_attr( _e( $atts['aria'], 'pixelforms' ) ); ?>"
     18    aria-label="<?php esc_attr( _e( $atts['aria'], 'autopopulate-checkout-woo' ) ); ?>"
    2319    class="<?php echo esc_attr( $atts['class'] ); ?>"
    2420    id="<?php echo esc_attr( $atts['id'] ); ?>"
     
    2723if ( ! empty( $atts['blank'] ) ) {
    2824
    29     ?><option value><?php esc_html_e( $atts['blank'], 'pixelforms' ); ?></option><?php
     25    ?><option value><?php esc_html_e( $atts['blank'], 'autopopulate-checkout-woo' ); ?></option><?php
    3026
    3127}
     
    4945        selected( $atts['value'], $value ); ?>><?php
    5046
    51         esc_html_e( $label, 'pixelforms' );
     47        esc_html_e( $label, 'autopopulate-checkout-woo' );
    5248
    5349    ?></option><?php
     
    5652
    5753?></select>
    58 <span class="description"><?php esc_html_e( $atts['description'], 'pixelforms' ); ?></span>
     54<span class="description"><?php esc_html_e( $atts['description'], 'autopopulate-checkout-woo' ); ?></span>
    5955</label>
  • autopopulate-checkout-for-woocommerce/trunk/autopopulate-checkout-woo.php

    r2687799 r2687864  
    1717 * Plugin URI:        https://www.wpconcierges.com/plugins/autopopulate-checkout-woo/
    1818 * Description:       Pass in values for shipping, billing, to any page of your site and the plugin will create a customer session that is used on the Woocommerce Checkout page.
    19  * Version:           1.0.5
     19 * Version:           1.0.6
    2020 * Author:            WpConcierges
    2121 * Author URI:        https://www.wpconcierges.com/plugins/
     
    2525 * Domain Path:       /languages
    2626 * WC requires at least: 3.0
    27  * WC tested up to: 6.
     27 * WC tested up to: 6.2.1
    2828 */
    2929
     
    3838 * Rename this for your plugin and update it as you release new versions.
    3939 */
    40 define( 'AUTOPOPULATE_CHECKOUT_WOO_VERSION', '1.0.4' );
     40define( 'AUTOPOPULATE_CHECKOUT_WOO_VERSION', '1.0.6' );
    4141
    4242/**
  • autopopulate-checkout-for-woocommerce/trunk/includes/class-autopopulate-checkout-woo.php

    r2687799 r2687864  
    7171            $this->version = AUTOPOPULATE_CHECKOUT_WOO_VERSION;
    7272        } else {
    73             $this->version = '1.0.5';
     73            $this->version = '1.0.6';
    7474        }
    7575        $this->plugin_name = $this->autopopulate_checkout_woo = 'autopopulate-checkout-woo';
  • autopopulate-checkout-for-woocommerce/trunk/public/class-autopopulate-checkout-woo-public.php

    r2687799 r2687864  
    292292       
    293293            if(class_exists("revcent_payments")){
    294                 $this->revcent_options=get_optin("woocommerce_revcent_payments_settings",array()); 
     294                $this->revcent_options=get_option("woocommerce_revcent_payments_settings",array());
    295295                if(count($this->revcent_options)){
    296296                 $this->revcent_campaign = $this->revcent_options['revcent_campaign'];
     
    307307    private function send_revcent_customer(){
    308308        $payload_rq = $this->create_revcent_customer();
    309         $response = wp_remote_post($this->revcent_url, array(
    310             'method' => 'POST',
    311             'headers' => array(
     309       
     310        if(count($payload_rq)){
     311         $response = wp_remote_post($this->revcent_url, array(
     312             'method' => 'POST',
     313             'headers' => array(
    312314                'x-api-key' => $this->revcent_api_key,
    313             ),
    314             'body' => json_encode($payload_rq),
    315             'timeout' => 90,
    316             'sslverify' => false,
    317         ));
     315             ),
     316             'body' => json_encode($payload_rq),
     317             'timeout' => 90,
     318             'sslverify' => false,
     319          ));
     320        }
    318321    }
    319322
    320323    private function create_revcent_customer(){
    321324        global $woocommerce;
    322        
     325       
     326     $payload =array();   
    323327        $metadata = array();
    324328       
    325 
     329     if(!is_null($woocommerce)){
    326330        if(isset($_COOKIE['affid'])){
    327331         $obj = new stdClass();
     
    371375             $city = $woocommerce->customer->get_billing_city();
    372376
    373              if(!is_null($$woocommerce->customer->get_billing_state()))
    374              $state = $$woocommerce->customer->get_billing_state();
     377             if(!is_null($woocommerce->customer->get_billing_state()))
     378             $state = $woocommerce->customer->get_billing_state();
    375379
    376380             if(!is_null($woocommerce->customer->get_billing_postcode()))
     
    389393             $phone =$woocommerce->customer->get_billing_phone();
    390394
    391 
    392             $payload =array();
    393395
    394396            $payload['request'] = array(
     
    424426                "metadata" => $metadata,
    425427            );
    426 
     428    }
    427429            return $payload;
    428430           
Note: See TracChangeset for help on using the changeset viewer.