Changeset 2620240
- Timestamp:
- 10/26/2021 03:09:22 PM (4 years ago)
- Location:
- wc-yabi/trunk
- Files:
-
- 3 edited
-
includes/ajax.php (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
-
wc-yabi.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
wc-yabi/trunk/includes/ajax.php
r2590939 r2620240 49 49 } 50 50 51 /* Coupons */ 52 $numitem = 0; 53 $order_items = $order->get_items('coupon'); 54 foreach( $order_items as $item_id => $item ) 55 { 56 $order_discount_amount = wc_get_order_item_meta( $item_id, 'discount_amount', true ); 57 $order_discount_tax_amount = wc_get_order_item_meta( $item_id, 'discount_amount_tax', true ); 58 59 if( isset( $products[ $numitem ] ) ) 60 { 61 $products[ $numitem ][ 'value' ] = floatval( $products[ $numitem ][ 'value' ] ) - floatval( $order_discount_amount ); 62 $products[ $numitem ][ 'tax' ] = floatval( $products[ $numitem ][ 'tax' ] ) - floatval( $order_discount_tax_amount ); 63 64 $products[ $numitem ][ 'percent' ] = round( $products[ $numitem ][ 'tax' ] * 100 / $products[ $numitem ][ 'value' ] ); 65 } 66 67 $numitem++; 68 } 69 /***********/ 70 51 71 $dueDate = date( "Y-m-d" ); 52 72 $dateTime = date( "Y-m-d" ) .'T'. date("H:i:s") .'Z'; … … 56 76 'dueDate' => $dueDate, 57 77 'dateTime' => $dateTime, 58 ); 59 78 ); 79 60 80 $graphQL = yabi_create_invoice_person( $person, $products, $payment ); 61 81 -
wc-yabi/trunk/readme.txt
r2590939 r2620240 4 4 Donate link: https://www.paypal.me/datakun 5 5 Requires at least: 5.5 6 Tested up to: 5.8 6 Tested up to: 5.8.1 7 7 Requires PHP: 7.4 8 8 Stable tag: trunk … … 90 90 = 1.3.1 = 91 91 * The taxscheme field was deleted, the field is no longer required 92 = 1.4.0 = 93 * Discount coupon validation -
wc-yabi/trunk/wc-yabi.php
r2590939 r2620240 9 9 * Plugin URI: https://mireunion.com/yabi 10 10 * Description: Create your electronic invoices of purchases made in woocommerce with Yabi 11 * Version: 1. 3.111 * Version: 1.4.0 12 12 * Author: Mex Avila 13 13 * Author URI: https://datakun.com/
Note: See TracChangeset
for help on using the changeset viewer.