Plugin Directory

Changeset 1782751


Ignore:
Timestamp:
12/07/2017 03:07:38 PM (8 years ago)
Author:
mslsantos
Message:

First Version

Location:
woo-masterway/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • woo-masterway/trunk/readme.txt

    r1668525 r1782751  
    33Tags: woocommerce, invoice, invoicing, masterway, ecommerce, billing
    44Requires at least: 3.0
    5 Tested up to: 4.8
     5Tested up to: 4.9.1
    66Stable tag: trunk
    77License: GPLv2 or later
  • woo-masterway/trunk/woocommerce-masterway.php

    r1610777 r1782751  
    544544                            $ExemptionReasonCode='';
    545545                           
    546                             $line_subtotal=$item['line_subtotal'];
    547                             $line_total=$item['line_total'];
     546                            $line_subtotal=(float)$item['line_subtotal'];
     547                            $line_total=(float)$item['line_total'];
     548                           
     549                            // TRATAMENTO DO DO DESCONTO
     550                            if($line_subtotal != $line_total)
     551                            {
     552                                $Discount = ($line_total * 100) / $line_subtotal;
     553                                $Discount = 100 - $Discount;
     554                                $Discount = round($Discount, 2);
     555                            }
    548556                           
    549557                           
Note: See TracChangeset for help on using the changeset viewer.