Plugin Directory

Changeset 3670506


Ignore:
Timestamp:
08/28/2026 02:23:45 PM (2 months ago)
Author:
nightvanhelsing
Message:

Commit for version 1.1.0

Location:
anise-simple-discounts/trunk
Files:
4 added
4 edited

Legend:

Unmodified
Added
Removed
  • anise-simple-discounts/trunk/anise-simple-discounts.php

    r3642344 r3670506  
    55 * Author: Michał Adamek
    66 * Author URI: https://github.com/NightVanHelsing
    7  * Version: 1.0.0
     7 * Version: 1.1.0
    88 * License: GPL v2 or later
    99 * License URI: https://www.gnu.org/licenses/gpl-2.0.html
    … …  
    1515        exit;
    1616}
     17define('ASD_PLUGIN_URL',plugin_dir_url(__FILE__));
    1718require_once __DIR__.'/include/discounts.php'; 
    1819require_once __DIR__.'/include/user-panel.php';
     20require_once __DIR__.'/include/popupsource.php';
     21
  • anise-simple-discounts/trunk/include/discounts.php

    r3642344 r3670506  
    1212    $asd_percentage = (int) get_user_meta($asd_client_id, 'asd_discount_percentage', true);
    1313    if ($asd_percentage > 0 && $asd_percentage < 100) {
    14     $discount = (WC()->cart->cart_contents_total) * ($asd_percentage/100);     
     14    $discount = (WC()->cart->get_cart_contents_total()) * ($asd_percentage/100);       
    1515        WC()->cart->add_fee(__('Permament discount','anise-simple-discounts'), -$discount);
    16         }
     16        } 
    1717    }
    1818}
     19
     20
  • anise-simple-discounts/trunk/readme.txt

    r3642344 r3670506  
    33Tags: discounts, woocommerce, customer
    44Requires at least: 7.0
    5 Tested up to: 7.0
     5Tested up to: 7.1
    66Requires PHP: 8.2
    7 Stable tag: 1.0.0
     7Stable tag: 1.1.0
    88License: GPL v2 or later
    99License URI: https://www.gnu.org/licenses/gpl-2.0.html
    … …  
    3131Edit a user's profile and enter a value between 1 and 99.
    3232
     33= How do I delete assigned discounts? =
     34
     35When disabling the plugin, you will have the option to delete all assigned discounts.
     36
    3337== Upgrade Notice ==
     38
     39= 1.1.0 =
     40Added a prompt asking whether to delete discount data when disabling the plugin.
    3441
    3542= 1.0.0 =
    … …  
    3845== Changelog ==
    3946
     47= 1.1.0 =
     48- Added a prompt asking whether to delete discount data when disabling the plugin.
     49
    4050= 1.0.0 =
    41 Initial release.
     51- Initial release.
  • anise-simple-discounts/trunk/uninstall.php

    r3642344 r3670506  
    33    die;
    44}
     5
    56delete_metadata('user',0,'asd_discount_percentage','',true);
Note: See TracChangeset for help on using the changeset viewer.