Plugin Directory

Changeset 3239462


Ignore:
Timestamp:
02/12/2025 02:44:14 PM (14 months ago)
Author:
bitsstech
Message:

new version

Location:
shipment-tracker-for-woocommerce/trunk
Files:
6 added
5 edited

Legend:

Unmodified
Added
Removed
  • shipment-tracker-for-woocommerce/trunk/bt-sync-shipment-tracking.php

    r3238579 r3239462  
    1717 * Plugin URI:        https://shipment-tracker-for-woocommerce.bitss.tech/
    1818 * Description:       Most comprehensive shipment tracking plugin that extends your woocommerce store with shipment related features. Keeps you & your customers informed about shipment movement.
    19  * Version:           1.4.23.9
     19 * Version:           1.4.23.10
    2020 * Author:            Bitss Techniques
    2121 * Author URI:        https://shipment-tracker-for-woocommerce.bitss.tech
     
    5959
    6060define( 'Carbon_Fields\URL', trailingslashit( plugin_dir_url( __FILE__ ) ) . 'vendor/htmlburger/carbon-fields/' );//fix for Bitnami installations.
    61 define( 'BT_SYNC_SHIPMENT_TRACKING_VERSION', '1.4.23.9' );
     61define( 'BT_SYNC_SHIPMENT_TRACKING_VERSION', '1.4.23.10' );
    6262define( 'BT_SHIPPING_PROVIDERS', array('delhivery' =>'Delhivery','nimbuspost' => 'Nimbuspost (Deprecated)','nimbuspost_new' => 'Nimbuspost','shipmozo'=>'Shipmozo','shiprocket' => 'Shiprocket', 'xpressbees' => 'Xpressbees', 'manual' =>'Custom Shipping') );
    6363define( 'BT_SHIPPING_PROVIDERS_WITH_NONE', array('none' =>'none','delhivery' =>'Delhivery', 'nimbuspost' => 'Nimbuspost (OLD)','nimbuspost_new' => 'Nimbuspost(NEW)','shipmozo'=>'Shipmozo','shiprocket' => 'Shiprocket', 'xpressbees' => 'Xpressbees','manual' =>'Custom Shipping') );
  • shipment-tracker-for-woocommerce/trunk/includes/class-bt-sync-shipment-tracking.php

    r3238579 r3239462  
    25592559        $this->loader->add_shortcode( 'bt_shipment_edd', $plugin_public,  'bt_shipment_edd_shortcode_callback' );
    25602560        $this->loader->add_shortcode( 'bt_shipment_awb', $plugin_public,  'bt_shipment_awb_shortcode_callback' );
     2561        $this->loader->add_shortcode( 'bt_shipment_timer', $plugin_public,  'bt_shipment_timer_shortcode_callback' );
    25612562
    25622563        $this->loader->add_filter( 'woocommerce_email_format_string', $plugin_public,  'woocommerce_email_format_string_shipment_placeholders_callback', 10, 2  );
  • shipment-tracker-for-woocommerce/trunk/public/class-bt-sync-shipment-tracking-public.php

    r3238579 r3239462  
    9090        wp_register_style('bt-sync-shipment-tracking-public-css', plugin_dir_url(__FILE__) . 'css/bt-sync-shipment-tracking-public.css', array(), $this->version, 'all');
    9191        wp_register_style('bt-sync-shipment-tracking-leaflet-css', plugin_dir_url(__FILE__) . 'css/bt-sync-shipment-tracking-leaflet.css', array(), $this->version, 'all');
     92        wp_register_style('bt-shipment-tracking-timing-css', plugin_dir_url(__FILE__) . 'timer/css/bt_sst_shipment_tracker_timer.css', array(), $this->version, 'all');
    9293
    9394        if (is_checkout()) {
     
    117118         */
    118119        wp_register_script('bt-sync-shipment-tracking-public', plugin_dir_url(__FILE__) . 'js/bt-sync-shipment-tracking-public.js', array('jquery'), $this->version, true);
     120        wp_register_script('bt-shipment-tracking-timing-js', plugin_dir_url(__FILE__) . 'timer/js/bt_sst_shipment_tracker.js', array('jquery'), $this->version, true);
    119121        wp_register_script(
    120122            'bt-sync-shipment-tracking-leaflet',
     
    24442446    }
    24452447
     2448    // Shortcode function for shipment timer
     2449    public function bt_shipment_timer_shortcode_callback($atts, $content = null, $tag = '')
     2450    {
     2451        wp_enqueue_style('bt-shipment-tracking-timing-css');
     2452        wp_enqueue_script('bt-shipment-tracking-timing-js');
     2453        // Set default values and extract attributes
     2454        $atts = shortcode_atts(
     2455            array(
     2456                'hours'   => 0,  // Default: 0 hours
     2457                'minutes' => 59, // Default: 59 minutes
     2458                'seconds' => 59  // Default: 59 seconds
     2459            ),
     2460            $atts,
     2461            'bt_shipment_timer'
     2462        );
     2463
     2464        // Convert attributes to total seconds
     2465        $total_seconds = ($atts['hours'] * 3600) + ($atts['minutes'] * 60) + $atts['seconds'];
     2466
     2467        ob_start();
     2468       
     2469        // Include the external file and pass attributes
     2470        include plugin_dir_path(dirname(__FILE__)) . 'public/timer/bt_sst_shipment_tracker_timer.php';
     2471
     2472        // Capture output
     2473        return ob_get_clean();
     2474    }
     2475
    24462476    public function woocommerce_email_format_string_shipment_placeholders_callback( $string, $email ) {
    24472477        // Get WC_Order object from email
  • shipment-tracker-for-woocommerce/trunk/public/partials/bt_shipping_tracking_page_primary_template_second.php

    r3238579 r3239462  
    3939    .tracking-input {
    4040        padding: 15px;
    41         width: 250px;
     41        width: 50%;
    4242        border-radius:20px 0 0 20px;
    4343        font-size: 1rem;
Note: See TracChangeset for help on using the changeset viewer.