Plugin Directory

Changeset 3289542


Ignore:
Timestamp:
05/08/2025 05:45:05 AM (10 months ago)
Author:
webtonative
Message:

Deploy plugin version 2.7.4

Location:
webtonative/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • webtonative/trunk/README.md

    r3286216 r3289542  
    44Requires at least: 2.0.2
    55Tested up to: 6.7.1
    6 Stable tag: 2.7.3
     6Stable tag: 2.7.4
    77License: GPLv2 or later
    88
  • webtonative/trunk/index.php

    r3286216 r3289542  
    33  Plugin Name: webtonative
    44  Description: webtonative Plugin
    5   Version: 2.7.3
     5  Version: 2.7.4
    66  Author: webtonative
    77*/
  • webtonative/trunk/website/scripts/woocommerce.js

    r3227974 r3289542  
    142142  // Event delegation for dynamically added buttons
    143143  $(document).on('click', '.single_add_to_cart_button, .add_to_cart_button', async function (e) {
     144    const button = $(this);
     145    const productId = button.data('product_id') || button.val();
     146    const nativeProductId = data?.[productId.toString()]?.[WTN.isIosApp ? 'appStore' : 'googlePlay'];
     147    if (!nativeProductId) return;
     148
    144149    e.stopPropagation();
    145150    e.preventDefault();
     
    150155      return;
    151156    }
    152     if(WTN.isIosApp && !iosSecretKey){
    153       alert("Please configure App store secret key in settings");
     157    if (WTN.isIosApp && !iosSecretKey) {
     158      alert('Please configure App store secret key in settings');
    154159      return;
    155160    }
    156 
    157     const button = $(this);
    158     const productId = button.data('product_id') || button.val();
    159 
    160     const nativeProductId = data?.[productId.toString()]?.[WTN.isIosApp ? 'appStore' : 'googlePlay'];
    161     if (!nativeProductId) return;
    162161
    163162    await processPayment.call(this);
Note: See TracChangeset for help on using the changeset viewer.