Plugin Directory

Changeset 3227128


Ignore:
Timestamp:
01/23/2025 12:18:17 AM (15 months ago)
Author:
gplsaver
Message:

fix password file
WooCommerce 9.60

Location:
woo-rfq-for-woocommerce
Files:
115 added
7 edited

Legend:

Unmodified
Added
Removed
  • woo-rfq-for-woocommerce/trunk/changelog.txt

    r3195129 r3227128  
    11== Changelog ==
     2
     3= 1.9.180 1/22/2025 =
     4fix password file
     5
    26= 1.9.179 11/22/2024 =
    37languge file corruption fixed
  • woo-rfq-for-woocommerce/trunk/gpls_assets/js/gpls_woo_password.js

    r3108931 r3227128  
    1 import { __ } from '@wordpress/i18n';
    21
    3 export const np_cart_checkout = [
    4     {
    5         label: __('Try again another day', 'shipping-workshop'),
    6         value: 'try-again',
    7     },
    8     {
    9         label: __('Try again another day 2', 'shipping-workshop'),
    10         value: 'try-again 2',
    11     },
    12     {
    13         label: __('other', 'shipping-workshop'),
    14         value: 'other',
    15     }
    16     /**
    17      * [frontend-step-01]
    18      * 📝 Add more options using the same format as above. Ensure one option has the key "other".
    19      */
    20 ];
     2jQuery.ajaxSetup({ cache: false });
     3jQuery( window ).on("load", function() {
     4    try {
     5        if(localized_script.account_option==="always_pwd") {
     6
     7            jQuery('#rfq_createaccount')[0].checked = true;
     8            jQuery('#rfq_createaccount').prop('disabled', true);
     9            jQuery('.gpls-woo-rfq_checkout_button').attr('disabled', 'disabled');
     10        }
     11
     12
     13        let isChecked = jQuery('#rfq_createaccount')[0].checked;
     14
     15        if(isChecked)
     16        {
     17            jQuery(('#account_password')).attr("required", true);
     18            jQuery("#account_password").addClass("required");
     19            jQuery("#account_password").show();
     20            jQuery('.password_input_div').show();
     21
     22
     23        }else{
     24            jQuery('#account_password').attr("required", false);
     25            jQuery('#account_password').removeClass("required");
     26            jQuery("#account_password").hide();
     27            jQuery('.password_input_div').hide();
     28
     29        }
     30
     31
     32        jQuery('#rfq_createaccount').on('click', function () {
     33
     34            let isChecked = jQuery('#rfq_createaccount')[0].checked;
     35
     36            if(isChecked)
     37            {
     38                jQuery(('#account_password')).attr("required", true);
     39                jQuery("#account_password").addClass("required");
     40                jQuery("#account_password").show();
     41                jQuery('.password_input_div').show();
     42
     43
     44            }else{
     45                jQuery('#account_password').attr("required", false);
     46                jQuery('#account_password').removeClass("required");
     47                jQuery("#account_password").hide();
     48                jQuery('.password_input_div').hide();
     49
     50            }
     51
     52        });
     53
     54        jQuery( document ).ready( function( $ ) {
     55            jQuery( 'body' ).on( 'keyup', '#account_password', function( event ) {
     56                if( jQuery( this ).val() != '' ) {
     57
     58                    jQuery( '#password-length','.woocommerce-password-hint' ).show();
     59
     60                    check_password_strength( jQuery( '#account_password' ),
     61                        null,
     62                        jQuery( '#password-length' ),
     63                        jQuery('.gpls-woo-rfq_checkout_button'), ['123', 'abc', 'hello', 'admin'] );
     64                }else{
     65                    check_password_strength( jQuery( '#account_password' ),
     66                        null,
     67                        jQuery( '#password-length' ),
     68                        jQuery('.gpls-woo-rfq_checkout_button'), ['123', 'abc', 'hello', 'admin'] );
     69                    jQuery( '#password-length','.woocommerce-password-hint' ).hide();
     70
     71
     72                }
     73            });
     74
     75
     76
     77
     78        });
     79
     80        function check_password_strength( password,  confirm_password, length_Message, submit_Btn, blacklist_Words ) {
     81            var password = password.val();
     82
     83            blacklist_Words = blacklist_Words.concat( wp.passwordStrength.userInputBlacklist() )
     84            jQuery('.gpls-woo-rfq_checkout_button').attr( 'disabled', 'disabled' );
     85            length_Message.removeClass( 'short bad good strong' );
     86            var password_length = wp.passwordStrength.meter( password, blacklist_Words );
     87            switch ( password_length ) {
     88                case 2:
     89                    length_Message.addClass( 'bad' ).html( pwsL10n.bad );
     90                    jQuery( '.woocommerce-password-hint' ).show();
     91                    break;
     92                case 3:
     93                    length_Message.addClass( 'good' ).html( pwsL10n.good );
     94                    jQuery( '.woocommerce-password-hint' ).hide();
     95                    break;
     96                case 4:
     97                    jQuery( '.woocommerce-password-hint' ).hide();
     98                    length_Message.addClass( 'strong' ).html( pwsL10n.strong );
     99                    break;
     100
     101                default:
     102                    jQuery( '.woocommerce-password-hint' ).hide();
     103                    length_Message.addClass( 'short' ).html( pwsL10n.short );
     104
     105            }
     106            if ( password_length >= 2  ) {
     107                // submit_Btn.removeAttr( 'disabled' );
     108                jQuery('.gpls-woo-rfq_checkout_button').removeAttr( 'disabled' );
     109            }else{
     110                jQuery( '.woocommerce-password-hint' ).show();
     111
     112            }
     113            return password_length;
     114
     115
     116        }
     117
     118
     119
     120    }catch(err){}
     121
     122} ); // jQuery( document ).ready
    21123
    22124
     
    30132
    31133
     134
     135
     136
     137
     138
     139
     140
     141
  • woo-rfq-for-woocommerce/trunk/includes/classes/admin/settings/gpls_woo_rfq_settings.php

    r3182706 r3227128  
    569569                                'type' => 'text',
    570570                                'desc' => 'If 4-02 above is selected,<br />
    571                                      this message (not blank) will be added to the subject of the notification email to admin.<br />
     571                                     this message will be added to the subject of the notification email to admin.<br />
    572572                                      It also adds a note to the order',
    573573                                'default' => __('No Payment', 'woo-rfq-for-woocommerce'),
     
    707707                            ),
    708708                            'rfq_cart_wordings_quote_request_currently_empty' => array(
    709                                 'name' => '12- Normal Checkout- ' . esc_html_e('Your Quote Request List Is Currently Empty', 'woo-rfq-for-woocommerce'),
     709                                'name' => '12- Normal Checkout- ' . __('Your Quote Request List Is Currently Empty', 'woo-rfq-for-woocommerce'),
    710710                                'type' => 'text',
    711711                                'desc' => '',
  • woo-rfq-for-woocommerce/trunk/includes/classes/cart/gpls_woo_rfq_cart.php

    r3195108 r3227128  
    23012301
    23022302                    $add_txt = get_option('rfq_cart_wordings_add_to_rfq', $default_text);
    2303                     $add_txt = __($add_txt, 'woo-rfq-for-woocommerce');
     2303                  //  $add_txt = __($add_txt, 'woo-rfq-for-woocommerce');
    23042304
    23052305                    $in_txt = get_option('rfq_cart_wordings_in_rfq', $default_text);
    2306                     $in_txt = __($in_txt, 'woo-rfq-for-woocommerce');
     2306                 //   $in_txt = __($in_txt, 'woo-rfq-for-woocommerce');
    23072307
    23082308                }
     
    23492349                        $request_quote = __('Read more', 'woo-rfq-for-woocommerce');// "Request Quote"
    23502350                    $read_more = get_option('settings_gpls_woo_rfq_read_more');// "Request Quote"
    2351                         $read_more = __($read_more, 'woo-rfq-for-woocommerce');
     2351                     //   $read_more = __($read_more, 'woo-rfq-for-woocommerce');
    23522352
    23532353                    if ($read_more != "") {
     
    23702370                        $request_quote = __('Read more', 'woo-rfq-for-woocommerce');// "Request Quote"
    23712371                    $read_more = get_option('settings_gpls_woo_rfq_read_more');// "Request Quote"
    2372                         $read_more = __($read_more, 'woo-rfq-for-woocommerce');
     2372                     //   $read_more = __($read_more, 'woo-rfq-for-woocommerce');
    23732373
    23742374                    if ($read_more != "") {
     
    23842384
    23852385            $add_txt= apply_filters('gpls_woo_rfq_add_to_cart_button_text', $add_txt, $product, $rfq_checkout_mode);
     2386
     2387
    23862388
    23872389
  • woo-rfq-for-woocommerce/trunk/includes/classes/checkout/gpls_woo_rfq_ncheckout.php

    r3142924 r3227128  
    1010    add_action('woocommerce_order_needs_payment', 'gplswoo_woocommerce_order_needs_payment', 10, 3);
    1111    function gplswoo_woocommerce_order_needs_payment($status, $order, $valid_order_statuses){
     12        np_write_log( 'gplswoo_woocommerce_order_needs_payment '.$status,__FILE__,__LINE__);
     13
    1214        return false;
    1315    }
     
    1517
    1618}
     19
    1720{
    1821    if ( !is_admin()&&get_option('settings_gpls_woo_rfq_no_payment_checkout', 'no') == 'yes')
     
    3134        if (!function_exists('woocommerce_payment_complete_status')){
    3235            function woocommerce_payment_complete_status($status, $id, $order) {
    33                 return 'wc-pending';
     36                np_write_log('woocommerce_payment_complete_status '. $status,__FILE__,__LINE__);
     37
     38                return 'pending';
    3439            }
    3540        }
     41
     42
     43          if (!function_exists('gpls_pre_payment_complete')){
     44              function gpls_pre_payment_complete( $id, $trx_id) {
     45                  np_write_log('gpls_pre_payment_complete '. $id,__FILE__,__LINE__);
     46$order=wc_get_order($id);
     47$order->set_status('wc-pending');
     48$order->save();
     49
     50              }
     51          }
    3652
    3753        if (!function_exists('gpls_woo_rfq_check')) {
     
    4359                add_filter( 'woocommerce_payment_complete_order_status','woocommerce_payment_complete_status',1000,3);
    4460//apply_filters( 'woocommerce_payment_complete_order_status', $this->needs_processing() ? 'processing' : 'completed', $this->get_id(), $this )
     61
     62              //  add_action( 'woocommerce_pre_payment_complete','gpls_pre_payment_complete', 100,2 );
    4563            }
    4664        }
  • woo-rfq-for-woocommerce/trunk/readme.txt

    r3195129 r3227128  
    66Tested up to: 6.7
    77Requires PHP: 8.2
    8 WC tested up to: 9.3.3
    9 Stable tag: 1.9.179
     8WC tested up to: 9.6.0
     9Stable tag: 1.9.180
    1010License: GPLv2
    1111License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    209209== Changelog ==
    210210
    211 = 1.9.179 11/22/2024 =
    212 languge file corruption fixed
     211= 1.9.180 1/22/2025 =
     212fix password file
    213213
    214214== Upgrade Notice ==
    215215
    216 = 1.9.179 11/22/2024 =
    217 languge file corruption fixed
    218 
    219 
     216= 1.9.180 1/22/2025 =
     217fix password file
     218
     219
  • woo-rfq-for-woocommerce/trunk/woo-rfq-for-woocommerce.php

    r3195129 r3227128  
    33 * Plugin Name: NP Quote Request for WooCommerce
    44 * Description: NP Quote Request for WooCommerce enables your customers to easily submit a quote request to your WooCommerce store. It is very flexible and can be used in a variety of store settings. NP Quote Request for WooCommerce enables you to generate leads and engage with your customers!
    5  * Version: 1.9.179
     5 * Version: 1.9.180
    66 * Contributors: Neah Plugins,gplsaver
    77 * Author: Neah Plugins
     
    1111 * Tested up to: 6.7
    1212 * Requires PHP: 7.4
    13  * WC tested up to: 9.3.3
     13 * WC tested up to: 9.6.0
    1414 * Text Domain: woo-rfq-for-woocommerce
    1515 * Domain Path: /languages/
     
    352352
    353353
    354         if (class_exists('WC_Payment_Gateway')) {
     354        if (class_exists('WC_Payment_Gateway'))
     355        {
    355356            //  require_once 'includes/class-wc-gateway-dummy.php';
    356357            require_once 'includes/classes/gateway/class-wc-gateway-rfq.php';
    357358            $GLOBALS['WC_Gateway_RFQ'] = new WC_Gateway_RFQ();
    358             //  require_once 'includes/classes/gateway/wc-gateway-gpls-request-quote.php';
     359                require_once 'includes/classes/gateway/wc-gateway-gpls-request-quote.php';
    359360        }
    360361
     
    545546    public function check_for_rfq_checkout()
    546547    {
     548
    547549        add_filter('woocommerce_payment_gateways', 'add_gpls_woo_rfq_class', 1, 1);
    548550
     
    551553        // add_filter('woocommerce_available_payment_gateways', 'gpls_rfq_remove_other_payment_gateways', 1000, 1);
    552554        add_filter('woocommerce_payment_gateways', 'gpls_rfq_remove_other_block_payment_gateways', 1000, 1);
     555
    553556
    554557        gpls_woo_rfq_handle_checkout();
Note: See TracChangeset for help on using the changeset viewer.