Mike Jolley
d694483735
Fix tax display issue for discounts
2017-10-13 14:36:35 +01:00
Mike Jolley
4f3393fc2f
Tax calculations should use `unfiltered` context for tax class
...
This fixes variations which have a ‘parent’ tax class. It should
inherit from the parent.
Closes #17147
2017-10-12 10:12:20 +01:00
lars
ac24a56ff3
#16938 rename filter for clarity
2017-10-04 10:56:56 +02:00
lars
73bc8b8e6c
added actions and filters to modify tax calculation for shipping taxes and fee taxes #16938
...
Filters and actions are needed to ensure correct tax calculation by
German law.
The filter in class-wc-cart-totals.php is used to modify fee tax
calculation during checkout and in cart.
The actions in the other files are used to modify tax calculation in
backend for manual orders.
2017-09-28 12:52:55 +02:00
Mike Jolley
f1f56423c0
Docblocks
2017-09-27 17:16:33 +01:00
Mike Jolley
40040f534b
These classes require WC_Cart objects
2017-09-27 17:12:45 +01:00
Mike Jolley
5151415eec
Merge branch 'discounts-class-fixes-and-tests'
2017-09-20 18:44:18 +01:00
Mike Jolley
21dfde842a
Revised coupon sort order to not rely on IDs which can differ between cart and tests
...
Also edited test to match
2017-09-20 18:41:48 +01:00
Mike Jolley
d3da954133
Move cart totals setter for 3.1 compat
...
Closes #16794
2017-09-15 11:15:50 -07:00
Mike Jolley
804feb9333
Store fee amount and prevent totals going negative
2017-08-23 12:15:06 +01:00
Mike Jolley
559982fbe7
Unused variable
2017-08-22 17:02:48 +01:00
Mike Jolley
00cb48a5fe
Pass through to order
2017-08-22 16:20:23 +01:00
Mike Jolley
367f08d79f
Negative fee logic for cart
2017-08-22 16:12:37 +01:00
Mike Jolley
1c8ad67a9e
Fix tests and tax merges
2017-08-18 15:05:01 +01:00
Mike Jolley
b854c1775c
Tests
2017-08-18 13:53:22 +01:00
Mike Jolley
302512e51f
Combine taxes correctly
2017-08-18 13:48:53 +01:00
Mike Jolley
3c18d5e849
Adjust total discount for ex.tax
2017-08-15 16:25:39 +01:00
Mike Jolley
392ce417bc
docblocks
2017-08-15 12:21:12 +01:00
claudiulodro
ae80d12d80
Merge master
2017-08-14 11:12:09 -07:00
Mike Jolley
e20d886972
calculate_item_discounts for clarity
2017-08-11 16:16:36 +01:00
Mike Jolley
51dffc0853
Apply logical sort order to discounts
...
Closes #16394
2017-08-10 17:24:27 +01:00
Mike Jolley
1fd1699bcd
Ensure isset
2017-08-10 11:25:08 +01:00
Mike Jolley
81806617d7
Fix total and rounding logic for tests
2017-08-08 09:24:26 +01:00
claudiulodro
80708255ee
Fix inc tax price calculation
2017-08-02 11:07:33 -07:00
claudiulodro
8fac8fc80b
Cleanup
2017-07-31 13:18:39 -07:00
claudiulodro
43cbcd04ef
Remove extra calcs and populate item totals
2017-07-31 11:48:34 -07:00
Claudio Sanches
de52221004
Fixe fatal error while trying to sum an empty array
2017-07-28 17:38:43 -03:00
Mike Jolley
c16df62b54
Fix tests and bootstrap
2017-07-28 17:43:08 +01:00
Mike Jolley
64e04c614a
fix variable in calculate_discounts
2017-07-28 16:43:51 +01:00
Mike Jolley
e23e55bb27
Methods for getting specific totals and discounts whilst keeping storage in a single array
2017-07-28 15:35:41 +01:00
Mike Jolley
51fbb1aec3
set_items_from_cart
2017-07-28 13:02:39 +01:00
Mike Jolley
fcfa510445
Fixed totals tests
2017-07-27 16:57:05 +01:00
Mike Jolley
ded2be8d28
Legacy filters
2017-07-27 15:31:10 +01:00
Mike Jolley
6054519605
Discount taxes
2017-07-27 13:48:58 +01:00
Mike Jolley
98db84dfdd
Passing tests
2017-07-27 11:01:48 +01:00
Mike Jolley
c6b8ad598f
Precision functions
2017-07-27 10:51:08 +01:00
Mike Jolley
306db69eaf
Remove order subclass
2017-07-27 10:49:47 +01:00
Mike Jolley
b9b4336c1b
Removed some duplicate keys
2017-07-26 16:50:34 +01:00
Mike Jolley
abdb325d83
Order items
2017-07-26 15:47:30 +01:00
Mike Jolley
1faae6a7aa
Order subclass
2017-07-26 14:32:43 +01:00
Mike Jolley
250dabaf41
WC_Cart_Totals subclass
2017-07-26 12:44:06 +01:00