Plugin Directory

Changeset 3358433


Ignore:
Timestamp:
09/09/2025 08:46:37 AM (4 months ago)
Author:
enituretechnology
Message:

3.3.7

  • Update: Introduced a new setting in Quote Settings to always include Lift Gate Delivery for Limited Access deliveries.

Ticket: 29383074366

Location:
ltl-freight-quotes-rl-edition/trunk
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • ltl-freight-quotes-rl-edition/trunk/js/en-rnl.js

    r3241903 r3358433  
    293293            jQuery("#rnl_quotes_liftgate_delivery_as_option").prop({checked: false});
    294294            jQuery("#en_woo_addons_liftgate_with_auto_residential").prop({checked: false});
     295            jQuery("#rnl_quotes_always_quote_liftgate_when_limited_access").prop({checked: false});
    295296
    296297        } else if (id == "rnl_quotes_liftgate_delivery_as_option" ||
    297             id == "en_woo_addons_liftgate_with_auto_residential") {
     298            id == "en_woo_addons_liftgate_with_auto_residential" || id == "rnl_quotes_always_quote_liftgate_when_limited_access") {
    298299            jQuery("#wc_settings_rnl_liftgate").prop({checked: false});
    299300        }
     
    565566    // limited access delivery
    566567    jQuery("#rnl_limited_access_delivery").closest('tr').addClass("rnl_limited_access_delivery");
    567     jQuery("#rnl_limited_access_delivery_as_option").closest('tr').addClass("rnl_limited_access_delivery_as_option");
     568    jQuery("#rnl_limited_access_delivery_as_option, #rnl_quotes_always_quote_liftgate_when_limited_access").closest('tr').addClass("rnl_limited_access_delivery_as_option");
    568569    jQuery("#rnl_limited_access_delivery_fee").closest('tr').addClass("rnl_limited_access_delivery_fee");
    569570
     
    573574        const id = jQuery(this).attr('id');
    574575        id == 'rnl_limited_access_delivery'
    575             ? jQuery('#rnl_limited_access_delivery_as_option').prop({ checked: false })
     576            ? jQuery('#rnl_limited_access_delivery_as_option, #rnl_quotes_always_quote_liftgate_when_limited_access').prop({ checked: false })
    576577            : jQuery('#rnl_limited_access_delivery').prop({ checked: false });
    577578
     
    579580
    580581        if (jQuery('#rnl_limited_access_delivery_as_option').prop('checked') == false &&
    581             jQuery('#rnl_limited_access_delivery').prop('checked') == false) {
     582            jQuery('#rnl_limited_access_delivery').prop('checked') == false && jQuery('#rnl_quotes_always_quote_liftgate_when_limited_access').prop('checked') == false) {
    582583            jQuery('.rnl_limited_access_delivery_fee').css('display', 'none');
    583584        }
     
    585586
    586587    if (jQuery("#rnl_limited_access_delivery_as_option").prop("checked") == false &&
    587         jQuery("#rnl_limited_access_delivery").prop("checked") == false) {
     588        jQuery("#rnl_limited_access_delivery").prop("checked") == false && jQuery("#rnl_quotes_always_quote_liftgate_when_limited_access") == false) {
    588589        jQuery('.rnl_limited_access_delivery_fee').css('display', 'none');
    589590    }
  • ltl-freight-quotes-rl-edition/trunk/ltl-freight-quotes-rnl-edition.php

    r3314366 r3358433  
    44 * Plugin URI:     https://eniture.com/products/
    55 * Description:    Dynamically retrieves your negotiated shipping rates from R+L Freight and displays the results in the WooCommerce shopping cart.
    6  * Version:        3.3.6
     6 * Version:        3.3.7
    77 * Author:         Eniture Technology
    88 * Author URI:     http://eniture.com/
     
    1010 * License:        GPL version 2 or later - http://www.eniture.com/
    1111 * WC requires at least: 6.4
    12  * WC tested up to: 9.9.4
     12 * WC tested up to: 10.1.2
    1313 */
    1414if (!defined('ABSPATH')) {
     
    222222    {
    223223        wp_enqueue_script('jquery');
    224         wp_enqueue_script('en_rnl_script', plugin_dir_url(__FILE__) . 'js/en-rnl.js', array(), '1.1.3');
     224        wp_enqueue_script('en_rnl_script', plugin_dir_url(__FILE__) . 'js/en-rnl.js', array(), '1.1.4');
    225225        wp_localize_script('en_rnl_script', 'en_rnl_admin_script', array(
    226226            'plugins_url' => plugins_url(),
  • ltl-freight-quotes-rl-edition/trunk/readme.txt

    r3314366 r3358433  
    33Tags: eniture,R+L,,LTL freight rates,LTL freight quotes, shipping estimates
    44Requires at least: 6.4
    5 Tested up to: 6.8.1
    6 Stable tag: 3.3.6
     5Tested up to: 6.8
     6Stable tag: 3.3.7
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    152152== Changelog ==
    153153
     154= 3.3.7 =
     155* Update: Introduced a new setting in Quote Settings to always include Lift Gate Delivery for Limited Access deliveries.
     156
    154157= 3.3.6 =
    155158* Update: Addressed a customer-specific issue involving dynamically created variants where the underlying products were being changed.
  • ltl-freight-quotes-rl-edition/trunk/rnl-carrier-service.php

    r3314366 r3358433  
    182182        $post_data = apply_filters('en_request_handler', $post_data, 'rnl');
    183183
    184         if ($this->quote_settings['liftgate_delivery_option'] == "yes") {
     184        if ($this->quote_settings['liftgate_delivery_option'] == "yes" || $this->quote_settings['liftgate_limited_access_delivery'] == "yes") {
    185185            $post_data['liftgateDelivery'] = 'Y';
    186186        }
     
    575575                       
    576576                        // Add limited access delivery fee in quote price and surcharge in rates surcharges array
    577                         if ($this->quote_settings['limited_access_delivery_option'] == 'yes' || ($this->quote_settings['limited_access_delivery'] == 'yes' && !in_array('R', $label_sufex_arr))) {
     577                        if ($this->quote_settings['limited_access_delivery_option'] == 'yes' || $this->quote_settings['liftgate_limited_access_delivery'] == 'yes' || ($this->quote_settings['limited_access_delivery'] == 'yes' && !in_array('R', $label_sufex_arr))) {
    578578                            $price = $this->addLimitedAccessDelFee($price);
    579579                            $surcharges = isset($surcharges) ? $surcharges : [];
     
    681681                        }
    682682
    683                         // When Limited Access As An Option Enabled                       
     683                        // When Limited Access As An Option Enabled
    684684                        $limited_access_quotes = [];
    685                         if ($this->quote_settings['limited_access_delivery_option'] == 'yes') {
     685                        if ($this->quote_settings['limited_access_delivery_option'] == 'yes' || $this->quote_settings['liftgate_limited_access_delivery'] == 'yes') {
    686686                           
    687687                            $limited_access_quotes = $quotes;
     
    872872    }
    873873
    874     function addLimitedAccessDelFee($charges) 
    875     {
    876         $is_limited_access_active = get_option('rnl_limited_access_delivery') == 'yes' || get_option('rnl_limited_access_delivery_as_option') == 'yes';
     874    function addLimitedAccessDelFee($charges)
     875    {
     876        $is_limited_access_active = get_option('rnl_limited_access_delivery') == 'yes' || get_option('rnl_limited_access_delivery_as_option') == 'yes' || get_option('rnl_quotes_always_quote_liftgate_when_limited_access') == 'yes';
    877877        $limited_access_fee = !empty(get_option('rnl_limited_access_delivery_fee')) ? get_option('rnl_limited_access_delivery_fee') : 0;
    878878
  • ltl-freight-quotes-rl-edition/trunk/rnl-shipping-class.php

    r3241903 r3358433  
    7979                $this->web_service_inst->quote_settings['residential_delivery'] = get_option('wc_settings_rnl_residential');
    8080                $this->web_service_inst->quote_settings['liftgate_resid_delivery'] = get_option('en_woo_addons_liftgate_with_auto_residential');
     81                $this->web_service_inst->quote_settings['liftgate_limited_access_delivery'] = get_option('rnl_quotes_always_quote_liftgate_when_limited_access');
    8182                $this->web_service_inst->quote_settings['limited_access_delivery'] = get_option('rnl_limited_access_delivery');
    8283                $this->web_service_inst->quote_settings['transit_time'] = get_option('wc_settings_rnl_delivey_estimate');
     
    829830                $rates = [];
    830831
    831                 foreach ($combined_quotes as $quote) {
     832                foreach ($combined_quotes as $key => $quote) {
    832833                    if (isset($quote['hold_at_terminal_quotes'])) {
    833834                        $rates[] = $quote['hold_at_terminal_quotes'];
     
    839840                    unset($quote['limited_access_quotes']);
    840841                    $lfg_quotes = $this->remove_array($quote, 'simple_quotes');
     842
     843                    if ($this->quote_settings['liftgate_limited_access_delivery'] == 'yes' && empty($simple_quotes)) {
     844                        $lfg_fee = isset($lfg_quotes['surcharges']['LIFT']) ? $lfg_quotes['surcharges']['LIFT'] : 0;
     845                        $lfg_quotes['cost'] -= floatval($lfg_fee) ;
     846
     847                        $simple_quotes = $lfg_quotes;
     848                    }
     849
    841850                    $rates[] = $lfg_quotes;
    842                     if (!empty($limited_access_quotes)) $rates[] = $limited_access_quotes;
     851                    if (!empty($limited_access_quotes) && $this->quote_settings['liftgate_limited_access_delivery'] != 'yes') $rates[] = $limited_access_quotes;
    843852                   
    844853                    $en_accessorial_excluded = apply_filters('en_rnl_ltl_accessorial_excluded', []);
     
    875884                        }
    876885   
    877                         $rates[] = $lfg_and_limited_quotes;                       
     886                        $rates[] = $lfg_and_limited_quotes;
    878887                    }
    879888   
  • ltl-freight-quotes-rl-edition/trunk/template/quote-settings.php

    r3241903 r3358433  
    335335                'id' => 'rnl_limited_access_delivery_as_option',
    336336                'class' => "limited_access_add ",
     337            ),
     338            'rnl_quotes_always_quote_liftgate_when_limited_access' => array(
     339                'name' => __('Always include lift gate delivery for limited access deliveries', 'rnl_freight_wc_settings'),
     340                'type' => 'checkbox',
     341                'desc' => '',
     342                'class' => 'limited_access_add',
     343                'id' => 'rnl_quotes_always_quote_liftgate_when_limited_access'
    337344            ),
    338345            'rnl_limited_access_delivery_fee' => array(
Note: See TracChangeset for help on using the changeset viewer.